Re: pgsql: psql: add an optional execution-count limit to \watch.
От | Anton Voloshin |
---|---|
Тема | Re: pgsql: psql: add an optional execution-count limit to \watch. |
Дата | |
Msg-id | 81b84b74-01ad-4782-9114-86ff842b1fd7@postgrespro.ru обсуждение исходный текст |
Ответ на | Re: pgsql: psql: add an optional execution-count limit to \watch. (Tom Lane <tgl@sss.pgh.pa.us>) |
Ответы |
Re: pgsql: psql: add an optional execution-count limit to \watch.
|
Список | pgsql-hackers |
On 26/04/2024 05:20, Tom Lane wrote: > Haven't we worked around that everywhere it matters, in commits such > as 8421f6bce and 605062227? Yes, needing 8421f6bce and 605062227 was, perhaps, surprising, but reasonable. Unlike breaking floating point constants in the source code. But, I guess, you're right and, since it does look like a Perl bug, we'll have to work around that in all places where we use floating-point constants in Perl code, which are surprisingly few. > For me, check-world passes under > LANG=ru_RU, even with perl 5.38.2 (where I do confirm that your > test script fails). The buildfarm isn't unhappy either. Indeed, check-world seems to run fine on my machine and on the bf as well. Grepping and browsing through, I've only found three spots with \d\.\d directly in Perl code as a float, only one of them needs correction. 1. src/test/perl/PostgreSQL/Test/Kerberos.pm in master src/test/kerberos/t/001_auth.pl in REL_16_STABLE > if ($krb5_version >= 1.15) I guess adding use locale ':numeric' would be easiest workaround here. Alternatively, we could also split version into krb5_major_version and krb5_minor_version while parsing krb5-config --version's output above, but I don't think that's warranted. So I suggest something along the lines of 0001-use-numeric-locale-in-kerberos-test-rel16.patch and *-master.patch (attached, REL_16 and master need this change in different places). I did verify by providing fake 'krb5-config' that before the fix, with LANG=ru_RU.UTF-8 and Perl 5.38.2 and with, say, krb5 "version" 1.13 it would still add the "listen" lines to kdc.conf by mistake (presumably, confusing some versions of kerberos). 2 and 3. contrib/intarray/bench/create_test.pl > if (rand() < 0.7) and > if ($#sect < 0 || rand() < 0.1) PostgreSQL::Test::Utils is not used there, so it's OK, no change needed. I did not find any other float constants in .pl/.pm files in master (I could have missed something). > Particularly in > this way --- what are we supposed to do, write "if (0 < 0,5)"? > That means something else. Yep. I will try to report this to Perl community later. -- Anton Voloshin Postgres Professional, The Russian Postgres Company https://postgrespro.ru
Вложения
В списке pgsql-hackers по дате отправления: