Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pLRPk-00049T-LW for pgsql-hackers@arkaria.postgresql.org; Fri, 27 Jan 2023 16:17:20 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1pLRPj-00026s-9R for pgsql-hackers@arkaria.postgresql.org; Fri, 27 Jan 2023 16:17:19 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pLRPj-00026i-0F for pgsql-hackers@lists.postgresql.org; Fri, 27 Jan 2023 16:17:19 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pLRPg-0007zc-RH for pgsql-hackers@postgresql.org; Fri, 27 Jan 2023 16:17:18 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 30RGHD7u3335492; Fri, 27 Jan 2023 11:17:14 -0500 From: Tom Lane To: Robert Haas cc: Peter Eisentraut , Nathan Bossart , "pgsql-hackers@postgresql.org" Subject: Re: improving user.c error messages In-reply-to: References: <20230118231749.GA3790025@nathanxps13> <20230126002251.GA1506128@nathanxps13> <9811affe-6755-2618-001b-46d6218e5463@enterprisedb.com> Comments: In-reply-to Robert Haas message dated "Fri, 27 Jan 2023 08:31:32 -0500" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <3335490.1674836233.1@sss.pgh.pa.us> Date: Fri, 27 Jan 2023 11:17:13 -0500 Message-ID: <3335491.1674836233@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Robert Haas writes: > I almost hate to bring this up since I'm not sure how far we want to > go down this rat hole, but what should be our policy about mentioning > superuser? I don't think we're entirely consistent right now, and I'm > not sure whether every error message needs to mention that if you were > the superuser you could do everything. Is that something we should > mention always, never, or in some set of circumstances? Good point. My vote is for standardizing on *not* mentioning it. Error messages should say "you need privilege X". That is not the place to go into all the ways you could hold privilege X (one of which is being superuser). regards, tom lane