Subject: | optional deps not so optional |
Date: | Tue, 15 Oct 2013 14:57:43 +0100 |
To: | bug-Devel-REPL [...] rt.cpan.org |
From: | Zefram <zefram [...] fysh.org> |
Devel-REPL declares (in META.{json,yml}) some `optional'
dependencies for plugins. In fact some of them (Lexical::Persistence,
Data::Dump::Streamer, PPI) are not really optional: their absence causes
an error even if the plugins are not explicitly invoked. For example:
$ /opt/perl-5.18.1/bin/re.pl
Failed to load role: Devel::REPL::Plugin::LexEnv Can't locate Lexical/Persistence.pm in @INC (you may need to install the Lexical::Persistence module) (@INC contains: /opt/perl-5.18.1/lib/site_perl/5.18.1/x86_64-linux-ld /opt/perl-5.18.1/lib/site_perl/5.18.1 /opt/perl-5.18.1/vendor/lib/vendor_perl/5.18.1/x86_64-linux-ld /opt/perl-5.18.1/vendor/lib/vendor_perl/5.18.1 /opt/perl-5.18.1/lib/5.18.1/x86_64-linux-ld /opt/perl-5.18.1/lib/5.18.1 .) at /opt/perl-5.18.1/lib/site_perl/5.18.1/Devel/REPL/Plugin/LexEnv.pm line 13.
BEGIN failed--compilation aborted at /opt/perl-5.18.1/lib/site_perl/5.18.1/Devel/REPL/Plugin/LexEnv.pm line 13.
Compilation failed in require at /opt/perl-5.18.1/lib/site_perl/5.18.1/Devel/REPL/Script.pm line 48.
at /opt/perl-5.18.1/lib/site_perl/5.18.1/MooseX/Object/Pluggable.pm line 235.
MooseX::Object::Pluggable::_load_and_apply_role(Moose::Meta::Class::__ANON__::SERIAL::5=HASH(0x2df7c00), "Devel::REPL::Plugin::LexEnv") called at /opt/perl-5.18.1/lib/site_perl/5.18.1/MooseX/Object/Pluggable.pm line 170
MooseX::Object::Pluggable::load_plugins(Moose::Meta::Class::__ANON__::SERIAL::5=HASH(0x2df7c00), "LexEnv") called at /opt/perl-5.18.1/lib/site_perl/5.18.1/MooseX/Object/Pluggable.pm line 181
MooseX::Object::Pluggable::load_plugin(Moose::Meta::Class::__ANON__::SERIAL::5=HASH(0x2df7c00), "LexEnv") called at /opt/perl-5.18.1/lib/site_perl/5.18.1/Devel/REPL/Profile/Minimal.pm line 20
Devel::REPL::Profile::Minimal::apply_profile(Devel::REPL::Profile::Minimal=HASH(0x2df5a48), Moose::Meta::Class::__ANON__::SERIAL::5=HASH(0x2df7c00)) called at /opt/perl-5.18.1/lib/site_perl/5.18.1/Devel/REPL/Script.pm line 48
Devel::REPL::Script::load_profile(Devel::REPL::Script=HASH(0x1ab0078), "Minimal") called at /opt/perl-5.18.1/lib/site_perl/5.18.1/Devel/REPL/Script.pm line 38
Devel::REPL::Script::BUILD(Devel::REPL::Script=HASH(0x1ab0078), HASH(0x283c7b0)) called at /opt/perl-5.18.1/lib/site_perl/5.18.1/x86_64-linux-ld/Class/MOP/Method.pm line 125
Class::MOP::Method::execute(Moose::Meta::Method=HASH(0x1ad9418), Devel::REPL::Script=HASH(0x1ab0078), HASH(0x283c7b0)) called at /opt/perl-5.18.1/lib/site_perl/5.18.1/x86_64-linux-ld/Moose/Object.pm line 59
Moose::Object::BUILDALL(Devel::REPL::Script=HASH(0x1ab0078), HASH(0x283c7b0)) called at /opt/perl-5.18.1/lib/site_perl/5.18.1/x86_64-linux-ld/Moose/Meta/Class.pm line 288
Moose::Meta::Class::new_object(Moose::Meta::Class=HASH(0x26eb028), HASH(0x283c7b0)) called at /opt/perl-5.18.1/lib/site_perl/5.18.1/x86_64-linux-ld/Moose/Object.pm line 28
Moose::Object::new("Devel::REPL::Script", "ARGV", ARRAY(0x26f4278), "extra_argv", ARRAY(0x26f4218), "usage", Getopt::Long::Descriptive::Usage=HASH(0x2cb4100)) called at /opt/perl-5.18.1/lib/site_perl/5.18.1/MooseX/Getopt/Basic.pm line 112
MooseX::Getopt::Basic::new_with_options("Devel::REPL::Script") called at /opt/perl-5.18.1/lib/site_perl/5.18.1/Devel/REPL/Script.pm line 96
Devel::REPL::Script::import("Devel::REPL::Script", "run") called at /opt/perl/bin/re.pl line 4
These dependencies should be either genuinely optional or declared as
hard deps.
-zefram