Higher level FTP lib?

Peter Haight peterh at sapros.com
Fri Jun 11 22:20:02 EDT 1999

>I wonder if there is a FTP module for python that allows for higher
>level operations than ftplib. With ftplib, I have to parse LIST lines
>myself (footnote: is there a module for *that* like perl's
>File::Listine?) if I want to know file size or date.

You could use urllib instead. It works like this:

import urllib
file = urllib.urlopen('ftp://ftp.python.org/pub/python/src/py152.tgz')

The file object you get back is pretty much the same as a file object you
would get from an open() command.

More information about the Python-list mailing list