Skip Menu |
 

This queue is for tickets about the RPC-XML CPAN distribution.

Report information
The Basics
Id: 47219
Status: resolved
Priority: 0/
Queue: RPC-XML

People
Owner: rjray [...] blackperl.com
Requestors: kmx [...] volny.cz
Cc:
AdminCc:

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



Subject: Broken detection whether we have Compress::Zlib
Date: Sun, 21 Jun 2009 22:39:18 +0200
To: bug-RPC-XML [...] rt.cpan.org
From: kmx <kmx [...] volny.cz>
Download (untitled) / with headers
text/plain 361b
Hi, I have found out (in RPC-XML-0.65) that client.t fails when I have not installed Compress::Zlib The following patch to RPC/XML/Client.pm solves this issue: # Check for compression support $self->{__compress} = ''; - eval 'require "Compress::Zlib"'; + eval "require Compress::Zlib"; $self->{__compress} = $@ ? '' : 'deflate'; -- kmx
Subject: Re: [rt.cpan.org #47219] AutoReply: Broken detection whether we have Compress::Zlib
Date: Mon, 22 Jun 2009 08:10:56 +0200
To: bug-RPC-XML [...] rt.cpan.org
From: kmx <kmx [...] volny.cz>
Download (untitled) / with headers
text/plain 453b
... and probably the similar issue in RPC/XML/Server.pm unless ($args{no_compress}) { + eval 'require "Compress::Zlib"'; - eval "require Compress::Zlib"; eval "require Compress::Zlib"; $self->{__compress} = $@ ? '' : 'deflate'; Generaly you have to use: require "Modulename::In::Quotation::Marks" if you want to catch unavailable module. See http://www.perl.com/doc/manual/html/pod/perlfunc/require.html -- kmx
Download (untitled) / with headers
text/plain 551b
Oddly, both files already had that change to the eval lines. Are you sure you were looking at the most-current versions? Either way, I re-did those tests so that they're done once, in a BEGIN block, and not repeated every time new() is called. The "require" would be (mostly) a no-op, but the trinary test doesn't need to execute every time... -- """"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" Randy J. Ray Silicon Valley Scale Modelers: http://www.svsm.org rjray@blackperl.com randy.j.ray@gmail.com
Subject: Re: [rt.cpan.org #47219] Broken detection whether we have Compress::Zlib
Date: Thu, 09 Jul 2009 21:03:19 +0200
To: bug-RPC-XML [...] rt.cpan.org
From: kmx <kmx [...] volny.cz>
Download (untitled) / with headers
text/plain 812b
Hi, I have taken the latest version from your Git repository In order to make all tests pass on Win32 without Compress::Zlib I have to patch *./lib/RPC/XML/Server.pm *and *./lib/RPC/XML/Client.pm* by changing the original line (in both files in BEGIN block): *eval "require Compress::Zlib";* into this form: *eval 'require "Compress::Zlib"'; * According to http://www.perl.com/doc/manual/html/pod/perlfunc/require.html the required module name should be in quotation marks if we want to catch the complain about not finding the module. With the above described patch all tests pass on Win32/strawberry/5.8.9. I have also tried Win32/strawberry/5.10.0 but I have a problem with installing Scalar::Util upgrade to 1.2, without this RPC::XML tests hang up. I will try to investigate further details. -- kmx
Download (untitled) / with headers
text/plain 397b
D'oh! I mid-read the patch, and since it was just one line I thought to "apply" it by hand. But since I mid-read it, I got it wrong. Looks like 0.67 will be coming out sooner than I thought! -- """"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" Randy J. Ray Silicon Valley Scale Modelers: http://www.svsm.org rjray@blackperl.com randy.j.ray@gmail.com
Download (untitled) / with headers
text/plain 406b
OK, 0.67 should get it right, now. I've added a new test suite to specifically test the detection of Compress::Zlib, including faking it's absence so that I test both detection AND non-detection :-). -- """"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" Randy J. Ray Silicon Valley Scale Modelers: http://www.svsm.org rjray@blackperl.com randy.j.ray@gmail.com
Download (untitled) / with headers
text/plain 205b
-- """"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" Randy J. Ray Silicon Valley Scale Modelers: http://www.svsm.org rjray@blackperl.com randy.j.ray@gmail.com


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.