Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw

POE module error

by rkg (Hermit)
on Mar 12, 2004 at 11:02 UTC ( #336116=perlquestion: print w/replies, xml ) Need Help??

rkg has asked for the wisdom of the Perl Monks concerning the following question:

Experimenting with POE for the first time, I tried the web page fetcher example from the poe cookbook. This is on a win xp box. While the example runs, it also prints an error
Can't locate object method "host" via package "URI::_foreign" at E:/ap +ps/perl/site/lib/POE /Component/Client/ line 280.
How do I remedy this error? I'm not sure what module(s) I need to install, update, or use. Thanks


Replies are listed 'Best First'.
Re: POE module error
by Tomte (Priest) on Mar 12, 2004 at 12:28 UTC

    As far as I followed the URI implementation, URI::_foreign is the used implementation-type, if there's no 'scheme' part (like http, https, ftp, ...).

    URI::_foreign does indeed not implement a host method, onle URI::_server does.

    This error occurs as ...Client::HTTP tries to get host, port and scheme from the request-uri.

    Assuming that POE::Component::Client::HTTP is working, I'd say you can't remedy this error by updating any module, the error is either in the webpage, providing wrong URLs, or in the crawler, instantiating the client in the wrong way...

    just my $0.02...


    Hlade's Law:

    If you have a difficult task, give it to a lazy person --
    they will find an easier way to do it.

Re: POE module error
by Anonymous Monk on Mar 12, 2004 at 20:41 UTC
    Consider posting your question to, and including your code verbatim -- just in the the event that you (innocently) deviated from the original code.

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://336116]
Approved by Old_Gray_Bear
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (4)
As of 2023-06-06 10:16 GMT
Find Nodes?
    Voting Booth?
    How often do you go to conferences?

    Results (26 votes). Check out past polls.