Subject: | PageRank fails with utf8 enabled |
Turning utf-8 encoding on (intentionally or as a side-effect of using
another module) causes WWW::Google::PageRank to fail, even if the URL
being fetched doesn't contain any international characters. The
checksum value that gets sent to Google is different.
e.g. this works:
/usr/bin/perl -MWWW::Google::PageRank -e 'print
WWW::Google::PageRank->new->get("http://www.google.com") . "\n"'
but this doesn't (returns undef, Google returns a 403 Forbidden):
/usr/bin/perl -MWWW::Google::PageRank -e 'use encoding utf8; print
WWW::Google::PageRank->new->get("http://www.google.com") . "\n"'
but changing to iso-8859-1 does work:
/usr/bin/perl -MWWW::Google::PageRank -e 'use encoding qw/iso-8859-1/;
print WWW::Google::PageRank->new->get("http://www.google.com") . "\n"'
Using perl 5.8.5.