Skip Menu |

This queue is for tickets about the Git-Repository CPAN distribution.

Report information
The Basics
Id: 89086
Status: resolved
Priority: 0/
Queue: Git-Repository

People
Owner: Nobody in particular
Requestors: jhavero [...] gmail.com
Cc:
AdminCc:

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



Subject: symlink tests failing
Date: Mon, 30 Sep 2013 16:17:40 -0700
To: bug-Git-Repository [...] rt.cpan.org
From: Alex Raguero <jhavero [...] gmail.com>
Distribution: Git-Repository-1.308 Perl version: V5.10.0 Operating system: Red Hat Enterprise Linux Server release 5.4 (Tikanga) There are two symlink tests that are failing when I run 'make test': $ make test PERL_DL_NONLAZY=1 /tools/swdev/packages/perl/perl5.10.0/bin/perl5.10.0 "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', 'blib/arch')" t/*.t t/00-load.t ................... 1/7 # Tested Git::Repository 1.308, Perl 5.010000, /tools/swdev/packages/perl/perl5.10.0/bin/perl5.10.0 t/00-load.t ................... ok t/000-report-versions-tiny.t .. # # # Generated by Dist::Zilla::Plugin::ReportVersions::Tiny v1.08 # perl: 5.010000 (wanted 5.006) on linux from /tools/swdev/packages/perl/perl5.10.0/bin/perl5.10.0 # # Carp => 1.08 (want any version) # Config => <undef> (want any version) # Cwd => 3.2501 (want any version) # Exporter => 5.68 (want any version) # ExtUtils::MakeMaker => 6.62 (want 6.30) # File::Find => 1.12 (want any version) # File::Path => 2.04 (want any version) # File::Spec => 3.2501 (want any version) # File::Temp => 0.22 (want any version) # IO::Handle => 1.27 (want any version) # Scalar::Util => 1.27 (want any version) # System::Command => 1.05 (want 1.103) # Test::Builder => 0.98 (want any version) # Test::More => 0.98 (want 0.88) # constant => 1.13 (want any version) # overload => 1.06 (want any version) # strict => 1.04 (want any version) # version => 0.88 (want 0.9901) # warnings => 1.06 (want any version) # # Thanks for using my code. I hope it works for you. # If not, please try and include this output in the bug report. # That will help me reproduce the issue and solve your problem. # t/000-report-versions-tiny.t .. ok t/05-try_git.t ................ 1/28 # Testing _is_git with /tools/swdev/bin/git from /home/ealragu/Git-Repository-1.308 # Testing _is_git with ../../../tools/swdev/bin/git from /home/ealragu/Git-Repository-1.308 Use of uninitialized value $version in pattern match (m//) at /home/ealragu/Git-Repository-1.308/blib/lib/Git/Repository/Command.pm line 88. # Failed test 'symlink to git' # at t/05-try_git.t line 87. Use of uninitialized value $version in pattern match (m//) at /home/ealragu/Git-Repository-1.308/blib/lib/Git/Repository/Command.pm line 88. # Failed test 'symlink to git' # at t/05-try_git.t line 110. # Looks like you failed 2 tests of 28. t/05-try_git.t ................ Dubious, test returned 2 (wstat 512, 0x200) Failed 2/28 subtests t/06-version.t ................ # git version 1.7.3.1 t/06-version.t ................ ok t/07-version.t ................ ok t/10-new_fail.t ............... ok t/11-create.t ................. ok t/12-create.t ................. ok t/13-sudo.t ................... ok t/20-simple.t ................. ok t/21-submodule.t .............. ok t/22-backward.t ............... ok t/23-quiet.t .................. ok t/24-errors.t ................. ok t/25-plugins.t ................ ok t/26-overloaded_objects.t ..... ok t/30-log.t .................... ok t/40-plugin-log.t ............. ok t/41-multiline-log.t .......... ok t/release-distmeta.t .......... skipped: these tests are for release candidate testing t/release-pod-coverage.t ...... skipped: these tests are for release candidate testing t/release-pod-syntax.t ........ skipped: these tests are for release candidate testing Test Summary Report ------------------- t/05-try_git.t (Wstat: 512 Tests: 28 Failed: 2) Failed tests: 22, 28 Non-zero exit status: 2 Files=22, Tests=631, 6 wallclock secs ( 0.19 usr 0.02 sys + 2.83 cusr 2.02 csys = 5.06 CPU) Result: FAIL Failed 1/22 test programs. 2/631 subtests failed. make: *** [test_dynamic] Error 255
On Mon Sep 30 19:17:57 2013, jhavero@gmail.com wrote: Show quoted text
> Distribution: Git-Repository-1.308 > Perl version: V5.10.0 > Operating system: Red Hat Enterprise Linux Server release 5.4 (Tikanga) > > There are two symlink tests that are failing when I run 'make test': >
The weird thing is that the tests using a link to the git binary located at /tools/swdev/bin/git work fine, but when using a link that points to the same binary using a relative path (../../../tools/swdev/bin/git) then it doesn't work anymore. This warning: Show quoted text
> Use of uninitialized value $version in pattern match (m//) at > /home/ealragu/Git-Repository-1.308/blib/lib/Git/Repository/Command.pm line > 88.
seem to indicate that the call to git --version via this link does not even return the version string. Do you have some more details? Have you been able to reproduce the bug? -- BooK
On Sun Feb 02 11:42:43 2014, BOOK wrote: Show quoted text
> On Mon Sep 30 19:17:57 2013, jhavero@gmail.com wrote:
> > Distribution: Git-Repository-1.308 > > Perl version: V5.10.0 > > Operating system: Red Hat Enterprise Linux Server release 5.4 > > (Tikanga) > > > > There are two symlink tests that are failing when I run 'make test': > >
> > The weird thing is that the tests using a link to the git binary > located at /tools/swdev/bin/git work fine, but when using a link that > points to the same binary using a relative path > (../../../tools/swdev/bin/git) then it doesn't work anymore. > > This warning: >
> > Use of uninitialized value $version in pattern match (m//) at > > /home/ealragu/Git-Repository-1.308/blib/lib/Git/Repository/Command.pm > > line > > 88.
> > seem to indicate that the call to git --version via this link does not > even return the version string. > > Do you have some more details? Have you been able to reproduce the > bug?
I have finally been able to reproduce the bug. The issue is that when $PATH contains a component that is not an absolute path, the 'real' symlink (which is created two levels below the current working dir) does not point to the original git binary any more, because the $abs_git path we computed for it is relative (because of the $PATH component) instead of absolute (as assumed). The fix will be part of the next Git::Repository release. Many thanks for your report! -- BooK