Hi ,
Thanks for the reply. I agree, 1Mb is pretty small as files sizes go....although on the large side for perl modules.
(btw: don't waste too much time on this...I generated the metrics on the failing file by removing all leading whitespace to drop filesize <1Mb...or works on linux)
Still it is a curious threshold, and repeatable on other modules...I've attached an example small, big with the only difference being comments.
I also show it failing on Tidy.pm (this is the only >1Mb .pm file in my perl installations.
I also installed on a linux box to test it there against the same files, but it ONLY fails on Windows.
Note that the perl on the linux box is 5.8.8.120, whereas the windows perl is 5.16.3.1603.
Thanks,
Steve
============= perl version exhibiting failure on Windows
12-Dec-13 08:31 AM 1,278,966 TestBigWebappUtil.pm - Only difference for this file is the addition of many comment lines to exceed 1Mb file size
C:\apps\devop_tools\Perl64\bin>perl.exe -ver
This is perl 5, version 16, subversion 3 (v5.16.3) built for MSWin32-x64-multi-thread
(with 1 registered patch, see perl -V for more detail)
Copyright 1987-2012, Larry Wall
Binary build 1603 [296746] provided by ActiveState
http://www.ActiveState.com
Built Mar 13 2013 13:31:10
C:\apps\devop_tools\Perl64\site\bin>countperl u:\scripts\TestBigWebappUtil.pm
Did not supply a document! at C:/apps/devop_tools/Perl64/site/lib/Perl/Metrics/Simple/Analysis/File.pm line 367.
Perl::Metrics::Simple::Analysis::File::_prune_non_code_lines(undef) called at C:/apps/devop_tools/Perl64/site/lib/Perl/Metrics/Simple/Analysis/File.pm line 160
Perl::Metrics::Simple::Analysis::File::_make_pruned_document(undef) called at C:/apps/devop_tools/Perl64/site/lib/Perl/Metrics/Simple/Analysis/File.pm line 109
Perl::Metrics::Simple::Analysis::File::_init('Perl::Metrics::Simple::Analysis::File=HASH(0x2fb53a8)', 'path', 'u:\scripts\TestBigWebappUtil.pm') called at C:/apps/devop_too
ls/Perl64/site/lib/Perl/Metrics/Simple/Analysis/File.pm line 86
Perl::Metrics::Simple::Analysis::File::new('Perl::Metrics::Simple::Analysis::File', 'path', 'u:\scripts\TestBigWebappUtil.pm') called at C:/apps/devop_tools/Perl64/site/lib
/Perl/Metrics/Simple.pm line 44
Perl::Metrics::Simple::analyze_files('Perl::Metrics::Simple=HASH(0x4f2d48)', 'u:\scripts\TestBigWebappUtil.pm') called at countperl line 97
main::set_analysis() called at countperl line 60
main::main() called at countperl line 53
==================== On smaller file it works fine
26-Sep-13 12:08 PM 2,548 WebappUtil.pm
C:\apps\devop_tools\Perl64\site\bin>countperl u:\scripts\WebappUtil.pm
Use of uninitialized value $value in concatenation (.) or string at countperl line 132. (this noise could be easily fixed)
Use of uninitialized value $value in concatenation (.) or string at countperl line 132.
Use of uninitialized value $value in concatenation (.) or string at countperl line 132.
Use of uninitialized value $value in concatenation (.) or string at countperl line 132.
Use of uninitialized value $value in concatenation (.) or string at countperl line 132.
Use of uninitialized value $value in concatenation (.) or string at countperl line 132.
Use of uninitialized value $value in concatenation (.) or string at countperl line 132.
Use of uninitialized value $value in concatenation (.) or string at countperl line 132.
Use of uninitialized value $value in concatenation (.) or string at countperl line 132.
Use of uninitialized value $value in concatenation (.) or string at countperl line 132.
Perl files found: 1
.
.
.
List of subroutines, with most complex at top
---------------------------------------------
complexity sub path size
1 {code not in named subroutines} u:\scripts\WebappUtil.pm 40
====================
==================== perl version succeeding on Linux --- Using same TestBigWebappUtil.pm file that failed on Windows above
Show quoted text > /plm/cinas/chucktestshare2/perl.d/as/perl/lnx64/bin/perl -ver
This is perl, v5.8.8 built for x86_64-linux-thread-multi
(with 30 registered patches, see perl -V for more detail)
Copyright 1987-2006, Larry Wall
Binary build 820 [274679] provided by ActiveState
http://www.ActiveState.com
Built Jan 22 2007 19:51:55
/plm/cinas/chucktestshare2/perl.d/as/perl/lnx64/site/bin> countperl /plm/cinas/chucktestshare2/perl.d/as/perl/lnx64/site/lib/Perl/Tidy.pm > /tmp/Tidy.pm.out
/plm/cinas/chucktestshare2/perl.d/as/perl/lnx64/site/bin> countperl /tmp/WebappUtil.pm > /tmp/WebappUtil.pm.out
/plm/cinas/chucktestshare2/perl.d/as/perl/lnx64/site/bin> countperl /tmp/TestBigWebappUtil.pm > /tmp/TestBigWebappUtil.pm.out
====================== Here's an example using a >1Mb CPAN module (only module in my perl installation >1Mb)
21-Aug-13 10:08 AM 1,115,493 Tidy.pm
C:\apps\devop_tools\Perl64\site\bin>countperl C:\apps\devop_tools\Perl64\site\lib\Perl\Tidy.pm
Did not supply a document! at C:/apps/devop_tools/Perl64/site/lib/Perl/Metrics/Simple/Analysis/File.pm line 367.
Perl::Metrics::Simple::Analysis::File::_prune_non_code_lines(undef) called at C:/apps/devop_tools/Perl64/site/lib/Perl/Metrics/Simple/Analysis/File.pm line 160
Perl::Metrics::Simple::Analysis::File::_make_pruned_document(undef) called at C:/apps/devop_tools/Perl64/site/lib/Perl/Metrics/Simple/Analysis/File.pm line 109
Perl::Metrics::Simple::Analysis::File::_init('Perl::Metrics::Simple::Analysis::File=HASH(0x306f238)', 'path', 'C:\apps\devop_tools\Perl64\site\lib\Perl\Tidy.pm') called at
C:/apps/devop_tools/Perl64/site/lib/Perl/Metrics/Simple/Analysis/File.pm line 86
Perl::Metrics::Simple::Analysis::File::new('Perl::Metrics::Simple::Analysis::File', 'path', 'C:\apps\devop_tools\Perl64\site\lib\Perl\Tidy.pm') called at C:/apps/devop_tool
s/Perl64/site/lib/Perl/Metrics/Simple.pm line 44
Perl::Metrics::Simple::analyze_files('Perl::Metrics::Simple=HASH(0x4f2de8)', 'C:\apps\devop_tools\Perl64\site\lib\Perl\Tidy.pm') called at countperl line 97
main::set_analysis() called at countperl line 60
main::main() called at countperl line 53
======================
Matisse Enzer via RT wrote:
Show quoted text> <URL:
https://rt.cpan.org/Ticket/Display.html?id=91129 >
>
> oops typo, I meant to write that 1 megabyte is NOT a very large file these days.
>
> On Tue Dec 10 10:55:01 2013, MATISSE wrote:
>
>> Also, 2^20 is exactly 1 megabyte ( 2^20 = 1048576 = 1024 * 1024) which
>> is very large as files go these days. Are you sure you are hitting
>> this with any file larger than that size?
>>
>> Can you attach an example of a failing file to this ticket?
>