Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re^5: Protocol scheme 'http' is not supported

by Corion (Pope)
on Jul 28, 2012 at 15:40 UTC ( #984209=note: print w/ replies, xml ) Need Help??


in reply to Re^4: Protocol scheme 'http' is not supported
in thread Protocol scheme 'http' is not supported

I think all of this comes down to a botched install of LWP::UserAgent, which should include LWP::Protocol::http. Maybe explicitly installing LWP::Protocol or LWP::Protocol::http can get the situation unstuck, but I wonder how the other modules can pass their test suites when the most basic prerequisites are missing.

Maybe you are mixing two versions of Perl, and have half of the module installed on one version and half on the other? Mixing Perl module directories seems like it's always a recipe for bad interactions to me...


Comment on Re^5: Protocol scheme 'http' is not supported
Re^6: Protocol scheme 'http' is not supported
by Bloodnok (Vicar) on Jul 28, 2012 at 16:02 UTC
    Indeed Corion, hence my comment/guess.

    A user level that continues to overstate my experience :-))

      Corion/Bloodnok, Yeah, It seemed like it's all about modules gone wild. I've got the exact same code (not what I posted; I boiled it down to the fewest number of lines that still showed the problem) and version of Perl on a Windows machine with no problems there so I figured moving it over to Linux would be a breeze.

      I'll try forcing an install of LWP::UserAgent, LWP::Protocol, and/or LWP::Protocol::http and see what that does for me. Is there a way from inside of cpan (ie the "perl -MCPAN -e shell") to actually uninstall an existing module or is it a manual cd-to-the-directory-and-rename sort of thing...?

      Many thanks, Greg
        And the saga continues... When I run my little test case I get:
        Uncaught exception from user code: HTML::Parser object version 3.55 does not match bootstrap para +meter 3.69 at /usr/lib64/perl5/5.8.8/x86_64-linux-thread-multi/DynaLo +ader.pm line 253. Compilation failed in require at /usr/lib64/perl5/site_perl/5.8.8/x86_ +64-linux-thread-multi/HTML/Entities.pm line 152. Compilation failed in require at /usr/lib64/perl5/site_perl/5.8.8/x86_ +64-linux-thread-multi/HTML/TokeParser.pm line 9. BEGIN failed--compilation aborted at /usr/lib64/perl5/site_perl/5.8.8/ +x86_64-linux-thread-multi/HTML/TokeParser.pm line 9. Compilation failed in require at /usr/lib/perl5/site_perl/5.8.8/WWW/Me +chanize.pm line 134. BEGIN failed--compilation aborted at /usr/lib/perl5/site_perl/5.8.8/WW +W/Mechanize.pm line 134. Compilation failed in require at ./test2.pl line 6. BEGIN failed--compilation aborted at ./test2.pl line 6. at ./test2.pl line 6.
        So I went looking for Parser.pm and found these:
        $ sudo find /usr -name Parser.pm -exec ls -l {} \; -r--r--r-- 1 root root 39789 Oct 15 2011 /usr/lib64/perl5/site_perl/5 +.8.8/x86_64-linux-thread-multi/HTML/Parser.pm -rw-r--r-- 1 root root 39509 Jul 10 2006 /usr/lib64/perl5/vendor_perl +/5.8.8/x86_64-linux-thread-multi/HTML/Parser.pm -rw-r--r-- 1 root root 27103 Aug 18 2003 /usr/lib64/perl5/vendor_perl +/5.8.8/x86_64-linux-thread-multi/XML/Parser.pm
        Ah. So if I grep out the version from each of them I find:
        $ grep "VERSION =" /usr/lib64/perl5/site_perl/5.8.8/x86_64-linux-threa +d-multi/HTML/Parser.pm $VERSION = "3.69"; grep "VERSION =" /usr/lib64/perl5/vendor_perl/5.8.8/x86_64-linux-thre +ad-multi/HTML/Parser.pm $VERSION = '3.55'; # $Date: 2006/07/10 09:12:26 $
        And from perl -V the @INC is:
        @INC: /usr/lib64/perl5/site_perl/5.8.8/x86_64-linux-thread-multi /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl /usr/lib64/perl5/vendor_perl/5.8.8/x86_64-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl /usr/lib64/perl5/5.8.8/x86_64-linux-thread-multi /usr/lib/perl5/5.8.8
        At this point I went on to see what Task::Mechanistic would do for me... (see next reply)

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://984209]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (9)
As of 2014-08-01 06:29 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (257 votes), past polls