Re: pgsql: psql: add an optional execution-count limit to \watch.

From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Alexander Korotkov <aekorotkov(at)gmail(dot)com>
Cc: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: pgsql: psql: add an optional execution-count limit to \watch.
Date: 2024-04-27 12:15:36
Message-ID: 58d71f37-a353-408f-950d-0c759e662d81@dunslane.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers pgsql-hackers


On 2023-04-07 Fr 10:00, Tom Lane wrote:
> Alexander Korotkov<aekorotkov(at)gmail(dot)com> writes:
>> On Thu, Apr 6, 2023 at 8:18 PM Tom Lane<tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>>> psql: add an optional execution-count limit to \watch.
>> This commit makes tests fail for me. psql parses 'i' option of
>> '\watch' using locale-aware strtod(), but 001_basic.pl uses hard-coded
>> decimal separator.
> Huh, yeah, I see it too if I set LANG=ru_RU.utf8 before running psql's
> TAP tests. It seems unfortunate that none of the buildfarm has noticed
> this. I guess all the TAP tests are run under C locale?

[just noticed this, redirecting to -hackers]

When run under meson, yes unless the LANG/LC_* settings are explicitly
in the build_env. I'm fixing that so we will allow them to pass through.
When run with configure/make they run with whatever is in the calling
environment unless overridden in the build_env.

We do have support for running installchecks with multiple locales.This
is done by passing --locale=foo to initdb.

We could locale-enable the non-install checks (for meson builds, that's
the 'misc-check' step, for configure/make builds it's more or less
everything between the install stages and the (first) initdb step. We'd
have to do that via appropriate environment settings, I guess. Would it
be enough to set LANG, or do we need to set the LC_foo settings
individually? Not sure how we manage it on Windows. Maybe just not
enable it for the first go-round.

cheers

andrew

--
Andrew Dunstan
EDB: https://www.enterprisedb.com

In response to

Browse pgsql-committers by date

  From Date Subject
Next Message David Rowley 2024-04-28 08:04:10 pgsql: Fix duplicated consecutive words in comments
Previous Message Andrew Dunstan 2024-04-27 11:10:42 pgsql: Remove redundant JSON parser typedefs

Browse pgsql-hackers by date

  From Date Subject
Next Message Masahiko Sawada 2024-04-27 13:04:33 Re: New committers: Melanie Plageman, Richard Guo
Previous Message Peter Eisentraut 2024-04-27 09:12:05 Re: Use XLOG_CONTROL_FILE macro everywhere?