Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-27 Thread Michael Paquier
On Mon, Jan 27, 2025 at 07:45:55AM +0900, Michael Paquier wrote: > Yep. config_sspi_auth() would fill into hba.conf a new HBA entry for > all the roles given by --create-role under the --config-auth switch, > which is wnat we want here. > > Will go fix in a bit using Dagfinn's patch. Worth a not

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-26 Thread Michael Paquier
On Sun, Jan 26, 2025 at 09:12:49AM -0500, Andrew Dunstan wrote: > On 2025-01-26 Su 9:02 AM, Andrew Dunstan wrote: >> This seems to me like the wrong fix. We don't want to create >> "no_such_user" I think, we just want to catch the Windows error message, >> as in this patch. Back into business now,

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-26 Thread Andrew Dunstan
On 2025-01-26 Su 9:02 AM, Andrew Dunstan wrote: This seems to me like the wrong fix. We don't want to create "no_such_user" I think, we just want to catch the Windows error message, as in this patch. Ignore this ... I'm clearly insufficiently caffeinated this morning. Despite the n

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-26 Thread Andrew Dunstan
On 2025-01-24 Fr 1:59 PM, Dagfinn Ilmari Mannsåker wrote: Tom Lane writes: Michael Paquier writes: On Thu, Jan 23, 2025 at 08:25:45PM +, Dagfinn Ilmari Mannsåker wrote: Here's a patch for that. Thanks. I had a bit of time today and applied it. BF member drongo doesn't like the new t

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-24 Thread Michael Paquier
On Fri, Jan 24, 2025 at 06:59:42PM +, Dagfinn Ilmari Mannsåker wrote: > Tom Lane writes: >> You might be able to work around this with auth_extra, >> a la 1e3f461e8 and other past fixes. Yes, forgot about this part with SSPI this time. Thanks for the poke. > Here's a (blind, but at least do

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-24 Thread Dagfinn Ilmari Mannsåker
Tom Lane writes: > Michael Paquier writes: >> On Thu, Jan 23, 2025 at 08:25:45PM +, Dagfinn Ilmari Mannsåker wrote: >>> Here's a patch for that. > >> Thanks. I had a bit of time today and applied it. > > BF member drongo doesn't like the new test for amcheck. > Looks like it has to do with

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-24 Thread Tom Lane
Michael Paquier writes: > On Thu, Jan 23, 2025 at 08:25:45PM +, Dagfinn Ilmari Mannsåker wrote: >> Here's a patch for that. > Thanks. I had a bit of time today and applied it. BF member drongo doesn't like the new test for amcheck. Looks like it has to do with SSPI authentication producing

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-23 Thread Michael Paquier
On Thu, Jan 23, 2025 at 08:25:45PM +, Dagfinn Ilmari Mannsåker wrote: > Here's a patch for that. Thanks. I had a bit of time today and applied it. - 'multiple -c options with different case'); + 'multiple ---set options with different case'); This description had one character i

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-23 Thread Dagfinn Ilmari Mannsåker
Michael Paquier writes: > Note that there are a few more under "Locale provider tests" in the > initdb tests. I've left that as a follow-up thing, that was already a > lot.. Here's a patch for that. - ilmari >From d787bf86ded9f66e12325a7460761d6d10fccbe0 Mon Sep 17 00:00:00 2001 From: =?UTF-8

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-22 Thread Michael Paquier
On Wed, Jan 22, 2025 at 03:34:11PM +, Dagfinn Ilmari Mannsåker wrote: > As I mentioned elsewhere in the thread, I left those alone since the > error message uses the short spelling even if the command had the long > one. We could add the long spelling to the preceding comments, like the > seco

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-22 Thread Dagfinn Ilmari Mannsåker
Hi Michael, Thanks for committing! Michael Paquier writes: > On Tue, Jan 21, 2025 at 02:17:03PM +, Dagfinn Ilmari Mannsåker wrote: >> Thanks again for reviewing this monster patch. > > +$node->command_checks_all( > + [ 'pg_amcheck', '--exclude-user' => 'no_such_user', 'postgres' ], > > Ex

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-21 Thread Michael Paquier
On Tue, Jan 21, 2025 at 02:17:03PM +, Dagfinn Ilmari Mannsåker wrote: > Thanks again for reviewing this monster patch. +$node->command_checks_all( + [ 'pg_amcheck', '--exclude-user' => 'no_such_user', 'postgres' ], Extra error spotted here with s/--exclude-user/--username/. The double --ve

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-21 Thread Dagfinn Ilmari Mannsåker
Michael Paquier writes: > On Tue, Jan 21, 2025 at 10:31:01AM +1100, Peter Smith wrote: >> I applied the v5* patches and ran make check-world. All passed OK. >> >> Your fat comma changes have greatly improved readability, particularly >> in 040_createsubscriber (the file that caused me to start t

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-20 Thread Michael Paquier
On Tue, Jan 21, 2025 at 10:31:01AM +1100, Peter Smith wrote: > I applied the v5* patches and ran make check-world. All passed OK. > > Your fat comma changes have greatly improved readability, particularly > in 040_createsubscriber (the file that caused me to start this > thread). Thanks! It is no

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-20 Thread Michael Paquier
On Mon, Jan 20, 2025 at 09:02:42PM -0500, Tom Lane wrote: > Nah, I'm pretty much -1 on bumping our perltidy version frequently. > That imposes costs on every developer who wants to track it. > It's unlikely that anyone will be on a platform that updates it > exactly when we decide to change, so mos

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-20 Thread Tom Lane
=?utf-8?Q?Dagfinn_Ilmari_Manns=C3=A5ker?= writes: > All in all, this makes me +0.5 to bumping the required Perl::Tidy > version, and +0.5 on (at least considering) bumping it to the latest > version before the pre-release-branch pgperltidy run. Nah, I'm pretty much -1 on bumping our perltidy vers

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-20 Thread Dagfinn Ilmari Mannsåker
"Euler Taveira" writes: > On Mon, Jan 20, 2025, at 7:49 PM, Tom Lane wrote: >> "Euler Taveira" writes: >> > It is kind of annoying to keep version 20230309 around to run perltidy. Do >> > we >> > have any other alternatives? >> >> As it says in src/tools/pgindent/README: >> >> 2) Install perl

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-20 Thread Peter Smith
On Tue, Jan 21, 2025 at 8:10 AM Dagfinn Ilmari Mannsåker wrote: > > Hi Peter, > > Peter Smith writes: > > > On Fri, Dec 13, 2024 at 5:03 AM Dagfinn Ilmari Mannsåker > > wrote: > >> > >> On Thu, 12 Dec 2024, at 17:52, Andrew Dunstan wrote: > >> > On 2024-12-12 Th 12:08 PM, Dagfinn Ilmari Mannsåke

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-20 Thread Euler Taveira
On Mon, Jan 20, 2025, at 7:49 PM, Tom Lane wrote: > "Euler Taveira" writes: > > It is kind of annoying to keep version 20230309 around to run perltidy. Do > > we > > have any other alternatives? > > As it says in src/tools/pgindent/README: > > 2) Install perltidy. Please be sure it is version

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-20 Thread Tom Lane
"Euler Taveira" writes: > It is kind of annoying to keep version 20230309 around to run perltidy. Do we > have any other alternatives? As it says in src/tools/pgindent/README: 2) Install perltidy. Please be sure it is version 20230309 (older and newer versions make different formatting choic

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-20 Thread Euler Taveira
On Mon, Jan 20, 2025, at 5:42 PM, Dagfinn Ilmari Mannsåker wrote: > Peter Smith writes: > > > > > In your v4 patch, there is a fragment (below) that replaces a double > > '--verbose' switch with just a single '--verbose'. > > > > As I have only recently learned, the '--verbose'' switch has a > >

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-20 Thread Dagfinn Ilmari Mannsåker
Hi Peter, Peter Smith writes: > Hi, > > In your v4 patch, there is a fragment (below) that replaces a double > '--verbose' switch with just a single '--verbose'. > > As I have only recently learned, the '--verbose'' switch has a > cumulative effect [1], so the original double '--verbose' was pr

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-13 Thread Peter Smith
On Fri, Dec 13, 2024 at 12:17 AM Dagfinn Ilmari Mannsåker wrote: > > Dagfinn Ilmari Mannsåker writes: > > > Peter Smith writes: > > > >> On Thu, Dec 12, 2024 at 2:53 PM Michael Paquier > >> wrote: > >> ... > >> > >>> > So, AFAICT I can workaround the perltidy wrapping just by putting all > >>>

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2025-01-12 Thread Peter Smith
On Fri, Dec 13, 2024 at 5:03 AM Dagfinn Ilmari Mannsåker wrote: > > On Thu, 12 Dec 2024, at 17:52, Andrew Dunstan wrote: > > On 2024-12-12 Th 12:08 PM, Dagfinn Ilmari Mannsåker wrote: > >> > >> command_ok( > >> [ > >> 'pg_dump', > >> ('--schema', 'pg_catalog'), > >>

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2024-12-12 Thread Peter Smith
On Fri, Dec 13, 2024 at 5:03 AM Dagfinn Ilmari Mannsåker wrote: > > On Thu, 12 Dec 2024, at 17:52, Andrew Dunstan wrote: > > On 2024-12-12 Th 12:08 PM, Dagfinn Ilmari Mannsåker wrote: > >> > >> command_ok( > >> [ > >> 'pg_dump', > >> ('--schema', 'pg_catalog'), > >>

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2024-12-12 Thread Michael Paquier
On Thu, Dec 12, 2024 at 06:03:33PM +, Dagfinn Ilmari Mannsåker wrote: > On Thu, 12 Dec 2024, at 17:52, Andrew Dunstan wrote: >> I'd rather get rid of those and just use the long options. > > Yeah, that is more self-documenting, so I'll do that while I'm at it. Agreed. I tend to prefer long

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2024-12-12 Thread Dagfinn Ilmari Mannsåker
On Thu, 12 Dec 2024, at 17:52, Andrew Dunstan wrote: > On 2024-12-12 Th 12:08 PM, Dagfinn Ilmari Mannsåker wrote: >> >> command_ok( >> [ >> 'pg_dump', >> ('--schema', 'pg_catalog'), >> ('-f', $outputdir . '/catalogs_primary.dump'), >> '--no-s

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2024-12-12 Thread Andrew Dunstan
On 2024-12-12 Th 12:08 PM, Dagfinn Ilmari Mannsåker wrote: Tom Lane writes: Andrew Dunstan writes: On 2024-12-12 Th 8:17 AM, Dagfinn Ilmari Mannsåker wrote: Here's a more thorough patch, that also applies the fat comma treatment to other pg_createsubscriber invocations in the same file th

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2024-12-12 Thread Dagfinn Ilmari Mannsåker
Tom Lane writes: > Andrew Dunstan writes: >> On 2024-12-12 Th 8:17 AM, Dagfinn Ilmari Mannsåker wrote: >>> Here's a more thorough patch, that also applies the fat comma treatment >>> to other pg_createsubscriber invocations in the same file that don't >>> currently happen to be mangled by perlti

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2024-12-12 Thread Tom Lane
Andrew Dunstan writes: > On 2024-12-12 Th 8:17 AM, Dagfinn Ilmari Mannsåker wrote: >> Here's a more thorough patch, that also applies the fat comma treatment >> to other pg_createsubscriber invocations in the same file that don't >> currently happen to be mangled by perltidy. It also adds trailin

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2024-12-12 Thread Andrew Dunstan
On 2024-12-12 Th 8:17 AM, Dagfinn Ilmari Mannsåker wrote: Dagfinn Ilmari Mannsåker writes: Peter Smith writes: On Thu, Dec 12, 2024 at 2:53 PM Michael Paquier wrote: ... So, AFAICT I can workaround the perltidy wrapping just by putting all the noarg options at the bottom of the command,

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2024-12-12 Thread Dagfinn Ilmari Mannsåker
Dagfinn Ilmari Mannsåker writes: > Peter Smith writes: > >> On Thu, Dec 12, 2024 at 2:53 PM Michael Paquier wrote: >> ... >> >>> > So, AFAICT I can workaround the perltidy wrapping just by putting all >>> > the noarg options at the bottom of the command, then all the >>> > option/optarg pairs (

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2024-12-12 Thread Dagfinn Ilmari Mannsåker
Peter Smith writes: > On Thu, Dec 12, 2024 at 2:53 PM Michael Paquier wrote: > ... > >> > So, AFAICT I can workaround the perltidy wrapping just by putting all >> > the noarg options at the bottom of the command, then all the >> > option/optarg pairs (ie 2s) will stay together. I can post anothe

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2024-12-12 Thread Alvaro Herrera
On 2024-Dec-12, Michael Paquier wrote: > On Thu, Dec 12, 2024 at 03:24:42PM +1100, Peter Smith wrote: > > PSA v2-0001. This time it can survive pgperltidy unchanged. > > Confirmed. It looks to apply cleanly to v17 as well. Better to > backpatch to avoid conflict frictions, even if it's cosmetic

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2024-12-11 Thread Michael Paquier
On Thu, Dec 12, 2024 at 03:24:42PM +1100, Peter Smith wrote: > PSA v2-0001. This time it can survive pgperltidy unchanged. Confirmed. It looks to apply cleanly to v17 as well. Better to backpatch to avoid conflict frictions, even if it's cosmetic. > In passing I also removed the duplicated '--v

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2024-12-11 Thread Peter Smith
On Thu, Dec 12, 2024 at 2:53 PM Michael Paquier wrote: ... > > So, AFAICT I can workaround the perltidy wrapping just by putting all > > the noarg options at the bottom of the command, then all the > > option/optarg pairs (ie 2s) will stay together. I can post another > > patch to do it this way

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2024-12-11 Thread Michael Paquier
On Thu, Dec 12, 2024 at 02:13:40PM +1100, Peter Smith wrote: > TBH, I have no idea what logic perltidy uses. I did find some > configurations here [1] (are those what it pgperltidy uses?) but those > claim max line length is 78 which I didn't come anywhere near > exceeding. Gave up trying to under

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2024-12-11 Thread Peter Smith
On Thu, Dec 12, 2024 at 1:46 PM Tom Lane wrote: > > Peter Smith writes: > > The strange thing is there are other commands in that file very > > similar to the ones I had changed but those already looked good, yet > > they remained unaffected by the pgperltidy. Why? > > You sure it's not just luck

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2024-12-11 Thread Tom Lane
Peter Smith writes: > The strange thing is there are other commands in that file very > similar to the ones I had changed but those already looked good, yet > they remained unaffected by the pgperltidy. Why? You sure it's not just luck-of-the-draw? I think that perltidy is just splitting the lin

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2024-12-11 Thread Peter Smith
On Thu, Dec 12, 2024 at 12:41 PM Tom Lane wrote: > > Peter Smith writes: > > While reviewing a patch for another pg_createsubscriber thread I found > > that multiple TAP tests have a terrible wrapping where the command > > options and their associated oparg are separated on different lines > > in

Re: pg_createsubscriber TAP test wrapping makes command options hard to read.

2024-12-11 Thread Tom Lane
Peter Smith writes: > While reviewing a patch for another pg_createsubscriber thread I found > that multiple TAP tests have a terrible wrapping where the command > options and their associated oparg are separated on different lines > instead of paired together nicely. This makes it unnecessarily >

pg_createsubscriber TAP test wrapping makes command options hard to read.

2024-12-11 Thread Peter Smith
Hi, While reviewing a patch for another pg_createsubscriber thread I found that multiple TAP tests have a terrible wrapping where the command options and their associated oparg are separated on different lines instead of paired together nicely. This makes it unnecessarily difficult to see what the