Re: improve CREATE EXTENSION error message - Mailing list pgsql-hackers

From Chapman Flack
Subject Re: improve CREATE EXTENSION error message
Date
Msg-id 61A5530C.8080005@anastigmatix.net
Whole thread Raw
In response to Re: improve CREATE EXTENSION error message  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On 11/29/21 17:03, Tom Lane wrote:
> I think "The extension must ..." would read better, otherwise +1.

I'm not strongly invested either way, but I'll see if I can get at why
I used 'an' ...

Hints are hinty. We can give them, and they're helpful, because there
are certain situations that we know are very likely to be what's behind
certain errors. ENOENT on the control file? Yeah, probably means the
extension needs to be installed. In somebody's specific case, though,
it could mean most of the extension is there but the other sysadmin
overnight fat-fingered an rm command and has been spending the morning
idly wondering why the file he /meant/ to remove is still there. Or a bit
flipped in an inode and a directory became a file. (That happened to me on
a production system once; the directory was /usr. That'll mess stuff up.)

So, in my view, a hint doesn't need to sound omniscient, or as if it
somehow knows precisely what happened in your case. It's enough (maybe
better, even?) if a hint reads like a hint, a general statement that
you may ponder for a moment and then think "yeah, that sounds like it's
probably what I needed to know."

Regards,
-Chap



pgsql-hackers by date:

Previous
From: "Bossart, Nathan"
Date:
Subject: Re: improve CREATE EXTENSION error message
Next
From: Chapman Flack
Date:
Subject: Re: improve CREATE EXTENSION error message