MichaelDaum / spreadsheet-parsexlsx

parse XLSX files
http://metacpan.org/release/Spreadsheet-ParseXLSX
1 stars 3 forks source link

Can't locate object method "method" via package "next" #14

Closed gavinehlers closed 5 months ago

gavinehlers commented 5 months ago

The latest version 0.34 triggers the following error:

Can't locate object method "method" via package "next" (perhaps you forgot to load "next"?) at /usr/lib/perl5/site_perl/5.38.2/Spreadsheet/ParseXLSX/Worksheet.pm line 22.

perl version v5.38.2

Code:

#!/usr/bin/perl -w

use Spreadsheet::ParseXLSX;

my $parser   = Spreadsheet::ParseXLSX->new();
my $workbook = $parser->parse('Book1.xlsx');
MichaelDaum commented 5 months ago

Hm, confirmed. However all tests pass.

MichaelDaum commented 5 months ago

Test::More seems to enable mro. However the thing should work even without. see https://metacpan.org/pod/mro#next::method.

Quick fix for your would be to "use mro;"

Will replace it with the more standard SUPER way of calling parents.

gavinehlers commented 5 months ago

Thanks Michael - I can confirm that your proposed temporary solution works.