![]() |
|
"be consistent" | |
PerlMonks |
Re: Config::Any does not complain when Config::Tiny is not installedby rjt (Curate) |
on Oct 10, 2019 at 14:14 UTC ( #11107311=note: print w/replies, xml ) | Need Help?? |
Edit: It's definitely the use of force_plugins. Without that (i.e., with plugins instead), it will indeed error out if Config::Tiny is not present:
The problem is on Config::Any.pm:144:
That map { eval "require $_;" $_ } @... line always returns @{$args->{force_plugins}}, even if one or more modules don't load. I don't know if that is the intended behavior or not (doesn't seem like it, based on my very quick reading of the docs), so it might not hurt to bring it up with the module author(s). For now, you can work around the issue by guarding it in your own (calling) code: @plugins = grep { eval "require $_" } @plugins;... or raising an error if you want:
Original reply missed the point a bit. Config::Any::INI is part of the Config::Any distribution: Config::Any, and that does require Config::Tiny, which is specified under suggests in the Makefile.PL. Are you sure you don't have Config/Tiny.pm in your Perl install?
In Section
Seekers of Perl Wisdom
|
|