public inbox for [email protected]  
help / color / mirror / Atom feed
From: Peter Eisentraut <[email protected]>
To: Daniel Gustafsson <[email protected]>
Cc: David G. Johnston <[email protected]>
Cc: Kyotaro Horiguchi <[email protected]>
Cc: [email protected]
Subject: Re: Possibly hard-to-read message
Date: Thu, 12 Jun 2025 08:27:42 +0200
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
References: <[email protected]>
	<CAKFQuwYN3wP2cz=FDJyOyLEutgXfJOZNS+8SFhWdwUR-QsbRgQ@mail.gmail.com>
	<[email protected]>
	<CAKFQuwbV7kD-v-SYjyQTvxOUui5HkRcXO4RoMNnbPaDL=Bw0WQ@mail.gmail.com>
	<CAKFQuwYJLJvt17eSAtxeBLngNrEzQD+kU4GpP7HwcupmL_NbmQ@mail.gmail.com>
	<[email protected]>
	<CAKFQuwYDZEmRnmSUUQSi=vX7MiKXb3Z-4eyAB1RqqmtWxJ0DTA@mail.gmail.com>
	<[email protected]>
	<[email protected]>
	<[email protected]>

On 11.06.25 11:36, Daniel Gustafsson wrote:
> 
> 
>> On 5 Jun 2025, at 13:14, Peter Eisentraut <[email protected]> wrote:
>>
>> On 07.04.25 02:55, Daniel Gustafsson wrote:
>>>> On 7 Apr 2025, at 02:43, David G. Johnston <[email protected]> wrote:
>>>> How about:
>>>>
>>>> + "    if set to a number, overrides the default two second \\watch interval\n"
>>>>
>>>> I do like the consistency of "if set" even though most of the others are booleans.
>>> Ah yes, number is better. I'll go ahead with that in the morning.
>>
>> I came across this psql help text and had a hard time processing it, and, without having read this thread, my thought process was that the message should be phrased more like how it was originally.
>>
>> The problem with the current phrasing is:
>>
>> - "if set to a number" seems to indicate that something else happens if it's not a number.  But it doesn't say what.  And it's also not true. And we don't phrase things like that for other numeric settings.
>>
>> - The way this is phrased now seems to say that the variable is unset by default, and only if it is set does it override the default.  But that is not what happens.  The variable has a value by default, and that is what gets used.
>>
>> I suggest something like this:
>>
>> number seconds \watch waits between executions (in seconds, default %d)
>>
>>
>> While we're here, the documentation could also use some more detail:
>>
>>       <varlistentry id="app-psql-variables-watch-interval">
>>         <term><varname>WATCH_INTERVAL</varname></term>
>>         <listitem>
>>         <para>
>>         This variable sets the default interval which <command>\watch</command>
>>         waits between executing the query.  Specifying an interval in the
>>         command overrides this variable.
>>         </para>
>>         </listitem>
>>       </varlistentry>
>>
>> This mentions neither the units nor the default value.
> 
> How about the attached (reflowing rows in docs not done to keep the diff readable)?

  	HELP0("  WATCH_INTERVAL\n"
-		  "    if set to a number, overrides the default two second \\watch 
interval\n");
+		  "    number of seconds \\watch waits between executions (default %s 
seconds)\n",
+		  DEFAULT_WATCH_INTERVAL);

This wording has the disadvantage that it requires plural-enabling the 
translation of "seconds".  I think you can just leave off the second 
"seconds" to avoid that.

The rest looks good to me.






view thread (15+ messages)  latest in thread

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected], [email protected], [email protected], [email protected]
  Subject: Re: Possibly hard-to-read message
  In-Reply-To: <[email protected]>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox