bug with decoded_content() if response header does not contain Content-Encoding [rt.cpan.org #92475]
oalders opened this issue · comments
Olaf Alders commented
Migrated from rt.cpan.org#92475 (status was 'open')
Requestors:
From shenzhongqiang@msn.com on 2014-01-26 01:55:50:
The bug exists in 6.06, but not in 6.02.
If the response header does not have a Content-Encoding header, decoded_content() returns nothing.
I am using perl5.10
From bunder@t-25.ru on 2015-08-08 05:34:47:
Same behaviour with v6.10 on Perl v5.22.0. Test [1] does not work.
Response is obtained using LWP::UserAgent->new->get("file://$Bin/data/UTF-8.html"). It has no Content-Encoding headers. But HTML in content has one.
[1] http://cpansearch.perl.org/src/VANSTYN/Email-MIME-CreateHTML-1.041/t/UTF-8_html.t
From srezic@cpan.org on 2015-08-08 15:22:08:
On 2015-08-08 01:34:47, bunder@t-25.ru wrote:
> Same behaviour with v6.10 on Perl v5.22.0. Test [1] does not work.
>
> Response is obtained using LWP::UserAgent->new-
> >get("file://$Bin/data/UTF-8.html"). It has no Content-Encoding
> headers. But HTML in content has one.
>
> [1] http://cpansearch.perl.org/src/VANSTYN/Email-MIME-CreateHTML-
> 1.041/t/UTF-8_html.t
Maybe the failure depends on a particular environment? The CPAN Testers fail/pass overview http://fast-matrix.cpantesters.org/?dist=Email-MIME-CreateHTML%201.041 shows only 2� FAILs.
From bunder@t-25.ru on 2015-08-12 04:47:07:
On Aug 08 11:22:08 2015, SREZIC wrote:
> Maybe the failure depends on a particular environment? The CPAN
> Testers fail/pass overview http://fast-
> matrix.cpantesters.org/?dist=Email-MIME-CreateHTML%201.041 shows only
> 2� FAILs.
Ok, I've found the problem. IO::HTML was not installed on my system, however HTTP::Message depends on it at runtime. I've filed a bug to packager [1]. With IO::HTML installed test passes.
[1] https://bugs.archlinux.org/task/45960
With respect,
Anton Leontiev
Julien Fiegehenn commented
IO::HTML is in HTTP::Message's required modules. This can be closed as it's outside of scope.
Olaf Alders commented
Thanks @simbabque!