From: Tom Lane <tgl@sss.pgh.pa.us>
To: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
Cc: Michael Paquier <michael@paquier.xyz>
Cc: Andrew Dunstan <andrew@dunslane.net>
Cc: pgsql-committers@lists.postgresql.org
Subject: Re: pgsql: Close stdin where it's not needed in TestLib.pm procedures
Date: Tue, 26 Nov 2019 15:30:54 -0500
Message-ID: <24716.1574800254@sss.pgh.pa.us> (raw)
In-Reply-To: <f4191724-423b-73e8-c91b-ee4057161cf3@2ndquadrant.com>
References: <E1iZLUQ-0006Kb-MM@gemulon.postgresql.org>
<20191126044302.GC5435@paquier.xyz>
<f4191724-423b-73e8-c91b-ee4057161cf3@2ndquadrant.com>
Peter Eisentraut <peter.eisentraut@2ndquadrant.com> writes:
> On 2019-11-26 05:43, Michael Paquier wrote:
>> This one is causing failures with the TAP tests of initdb on all AIX
>> animals and prairiedog:
>> # Running: initdb --help
>> Can't locate IO/Pty.pm in @INC (@INC contains: ../../../src/test/perl/
>> . /usr/local/perl5.8.3/lib/5.8.3/darwin-2level
>> [...]
>> Unexpected SCALAR(0x1987690) in harness() parameter 7 at
>> ../../../src/test/perl//TestLib.pm line 692
> I'm also seeing this problem on macOS in
> src/test/recovery/t/016_min_consistency.pl .
I just noticed that my buildfarm animal longfin has been stuck for
the past 24 hours in t/001_initdb.pl, and I can replicate that
in a manual build. ktrace says it's in some sort of loop.
Apparently, macOS has got IO::Pty but it doesn't actually work
the way this patch expects. Therefore, the proposed patch will
leave things still broken for macOS :-(
I tried this:
inline patch 1: src/test/perl/TestLib.pm (+1/-2 lines) download inline-1.patchdiff --git a/src/test/perl/TestLib.pm b/src/test/perl/TestLib.pmindex 18b4ce35c2..d67ffc4368 100644--- a/src/test/perl/TestLib.pm+++ b/src/test/perl/TestLib.pm@@ -192,8 +192,7 @@ INIT
}
else
{
- use charnames ':full';- @no_stdin = ('<pty<', \"\N{END OF TRANSMISSION}");+ @no_stdin = ('<pty<', \"");
}
}
and that seems to fix it. I wonder what's the point of sending
a nonempty string to the pty, exactly?
regards, tom lane
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-committers@postgresql.org
Cc: tgl@sss.pgh.pa.us, peter.eisentraut@2ndquadrant.com, michael@paquier.xyz, andrew@dunslane.net
Subject: Re: pgsql: Close stdin where it's not needed in TestLib.pm procedures
In-Reply-To: <24716.1574800254@sss.pgh.pa.us>
References: <E1iZLUQ-0006Kb-MM@gemulon.postgresql.org> <20191126044302.GC5435@paquier.xyz> <f4191724-423b-73e8-c91b-ee4057161cf3@2ndquadrant.com> <24716.1574800254@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox