[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#55441: [cuirass] hang in "In progress..."; runs out of pgsql connect
From: |
Maxim Cournoyer |
Subject: |
bug#55441: [cuirass] hang in "In progress..."; runs out of pgsql connections |
Date: |
Mon, 16 May 2022 08:49:28 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) |
Hi Ludo and Mathieu!
Ludovic Courtès <ludo@gnu.org> writes:
> Hi!
>
> Mathieu Othacehe <othacehe@gnu.org> skribis:
>
>> I noticed this error: https://ci.guix.gnu.org/eval/320682/log/raw.
>>
>> The following lines can be caused by having a multi-threaded program:
>> (cuirass scripts evaluate) because of its par-for-each procedure, call
>> "primitive-fork" in open-bidirectional-pipe of (guix inferior).
>>
>> warning: call to primitive-fork while multiple threads are running;
>> further behavior unspecified. See "Processes" in the
>> manual, for more information.
>>
>> Not sure that it could cause the observed hang, Ludo what do you think?
>
> As you write, the warning comes from ‘open-bidirectional-pipe’, added in
> commit bd86bbd300474204878e927f6cd3f0defa1662a5. I noticed it back then
> but as far as I could see, it was harmless (but definitely suboptimal):
>
> https://issues.guix.gnu.org/48007#11
Thanks for investigating it!
I'm not yet very knowledgeable about POSIX threads and shortcomings, but
this looks like a dangerous trap to have lying around :-). Is there an
alternative implementation we could come up with that would avoid the
potential problem (and warnings) entirely?
Otherwise, if we are sure there are no practical problems in a
multi-threaded scenario, I think a comment explaining the reasoning in
the code (of why it's considered safe despite the warnings) and a test
exercising the behavior would be in order to ensure it continues working
as intended in the face of changes.
Thoughts?
Thanks again,
Maxim
- bug#55441: [cuirass] hang in "In progress..."; runs out of pgsql connections, (continued)
- bug#55441: [PATCH] guix: inferior: Make open-bidirectional-pipe use piped-process., Josselin Poiret, 2022/05/26
- bug#55441: [PATCH] guix: inferior: Make open-bidirectional-pipe use piped-process., Maxime Devos, 2022/05/26
- bug#55441: [PATCH] guix: inferior: Make open-bidirectional-pipe use piped-process., Ludovic Courtès, 2022/05/28
- bug#55441: [cuirass] hang in "In progress..."; runs out of pgsql connections, Maxime Devos, 2022/05/26
- bug#55441: [cuirass] hang in "In progress..."; runs out of pgsql connections, Josselin Poiret, 2022/05/28
- bug#55441: [cuirass] hang in "In progress..."; runs out of pgsql connections, Ludovic Courtès, 2022/05/26
- bug#55441: [cuirass] hang in "In progress..."; runs out of pgsql connections,
Maxim Cournoyer <=
- bug#55441: [cuirass] hang in "In progress..."; runs out of pgsql connections, Ludovic Courtès, 2022/05/17