perl-carton / carton

Bundler or pip freeze for Perl
http://search.cpan.org/dist/carton
Other
492 stars 96 forks source link

carton install --deployment doesn't work as expected #137

Closed zakame closed 11 years ago

zakame commented 11 years ago

Basically, I'm trying to run a (not so old) Amon2 app (https://github.com/zakame/BookList-Amon2) on my remote machine (with a near-pristine Perl 5.18.1 on plenv, Carton and its deps being the only other modules from CPAN.) Following the tutorial for carton on deployment, it doesn't seem to work as I expect:

[zakame:~/BookList-Amon2] master ± carton install --deployment
Installing modules using /home/zakame/BookList-Amon2/cpanfile (deployment mode)
Successfully installed Test-Requires-0.07
Successfully installed File-ShareDir-Install-0.04
Successfully installed URI-1.60
Successfully installed Devel-StackTrace-1.30
Successfully installed IO-HTML-1.00
Successfully installed Encode-Locale-1.03
Successfully installed LWP-MediaTypes-6.02
Successfully installed HTTP-Date-6.02
Successfully installed HTTP-Message-6.06
Successfully installed Test-Tester-0.109
Successfully installed Test-NoWarnings-1.04
Successfully installed Test-Deep-0.110
Successfully installed HTTP-Body-1.17
Successfully installed Filesys-Notify-Simple-0.12
Successfully installed Test-SharedFork-0.21
Successfully installed Test-TCP-2.00
Successfully installed Stream-Buffered-0.02
Successfully installed Class-Inspector-1.28
Successfully installed File-ShareDir-1.03
Successfully installed Devel-StackTrace-AsHTML-0.14
Successfully installed Try-Tiny-0.16
Successfully installed Apache-LogFormat-Compiler-0.13
Successfully installed Hash-MultiValue-0.15
Successfully installed Plack-1.0028
Successfully installed Class-Accessor-Lite-0.05
Successfully installed Router-Simple-0.14
Successfully installed Router-Simple-Sinatraish-0.03
Successfully installed MRO-Compat-0.12
Successfully installed ExtUtils-Config-0.007
Successfully installed ExtUtils-Helpers-0.021
Successfully installed ExtUtils-InstallPaths-0.009
Successfully installed Module-Build-Tiny-0.025
Successfully installed Digest-SHA1-2.13
Successfully installed Digest-HMAC-1.03
Successfully installed Plack-Middleware-Session-0.20
! Couldn't find module or a distribution Text::Xslate (1.6001)
! Installing the dependencies failed: Module 'Text::Xslate' is not installed
! Bailing out the installation for Amon2-3.85.
Successfully installed DBI-1.628
Successfully installed DBD-SQLite-1.40
Successfully installed HTML-FillInForm-Lite-1.13
Successfully installed JSON-2.59
Successfully installed Plack-Middleware-ReverseProxy-0.15
Successfully installed DBIx-TransactionManager-1.12
Successfully installed Sub-Uplevel-0.24
Successfully installed Test-Exception-0.32
Successfully installed Carp-Clan-6.04
Successfully installed Params-Util-1.07
Successfully installed Sub-Install-0.926
Successfully installed Data-OptList-0.108
Successfully installed Sub-Exporter-0.986
Successfully installed SQL-Interp-1.21
Successfully installed Amon2-DBI-0.32
Successfully installed Log-Minimal-0.14
Successfully installed Sub-Identify-0.04
Successfully installed Module-Functions-2.1.3
Successfully installed Module-Runtime-0.013
Successfully installed Module-Implementation-0.07
Successfully installed Test-Fatal-0.010
Successfully installed List-MoreUtils-0.33
Successfully installed Dist-CheckConflicts-0.09
Successfully installed Package-Stash-XS-0.28
Successfully installed Package-Stash-0.35
Successfully installed Class-Load-0.20
Successfully installed SQL-Maker-1.12
! Couldn't find module or a distribution Class::Accessor::Chained::Fast
! Installing the dependencies failed: Module 'Class::Accessor::Chained::Fast' is not installed
! Bailing out the installation for Data-Page-2.02.
Successfully installed Data-Page-NoTotalEntries-0.02
Successfully installed Test-Mock-Guard-0.09
Successfully installed DBIx-Inspector-0.12
! Installing the dependencies failed: Module 'Data::Page' is not installed
! Bailing out the installation for Teng-0.19.
Successfully installed HTML-Tagset-3.20
Successfully installed HTML-Parser-3.71
Successfully installed HTML-Tree-5.03
Successfully installed HTTP-Server-Simple-0.44
Successfully installed HTTP-Negotiate-6.01
Successfully installed WWW-RobotRules-6.02
Successfully installed File-Listing-6.04
Successfully installed HTTP-Daemon-6.01
Successfully installed HTTP-Cookies-6.01
Successfully installed Net-HTTP-6.06
Successfully installed libwww-perl-6.05
Successfully installed HTML-Form-6.03
Successfully installed Tree-DAG_Node-1.12
Successfully installed Test-Warn-0.24
Successfully installed WWW-Mechanize-1.72
Successfully installed Carp-Assert-0.20
Successfully installed Carp-Assert-More-1.14
Successfully installed Test-LongString-0.15
Successfully installed Test-WWW-Mechanize-1.44
Successfully installed Test-WWW-Mechanize-PSGI-0.35
! Installing the dependencies failed: Module 'Text::Xslate' is not installed, Module 'Teng' is not installed, Module 'Amon2' is not installed
! Bailing out the installation for /home/zakame/BookList-Amon2/.
85 distributions installed
Installing modules failed

The failed-to-install modules still exist on CPAN, so I suspect this could be more of a cpanm issue than carton?

[zakame@:~/BookList-Amon2] master 2 ± carton check
Following dependencies are not satisfied.
  Class::Accessor::Chained::Fast is not installed. Needs 0
  Text::Xslate is not installed. Needs 1.6001
  Module::CPANfile is not installed. Needs 0.9010
Run `carton install` to install them.
[zakame:~/BookList-Amon2] master 255 ± carton version
carton v1.0.10
zakame commented 11 years ago

OTOH, carton install works as expected (the cpanfile deps for Text::Xslate and Module::CPANfile is not strict, so the latest gets pull in, while I'm not even sure why Class::Accessor::Chained::Fast is listed in check (it doesn't show up in carton tree.)

[zakame:~/BookList-Amon2] master ± carton tree | grep Class
   Class::Inspector (Class-Inspector-1.28)
  Class::Accessor::Lite (Class-Accessor-Lite-0.05)
 Class::Load (Class-Load-0.20)
miyagawa commented 11 years ago

suspect this could be more of a cpanm issue than carton?

No it's not. The issue is that your snapshot doesn't have the information for xslate and Class::Accesor::Chained::Fast. The reason why carton install works is that it will fallback to CPAN, where as --deployment won't, which is the intended behavior.

miyagawa commented 11 years ago

re: CPANfile, i don't understand the configure requirement group in your cpanfile. I recommend you to delete them.

miyagawa commented 11 years ago

What version of carton are you using?

miyagawa commented 11 years ago

I tested locally with Text::Xslate and Class::Accessor::Chained with 5.18.1 and they get all package info correctly in snapshot.

zakame commented 11 years ago

As in the OP, I was using Carton v1.0.10 on the remote host. the snapshot file was generated over a month ago with Carton-dev pre 1.0 (in fact, last updated just a day shy of the official Carton v1.0 release.) I think that's where my trouble is :)

Thanks for clarifying!

zakame commented 11 years ago

BTW, the require on Module::CPANfile on configure was from Amon2 boilerplate, ping @tokuhirom