This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author orsenthil
Recipients dcantrell-rh, dmorr, facundobatista, jjlee, orsenthil, skip.montanaro
Date 2009-01-02.05:29:39
SpamBayes Score 4.2670214e-09
Marked as misclassified No
Message-id <7c42eba10901012129qebc28dcsefa0cba09cec34c2@mail.gmail.com>
In-reply-to <1230869629.1.0.9760193206.issue1675455@psf.upfronthosting.co.za>
Content
> I am a little confused by this though. It looks like
> FileHandler.file_open() checks if there is a hostname in the URL, and
> if so, uses FTPHandler instead. So why does FileHandler.open_local_file
> check the hostname value?

You are right. Even I had observed this, but did not dispute it. Let
me try to look into the history to see why it so. Perhaps it needs to
change.

> For your other points, gethostbyname() in libc can only handle IPv4
> addresses. The IETF defined the getaddrinfo() interface as an IP
> version neutral replacement. I would recommend using getaddrinfo().
> Yes, FTPHandler creates an urllib.FTPWrapper object. That object calls
> into ftplib, which is already IPv6-capable. So, I don't think we need
> to do hostname resolution in FTPHandler.

Thanks for the info. I shall look into both in revision of the path.
1) using getaddrinfo() for IP version neutral call.
2) passing the hostname directly to ftplib. ( I am not sure of
consequences, need to investigate).
History
Date User Action Args
2009-01-02 05:29:50orsenthilsetrecipients: + orsenthil, skip.montanaro, facundobatista, jjlee, dcantrell-rh, dmorr
2009-01-02 05:29:47orsenthillinkissue1675455 messages
2009-01-02 05:29:41orsenthilcreate