Re: About a recently-added message

From: Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>
To: Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>
Cc: pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: About a recently-added message
Date: 2024-02-14 11:45:37
Message-ID: CAA4eK1J4iu3tK=T+9ur6sD6ZXnMQSHGJvHmSpd_badikEWryQw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Feb 14, 2024 at 12:57 PM Kyotaro Horiguchi
<horikyota(dot)ntt(at)gmail(dot)com> wrote:
>
> A recent commit added the following message:
>
> > "wal_level" must be >= logical.
>
> The use of the term "logical" here is a bit confusing, as it's unclear
> whether it's meant to be a natural language word or a token. (I
> believe it to be a token.)
>
> On the contrary, we already have the following message:
>
> > wal_level must be set to "replica" or "logical" at server start.
>
> This has the conflicting policy about quotation of variable names and
> enum values.
>
> I suggest making the quoting policy consistent.
>

As per docs [1] (In messages containing configuration variable names,
do not include quotes when the names are visibly not natural English
words, such as when they have underscores, are all-uppercase, or have
mixed case. Otherwise, quotes must be added. Do include quotes in a
message where an arbitrary variable name is to be expanded.), I think
in this case GUC's name shouldn't have been quoted. I think the patch
did this because it's developed parallel to a thread where we were
discussing whether to quote GUC names or not [2]. I think it is better
not to do as per docs till we get any further clarification.

Now, I am less clear about whether to quote "logical" or not in the
above message. Do you have any suggestions?

[1] - https://www.postgresql.org/docs/devel/error-style-guide.html
[2] - https://www.postgresql.org/message-id/CAHut+Psf3NewXbsFKY88Qn1ON1_dMD6343MuWdMiiM2Ds9a_wA@mail.gmail.com

--
With Regards,
Amit Kapila.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Alexander Korotkov 2024-02-14 12:00:06 Re: Stack overflow issue
Previous Message Jim Jones 2024-02-14 11:36:49 Re: Psql meta-command conninfo+