Skip Menu |

This queue is for tickets about the Parallel-Prefork CPAN distribution.

Report information
The Basics
Id: 113449
Status: open
Priority: 0/
Queue: Parallel-Prefork

People
Owner: Nobody in particular
Requestors: ppisar [...] redhat.com
SREZIC [...] cpan.org
Cc: gregoa [...] cpan.org
AdminCc:

Bug Information
Severity: (no value)
Broken in:
  • 0.18
  • 0.17
Fixed in: (no value)



Subject: Time races in tests
Many tests, like t/04-interval.t relies on precise timing that cannot be guaranteed. E.g. I encountered this failure on an overloaded machine: t/03-spareworkers.t ...................... ok # Failed test 'workers at 6 sec' # at t/04-interval.t line 30. # got: '0' # expected: '1' # Looks like you failed 1 test of 6. t/04-interval.t .......................... Dubious, test returned 1 (wstat 256, 0x100) Failed 1/6 subtests The reason is a CPU scheduler may delay process execution more then the various "sleep" calls specify and then the test will fail. CPAN test matrix <http://matrix.cpantesters.org/?dist=Parallel-Prefork+0.18> displays many failures in other tests. Can the tests be improved to eliminate the inherent races?
We're also seeing intermittent test failures in Debian: https://bugs.debian.org/786592 Cheers, gregor
On 2016-11-26 10:01:36, GREGOA wrote: Show quoted text
> We're also seeing intermittent test failures in Debian: > > https://bugs.debian.org/786592 >
I tried to find out the reason for very frequent test failures of t/01-base.t on my FreeBSD smokers. The problem seems to be that the TERM signal handler may not be installed in all workers at the time of sending SIGTERM to the parent. Here's a simple patch which moves the unlocking after setup of the TERM handler. It seems to be effective on my smokers: http://cpan.metacpan.org/authors/id/S/SR/SREZIC/patches/Parallel-Prefork-0.18-RT113449.patch