Subject: | ReportVersions fails when modules have conflicting symbols |
Marked as critical because the plugin cannot be used at all when two or
more modules conflict.
The ReportVersions plugin seems to be importing symbols from all modules
into one package. Mayhem ensues when two or more modules export
conflicting symbols.
t/000-report-versions.t .... 2/? # Moose version is 1.12
# Failed test 'use MooseX::Role::Parameterized;'
# at t/000-report-versions.t line 440.
# Tried to use 'MooseX::Role::Parameterized'.
# Error: You already have a &meta function, but it does not return
a Moose::Meta::Role at
/sw/lib/perl5/site_perl/5.10.0/darwin-thread-multi-2level/Moose/Role.pm
line 125
# Moose::Role::init_meta('Moose::Role', 'metaclass',
'MooseX::Role::Parameterized::Meta::Role::Parameterizable', 'for_class',
'main') called at
/sw/lib/perl5/site_perl/5.10.0/MooseX/Role/Parameterized.pm line 49
# MooseX::Role::Parameterized::init_meta('MooseX::Role::Parameterized',
'for_class', 'main', 'metaclass', undef) called at
/sw/lib/perl5/site_perl/5.10.0/darwin-thread-multi-2level/Moose/Exporter.pm
line 355
# Moose::Exporter::__ANON__('MooseX::Role::Parameterized') called at
(eval 212) line 2
# main::BEGIN() called at
/sw/lib/perl5/site_perl/5.10.0/MooseX/Role/Parameterized.pm line 2
# eval {...} called at
/sw/lib/perl5/site_perl/5.10.0/MooseX/Role/Parameterized.pm line 2
# eval 'package main;
# use MooseX::Role::Parameterized @{$args[0]};
# 1;
#
# ;' called at /sw/lib/perl5-core/5.10.0/Test/More.pm line 858
# Test::More::_eval('package main;\x{a}use MooseX::Role::Parameterized
@{$args[0]};\x{a}1;\x{a}', 'ARRAY(0x826220)') called at
/sw/lib/perl5-core/5.10.0/Test/More.pm line 833
# Test::More::use_ok('MooseX::Role::Parameterized') called at
t/000-report-versions.t line 440
# main::BEGIN() called at
/sw/lib/perl5/site_perl/5.10.0/MooseX/Role/Parameterized.pm line 2
# eval {...} called at
/sw/lib/perl5/site_perl/5.10.0/MooseX/Role/Parameterized.pm line 2
# BEGIN failed--compilation aborted at (eval 212) line 2.
Bailout called. Further testing stopped: can't load
MooseX::Role::Parameterized
# Tests were run but no plan was declared and done_testing() was not seen.
FAILED--Further testing stopped: can't load MooseX::Role::Parameterized
make: *** [test_dynamic] Error 255
error running make test
.............
The above fails in exactly the same way as using conflicting modules:
% perl -wle 'use Moose; use MooseX::Role::Parameterized'
You already have a &meta function, but it does not return a
Moose::Meta::Role at
/sw/lib/perl5/site_perl/5.10.0/darwin-thread-multi-2level/Moose/Role.pm
line 125
Moose::Role::init_meta('Moose::Role', 'metaclass',
'MooseX::Role::Parameterized::Meta::Role::Parameterizable', 'for_class',
'main') called at
/sw/lib/perl5/site_perl/5.10.0/MooseX/Role/Parameterized.pm line 49
MooseX::Role::Parameterized::init_meta('MooseX::Role::Parameterized',
'for_class', 'main', 'metaclass', undef) called at
/sw/lib/perl5/site_perl/5.10.0/darwin-thread-multi-2level/Moose/Exporter.pm
line 355
Moose::Exporter::__ANON__('MooseX::Role::Parameterized') called at -e
line 1
main::BEGIN() called at
/sw/lib/perl5/site_perl/5.10.0/MooseX/Role/Parameterized.pm line 1
eval {...} called at
/sw/lib/perl5/site_perl/5.10.0/MooseX/Role/Parameterized.pm line 1
BEGIN failed--compilation aborted at -e line 1.