Skip Menu |

This queue is for tickets about the HTTP-Body CPAN distribution.

Report information
The Basics
Id: 25927
Status: resolved
Priority: 0/
Queue: HTTP-Body

People
Owner: Nobody in particular
Requestors: ANDK [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: "out of memory" with bleadperl
make[1]: Entering directory `/home/k/.cpan/build/HTTP-Body-0.9-n23Llm' PERL_DL_NONLAZY=1 /home/src/perl/repoperls/installed-perls/perl/pwn9B1a/perl-5.8.0@30777/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', 'blib/arch')" t/*.t t/01use............ok t/02pod............skipped all skipped: set TEST_POD to enable this test t/03podcoverage....skipped all skipped: set TEST_POD to enable this test t/04multipart......Out of memory! dubious Test returned status 0 (wstat 15, 0xf) DIED. FAILED tests 2-55 Failed 54/55 tests, 1.82% okay t/05urlencoded.....ok t/06octetstream....ok Failed Test Stat Wstat Total Fail List of Failed ------------------------------------------------------------------------------- t/04multipart.t 0 15 55 108 2-55 Maybe it is a YAML issue. Could it be difficult to rewrite the test so that it doesn't use YAML? OR at least use YAML::Syck if available? This is just a guess. Let me know if you need more information.
From: AGRUNDMA [...] cpan.org
On Thu Mar 29 22:59:42 2007, ANDK wrote: Show quoted text
> make[1]: Entering directory `/home/k/.cpan/build/HTTP-Body-0.9-n23Llm' > PERL_DL_NONLAZY=1 > /home/src/perl/repoperls/installed-perls/perl/pwn9B1a/perl- > 5.8.0@30777/bin/perl > "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', > 'blib/arch')" t/*.t > t/01use............ok > t/02pod............skipped > all skipped: set TEST_POD to enable this test > t/03podcoverage....skipped > all skipped: set TEST_POD to enable this test > t/04multipart......Out of memory! > dubious > Test returned status 0 (wstat 15, 0xf) > DIED. FAILED tests 2-55 > Failed 54/55 tests, 1.82% okay > t/05urlencoded.....ok > t/06octetstream....ok > Failed Test Stat Wstat Total Fail List of Failed >
------------------------------------------------------------------------------- Show quoted text
> t/04multipart.t 0 15 55 108 2-55 > > > > Maybe it is a YAML issue. Could it be difficult to rewrite the test so > that it doesn't use YAML? OR at least use YAML::Syck if available? > > This is just a guess. Let me know if you need more information.
Ouch, hmm, the tests do use a lot of YAML but certainly not enough to run out of memory I would think. Will try using YAML::Syck though.
I rewrote it to use YAML::Syck and the test passes.
On Thu Mar 29 23:30:56 2007, ANDK wrote: Show quoted text
> I rewrote it to use YAML::Syck and the test passes.
Can you send me a patch?
CC: ANDK [...] cpan.org
Subject: Re: [rt.cpan.org #25927] "out of memory" with bleadperl
Date: Fri, 30 Mar 2007 07:48:28 +0200
To: bug-HTTP-Body [...] rt.cpan.org
From: andreas.koenig.7os6VVqR [...] franz.ak.mind.de (Andreas J. Koenig)
Show quoted text
>>>>> On Fri, 30 Mar 2007 00:25:52 -0400, " via RT" <bug-HTTP-Body@rt.cpan.org> said:
Show quoted text
Show quoted text
> On Thu Mar 29 23:30:56 2007, ANDK wrote:
>> I rewrote it to use YAML::Syck and the test passes.
Show quoted text
> Can you send me a patch?
Well, this is not good enough for public use, because there is no fallback when there is no YAML: --- /home/k/.cpan/build/HTTP-Body-0.9-n23Llm/t/04multipart.t~ 2007-03-27 19:42:43.000000000 +0200 +++ /home/k/.cpan/build/HTTP-Body-0.9-n23Llm/t/04multipart.t 2007-03-30 05:29:23.000000000 +0200 @@ -9,15 +9,15 @@ use HTTP::Body; use File::Spec::Functions; use IO::File; -use YAML; +use YAML::Syck; my $path = catdir( getcwd(), 't', 'data', 'multipart' ); for ( my $i = 1; $i <= 11; $i++ ) { my $test = sprintf( "%.3d", $i ); - my $headers = YAML::LoadFile( catfile( $path, "$test-headers.yml" ) ); - my $results = YAML::LoadFile( catfile( $path, "$test-results.yml" ) ); + my $headers = YAML::Syck::LoadFile( catfile( $path, "$test-headers.yml" ) ); + my $results = YAML::Syck::LoadFile( catfile( $path, "$test-results.yml" ) ); my $content = IO::File->new( catfile( $path, "$test-content.dat" ) ); my $body = HTTP::Body->new( $headers->{'Content-Type'}, $headers->{'Content-Length'} ); Maybe you could convert to perl code with Data::Dumper. I use this oneliner in my Makefile.PL, sorry for the many backslashes but I fear if I remove them, I make mistakes: push @m, qq{$base.dd : Makefile \$(PERL) -MYAML::Syck=LoadFile -MData::Dumper -e '\$\$x=shift; \@y=LoadFile("\$\$x.yml"); print Data::Dumper->new(\\\@y)->Indent(1)->Useqq(1)->Purity(1)->Dump' $base > $base.dd.new && mv $base.dd.new $base.dd }; -- andreas
I think this is rather a bug in perl. I ran your test through the debugger and it passes just fine. Given that YAML is a perl only module it should make no difference what the result is between debugger and normal environment. In any case, please do not delete AGRUNDMA/HTTP-Body-0.9.tar.gz from CPAN, so that I can point Perl5-porters to it. Your test case seems to be an interesting one. Thanks,
As time goes by, old bugs wash out. Thanks!