duncs / clusterssh

Cluster SSH - Cluster Admin Via SSH
https://github.com/duncs/clusterssh/wiki
890 stars 79 forks source link

Test::PerlTidy dependency is problematic #110

Closed eserte closed 5 years ago

eserte commented 5 years ago

The test suite of Test::PerlTidy is currently broken (see https://rt.cpan.org/Ticket/Display.html?id=127688 ) and it does not look like it will be fixed soon. Test::PerlTidy is currently marked as a build_requires dependency, so installing cssh out of the box is not possible anymore. I wonder if the dependency could be changed into a author/developer-only dependency, and the perltidy test skipped for "normal" users if Test::PerlTidy is not installed.

eserte commented 5 years ago

I see that the perltidy test is already skipped if Test::PerlTidy is missing.

So Test::PerlTidy should just be made into an optional dependency.

For my installations, I am now applying a patch through the following CPAN.pm distropref file: https://github.com/eserte/srezic-cpan-distroprefs/blob/master/App-ClusterSSH.yml

duncs commented 5 years ago

Are you able to easily try out the recent developer release I did?  duncs/clusterssh - https://github.com/duncs/clusterssh/archive/v4.13.2_01.tar.gz I am in the process of swapping over to using dzil and one of the changes was to improve/remove the author dependancies   Duncs

|

duncs/clusterssh

Cluster SSH - Cluster Admin Via SSH. Contribute to duncs/clusterssh development by creating an account on GitHub. |

|

|

On Saturday, 5 January 2019, 15:03:33 GMT, Slaven Rezić <notifications@github.com> wrote:  

I see that the perltidy test is already skipped if Test::PerlTidy is missing.

So Test::PerlTidy should just be made into an optional dependency.

For my installations, I am now applying a patch through the following distropref file: https://github.com/eserte/srezic-cpan-distroprefs/blob/master/App-ClusterSSH.yml

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or mute the thread.

eserte commented 5 years ago

Downloaded and extracted tarball and tried:

$ cpan -t .
...
Running Build for /tmp/clusterssh-4.13.2_01/.
Could not read metadata file. Falling back to other methods to determine prerequisites
Building App-ClusterSSH
Using perl binary: /usr/bin/perl
Using perl version v5.26.1
Generating: /tmp/clusterssh-4.13.2_01/bin_PL/cssh
Getopt::Long version 2.5 required--this is only version 2.49 at /usr/share/perl/5.26/Getopt/Long.pm line 1549.
BEGIN failed--compilation aborted at /tmp/clusterssh-4.13.2_01/bin_PL/../lib/App/ClusterSSH/Getopt.pm line 19.
Compilation failed in require at /tmp/clusterssh-4.13.2_01/bin_PL/../lib/App/ClusterSSH.pm line 37.
BEGIN failed--compilation aborted at /tmp/clusterssh-4.13.2_01/bin_PL/../lib/App/ClusterSSH.pm line 37.
Compilation failed in require at /tmp/clusterssh-4.13.2_01/bin_PL/cssh line 9.
BEGIN failed--compilation aborted at /tmp/clusterssh-4.13.2_01/bin_PL/cssh line 9.
Failed to generate pod at bin_PL/_build_docs line 39.
bin_PL/_build_docs failed at /usr/share/perl5/Module/Build/Base.pm line 2942.
  /tmp/clusterssh-4.13.2_01/.
  ./Build -- NOT OK

This is the system perl on Ubuntu 18.04.

With a newer perl things go farther, but the test suite still fails:

t/boilerplate.t ... couldn't open README for reading: No such file or directory at t/boilerplate.t line 9.
# Looks like your test exited with 2 before it could output anything.
t/boilerplate.t ... Dubious, test returned 2 (wstat 512, 0x200)
Failed 3/3 subtests 
duncs commented 5 years ago

Can you try again with https://github.com/duncs/clusterssh/archive/v4.13.2_02.tar.gz please? The tests passed on a clean and fresh install of FC29 for me

eserte commented 5 years ago

With dzil or just with Build.PL? I tried the latter and still got the same error about a missing README (which is indeed not in the tarball).

duncs commented 5 years ago

Just Build.PL should be enough - I didn't get any errors about the README - I'll go over it again and use your cpan -t . method as I just used perl Build.PL ; ./Build ; ./Build test previously

duncs commented 5 years ago

I think I just worked out the issue - the .tar.gz I upload to cpan is different to the tar.gz that github allows you to download

Can you try https://cpan.metacpan.org/authors/id/D/DU/DUNCS/App-ClusterSSH-4.13.2_02.tar.gz and I'll try to work out how my method of using github releases can be improved

eserte commented 5 years ago

Already tested on my smokers and it looks good: http://matrix.cpantesters.org/?dist=App-ClusterSSH%204.13.2_02;reports=1

mic6061 commented 5 years ago

Hi duncs, eserte,

I had the same issue with the Test::PerlTidy dependancy. My original installation is blocked by

perl Build.PL
Checking prerequisites...
  build_requires:
    !  Test::PerlTidy is not installed

ERRORS/WARNINGS FOUND IN PREREQUISITES.  You may wish to install the versions
of the modules indicated above before proceeding with this installation

Run 'Build installdeps' to install missing prerequisites.

Created MYMETA.yml and MYMETA.json
Creating new 'Build' script for 'App-ClusterSSH' version '4.13'

Stacktrace of Test::PerlTidy

...
t/exclude_perltidy.t .. 4/11 # Looks like you failed 1 test of 11.
t/exclude_perltidy.t .. Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/11 subtests
t/is_file_tidy.t ...... ok
t/list_files.t ........ ok
t/perltidy.t .......... 1/11 # The file 'lib/Test/PerlTidy.pm' is not tidy
...

Test Summary Report
-------------------
t/exclude_perltidy.t (Wstat: 256 Tests: 11 Failed: 1)
  Failed test:  2
  Non-zero exit status: 1
t/perltidy.t        (Wstat: 256 Tests: 11 Failed: 1)
  Failed test:  2
  Non-zero exit status: 1
Files=9, Tests=26,  5 wallclock secs ( 0.05 usr  0.05 sys +  3.44 cusr  1.61 csys =  5.15 CPU)
Result: FAIL
Failed 2/9 test programs. 2/26 subtests failed.
make: *** [Makefile:857: test_dynamic] Error 255
  LARRYL/Test-PerlTidy-20130104.tar.gz
  /usr/bin/make test -- NOT OK
//hint// to see the cpan-testers results for installing this module, try:
  reports LARRYL/Test-PerlTidy-20130104.tar.gz

For further information : I am on windows 7 with cygwin installed on it. Sadly i tried your package https://cpan.metacpan.org/authors/id/D/DU/DUNCS/App-ClusterSSH-4.13.2_02.tar.gz but it doen't function cause some dependancies like XML::Simple or XML::Parser won't install with stuff like this : /usr/lib/perl5/5.26/x86_64-cygwin-threads/CORE/reentr.h:104:17: erreur fatale: crypt.h : No such file or directory

I tried also my older installation of cssh App-ClusterSSH-4.13 that was done on my windows 10 without any problems but here with the same issue. Regards

duncs commented 5 years ago

I believe crypt.h should be provided by a package such as libc6-dev (from my Debian system). Do you have this package installed?

mic6061 commented 5 years ago

Hello the library was wrong.The good one is libcrypt-devel-2.1-1 It works now Thx

sanjay92-gupta commented 4 years ago

I think I just worked out the issue - the .tar.gz I upload to cpan is different to the tar.gz that github allows you to download

Can you try https://cpan.metacpan.org/authors/id/D/DU/DUNCS/App-ClusterSSH-4.13.2_02.tar.gz and I'll try to work out how my method of using github releases can be improved

On Cygwin Win 10 Even I do cpan XML::Simple ( still same issue)

I have also tried other versions but some other issues like some thing else is not installed $ perl Build.PL Checking prerequisites... requires: ! XML::Simple is not installed

ERRORS/WARNINGS FOUND IN PREREQUISITES. You may wish to install the versions of the modules indicated above before proceeding with this installation

Run 'Build installdeps' to install missing prerequisites.

Created MYMETA.yml and MYMETA.json Creating new 'Build' script for 'App-ClusterSSH' version 'v4.13.202'

sanjay92-gupta commented 4 years ago

I have installed expat in cygwin and it looks like I am able to compile now

sanjay92-gupta commented 4 years ago

./Build was fine

$ ./Build test t/00-load.t .............. ok
t/01l10n.t ............... ok
t/02base.t ............... ok
t/05getopts.t ............ ok
t/10host.t ............... ok
t/15config.t ............. 88/?

Failed test 'died ok'

at t/15config.t line 505.

got: 'return'

expected: 'die'

Failed test 'Expecting no STDERR'

at t/15config.t line 508.

got: 'Moved $HOME/.csshrc to $HOME/.csshrc.DISABLED

Created new configuration file within $HOME/.clusterssh/

'

expected: ''

Failed test 'Expected die msg Moved $HOME/.csshrc to $HOME/.csshrc.DISABLED

Created new configuration file within $HOME/.clusterssh/

'

at t/15config.t line 509.

got: undef

expected: 'Unable to create directory $HOME/.clusterssh: Permission denied

'

Looks like you failed 3 tests of 155.

t/15config.t ............. Dubious, test returned 3 (wstat 768, 0x300) Failed 3/155 subtests t/20helper.t ............. ok
t/30cluster.t ............ ok
t/80clusterssh.t ......... ok
t/author-pod-coverage.t .. skipped: these tests are for testing by the author t/author-pod-syntax.t .... skipped: these tests are for testing by the author t/boilerplate.t .......... ok
t/changes.t .............. ok
t/pod-coverage.t ......... ok
t/pod.t .................. ok
t/range.t ................ ok

Test Summary Report

t/05getopts.t (Wstat: 0 Tests: 175 Failed: 0) TODO passed: 160-163, 168-171 t/15config.t (Wstat: 768 Tests: 155 Failed: 3) Failed tests: 142, 145-146 Non-zero exit status: 3 Files=16, Tests=1974, 74 wallclock secs ( 0.11 usr 0.34 sys + 3.93 cusr 13.72 csys = 18.10 CPU) Result: FAIL Failed 1/16 test programs. 3/1974 subtests failed.

duncs commented 4 years ago

That is because permissions work differently on windows - I will amend the test to ignore that error at some point On Friday, 27 December 2019, 20:04:59 GMT, sanjay92-gupta notifications@github.com wrote:

./Build was fine

$ ./Build test t/00-load.t .............. ok t/01l10n.t ............... ok t/02base.t ............... ok t/05getopts.t ............ ok t/10host.t ............... ok t/15config.t ............. 88/?

Failed test 'died ok'

at t/15config.t line 505.

got: 'return'

expected: 'die'

Failed test 'Expecting no STDERR'

at t/15config.t line 508.

got: 'Moved $HOME/.csshrc to $HOME/.csshrc.DISABLED

Created new configuration file within $HOME/.clusterssh/

'

expected: ''

Failed test 'Expected die msg Moved $HOME/.csshrc to $HOME/.csshrc.DISABLED

Created new configuration file within $HOME/.clusterssh/

'

at t/15config.t line 509.

got: undef

expected: 'Unable to create directory $HOME/.clusterssh: Permission denied

'

Looks like you failed 3 tests of 155.

t/15config.t ............. Dubious, test returned 3 (wstat 768, 0x300) Failed 3/155 subtests t/20helper.t ............. ok t/30cluster.t ............ ok t/80clusterssh.t ......... ok t/author-pod-coverage.t .. skipped: these tests are for testing by the author t/author-pod-syntax.t .... skipped: these tests are for testing by the author t/boilerplate.t .......... ok t/changes.t .............. ok t/pod-coverage.t ......... ok t/pod.t .................. ok t/range.t ................ ok

Test Summary Report

t/05getopts.t (Wstat: 0 Tests: 175 Failed: 0) TODO passed: 160-163, 168-171 t/15config.t (Wstat: 768 Tests: 155 Failed: 3) Failed tests: 142, 145-146 Non-zero exit status: 3 Files=16, Tests=1974, 74 wallclock secs ( 0.11 usr 0.34 sys + 3.93 cusr 13.72 csys = 18.10 CPU) Result: FAIL Failed 1/16 test programs. 3/1974 subtests failed.

— You are receiving this because you modified the open/close state.

Reply to this email directly, view it on GitHub, or unsubscribe.