Skip Menu |

This queue is for tickets about the Pod-Tidy CPAN distribution.

Report information
The Basics
Id: 51281
Status: open
Priority: 0/
Queue: Pod-Tidy

People
Owner: Nobody in particular
Requestors: CEBJYRE [...] cpan.org
Cc: SREZIC [...] cpan.org
AdminCc:

Bug Information
Severity: (no value)
Broken in: 0.10
Fixed in: (no value)



Subject: Process test (06) fails on OS X
Running the tests on OS X (10.5.8; Perl 5.8.8) results in it hanging once it gets to t/06_pod_tidy_process_pod_queue.t (in fact, on my system it doesn't display anything after: t/05_pod_tidy_build_pod_queue.t .... ok ) From a bit of poking around it looks like the hangpoint is the flock call at line 85 of Pod/Tidy.pm (in process_pod_queue).
Hello, Is this issue still reproducable? Thanks, -Josh --
On Sun Feb 12 02:00:54 2012, JHOBLITT wrote: Show quoted text
> Hello, > > Is this issue still reproducable? > > Thanks, > > -Josh > > --
Yep, still happening on 5.10.0 / OS X 10.6.8 (weird, I thought I had perlbrew running)
Is there any chance you could try a newer version of perl? If the problem is indeed with flock(), there's not much I can do to fix it. -Josh --
On Sun Feb 12 20:01:25 2012, JHOBLITT wrote: Show quoted text
> Is there any chance you could try a newer version of perl? If the > problem is indeed with flock(), there's not much I can do to fix it. > > -Josh > > --
Yep, still happens with 5.14.2 (from perlbrew)
Subject: Re: [rt.cpan.org #51281] Process test (06) fails on OS X
Date: Sun, 12 Feb 2012 23:15:04 -0700
To: bug-Pod-Tidy [...] rt.cpan.org
From: Joshua Hoblitt <josh [...] hoblitt.com>
Dang. I don't have an OSX dev/test system anymore some I'm going to have to hunt for a shell account to reproduce this. -Josh --
On Sun Feb 12 23:27:43 2012, CEBJYRE wrote: Show quoted text
> Yep, still happens with 5.14.2 (from perlbrew)
Just to confirm I also see this on 5.14.2 on OS X (Mountain Lion) [Not on 5.16.x because other parts of my toolchain break :-( ]
Subject: Re: [rt.cpan.org #51281] Process test (06) fails on OS X
Date: Fri, 07 Sep 2012 08:59:27 -0700
To: bug-Pod-Tidy [...] rt.cpan.org
From: Joshua Hoblitt <jhoblitt [...] cpan.org>
OK - let me see if I can get access to a mountan lion box for testing. -Josh --
The problem can be traced to the fact that OSX actually enables O_EXLOCK whereas on my linux systems Fcntl::O_EXLOCK is missing. You can reproduce the hang with this code: use File::Temp; use Fcntl ':flock'; my $tmpfile = File::Temp->new(); open(my $t, '+<', $tmpfile->filename) or warn "can't open file: $!"; print "About to lock\n"; flock( $t, LOCK_EX ); print "Locked\n"; With the problem being that File::Temp creates locked temp files if it can do so. When Pod::Tidy comes along and tries to reopen the file it can't get the lock because the temp file is still open. The simplest solution is to close the temp file. I'll sort out a pull request on github.
A simpler solution to this would be to add EXLOCK => 0 to the File::Temp->new calls. Either way though, would it be possible to get a new release with one of the fixes in place?
And this is still present on perl 5.20.0 (built with perlbrew).
Still present on 5.22.0 (also built with perlbrew)
The problem exists also on FreeBSD systems, and probably on other BSD variants, too (O_EXLOCK is a BSD thing).
On Thu Aug 13 02:12:52 2015, SREZIC wrote: Show quoted text
> The problem exists also on FreeBSD systems, and probably on other BSD > variants, too (O_EXLOCK is a BSD thing).
The problem persists up through at least perl-5.27.11. Today I was testing this library against that version on perl on FreeBSD-11.1, using 'cpanm' as the installer. The 'cpanm' process timed out after 30 minutes. When I ran each file through 'prove' indvidually, I found that the hangups occurred in: * t/06_pod_tidy_process_pod_queue.t: lines 19-78 * t/08_pod_tidy_tidy_files.t: lines 19-137 Please address this problem. Otherwise, we'll have to exclude this distribution from the "top of CPAN river" list of libraries we plan to test against development versions of perl in the upcoming development cycle. Thank you very much. Jim Keenan
On Sat May 19 21:20:11 2018, JKEENAN wrote: Show quoted text
> On Thu Aug 13 02:12:52 2015, SREZIC wrote:
> > The problem exists also on FreeBSD systems, and probably on other BSD > > variants, too (O_EXLOCK is a BSD thing).
> > The problem persists up through at least perl-5.27.11. Today I was > testing this library against that version on perl on FreeBSD-11.1, > using 'cpanm' as the installer. The 'cpanm' process timed out after > 30 minutes. When I ran each file through 'prove' indvidually, I found > that the hangups occurred in: > > * t/06_pod_tidy_process_pod_queue.t: lines 19-78 > > * t/08_pod_tidy_tidy_files.t: lines 19-137 > > Please address this problem. Otherwise, we'll have to exclude this > distribution from the "top of CPAN river" list of libraries we plan to > test against development versions of perl in the upcoming development > cycle. >
The problem persists with perl-5.28.0-RC2. Testing once again on FreeBSD-11.1, I got a similar hang. I eventually managed to run t/06 through the debugger and narrowed down the point at which the hang began to: ##### Pod::Tidy::process_pod_queue(lib/Pod/Tidy.pm:82): 82: open(my $src, '+<', $filename) or warn "can't open file: $!" && next; DB<5> Pod::Tidy::process_pod_queue(lib/Pod/Tidy.pm:85): 85: flock($src, LOCK_EX); #####
RT-Send-CC: jhoblitt [...] cpan.org, josh [...] hoblitt.com
On 2018-06-13 22:16:37, JKEENAN wrote: Show quoted text
> On Sat May 19 21:20:11 2018, JKEENAN wrote:
> > On Thu Aug 13 02:12:52 2015, SREZIC wrote:
> > > The problem exists also on FreeBSD systems, and probably on other > > > BSD > > > variants, too (O_EXLOCK is a BSD thing).
> > > > The problem persists up through at least perl-5.27.11. Today I was > > testing this library against that version on perl on FreeBSD-11.1, > > using 'cpanm' as the installer. The 'cpanm' process timed out after > > 30 minutes. When I ran each file through 'prove' indvidually, I > > found > > that the hangups occurred in: > > > > * t/06_pod_tidy_process_pod_queue.t: lines 19-78 > > > > * t/08_pod_tidy_tidy_files.t: lines 19-137 > > > > Please address this problem. Otherwise, we'll have to exclude this > > distribution from the "top of CPAN river" list of libraries we plan > > to > > test against development versions of perl in the upcoming development > > cycle. > >
> > The problem persists with perl-5.28.0-RC2. Testing once again on > FreeBSD-11.1, I got a similar hang. I eventually managed to run t/06 > through the debugger and narrowed down the point at which the hang > began to: > > ##### > Pod::Tidy::process_pod_queue(lib/Pod/Tidy.pm:82): > 82: open(my $src, '+<', $filename) or warn "can't open > file: $!" && next; > DB<5> > Pod::Tidy::process_pod_queue(lib/Pod/Tidy.pm:85): > 85: flock($src, LOCK_EX); > #####
A possible patch for this problem: http://cpan.cpantesters.org/authors/id/S/SR/SREZIC/patches/Pod-Tidy-0.10-RT51281.patch CPAN.pm users may use the following distroprefs file for automatic patching: https://github.com/eserte/srezic-cpan-distroprefs/blob/master/Pod-Tidy.yml
RT-Send-CC: jhoblitt [...] cpan.org, josh [...] hoblitt.com
On 2018-06-14 02:07:31, SREZIC wrote: Show quoted text
> On 2018-06-13 22:16:37, JKEENAN wrote:
> > On Sat May 19 21:20:11 2018, JKEENAN wrote:
> > > On Thu Aug 13 02:12:52 2015, SREZIC wrote:
> > > > The problem exists also on FreeBSD systems, and probably on other > > > > BSD > > > > variants, too (O_EXLOCK is a BSD thing).
> > > > > > The problem persists up through at least perl-5.27.11. Today I was > > > testing this library against that version on perl on FreeBSD-11.1, > > > using 'cpanm' as the installer. The 'cpanm' process timed out > > > after > > > 30 minutes. When I ran each file through 'prove' indvidually, I > > > found > > > that the hangups occurred in: > > > > > > * t/06_pod_tidy_process_pod_queue.t: lines 19-78 > > > > > > * t/08_pod_tidy_tidy_files.t: lines 19-137 > > > > > > Please address this problem. Otherwise, we'll have to exclude this > > > distribution from the "top of CPAN river" list of libraries we plan > > > to > > > test against development versions of perl in the upcoming > > > development > > > cycle. > > >
> > > > The problem persists with perl-5.28.0-RC2. Testing once again on > > FreeBSD-11.1, I got a similar hang. I eventually managed to run t/06 > > through the debugger and narrowed down the point at which the hang > > began to: > > > > ##### > > Pod::Tidy::process_pod_queue(lib/Pod/Tidy.pm:82): > > 82: open(my $src, '+<', $filename) or warn "can't open > > file: $!" && next; > > DB<5> > > Pod::Tidy::process_pod_queue(lib/Pod/Tidy.pm:85): > > 85: flock($src, LOCK_EX); > > #####
> > A possible patch for this problem: > http://cpan.cpantesters.org/authors/id/S/SR/SREZIC/patches/Pod-Tidy- > 0.10-RT51281.patch
There are two more files where EXLOCK=>0 has to be used. Please use this revised patch instead: http://cpan.cpantesters.org/authors/id/S/SR/SREZIC/patches/Pod-Tidy-0.10-RT51281-2.patch Show quoted text
> CPAN.pm users may use the following distroprefs file for automatic > patching: > https://github.com/eserte/srezic-cpan-distroprefs/blob/master/Pod- > Tidy.yml