Re: Questioning an errcode and message in jsonb.c - Mailing list pgsql-hackers

From Andy Fan
Subject Re: Questioning an errcode and message in jsonb.c
Date
Msg-id CAKU4AWrQ8fTuNx84doWf1ixMwgV3BrTXXrVP5a3FY+3rE4tm2g@mail.gmail.com
Whole thread Raw
In response to Questioning an errcode and message in jsonb.c  (Chapman Flack <chap@anastigmatix.net>)
List pgsql-hackers
Hi, 

 Thanks for raising this issue in a more public way:) 

On Tue, Sep 19, 2023 at 12:55 AM Chapman Flack <chap@anastigmatix.net> wrote:

It would make me happy if the message could be changed, and maybe
ERRCODE_INVALID_PARAMETER_VALUE also changed, perhaps to one of
the JSON-specific ones in the 2203x range.

I'd agree with this. 
 
By the same token, the message and the errcode are established
current behavior, so there can be sound arguments against changing
them (even though that means weird logic in rewriting the expression).
 
This is not a technology issue,  I'd be pretty willing to see what some
more experienced people say about this.  I think just documenting the 
impatible behavior is an option as well.  

--
Best Regards
Andy Fan

pgsql-hackers by date:

Previous
From: Ryoga Yoshida
Date:
Subject: Re: Bug fix for psql's meta-command \ev
Next
From: Sergey Shinderuk
Date:
Subject: Re: Fix error handling in be_tls_open_server()