file objects choices?

Lexy Zhitenev zhitenev at
Tue Mar 18 17:08:15 CET 2003

"e y suzuki" <suzuki-python at> wrote in message:
news:mailman.1047931167.5356.python-list at
> are there any existing python file i/o types that can be represented
> by file objects other than:
>     -direct files (regular, directories) specified for the open function
>     -stdin, stdout, stderr streams via sys module
>     -input from piped commands of output from program executed by os/
>         another program

I also widely use StringIO - represent strings as file-like objects. It is
useful to unzip files just downloaded. I mean, when I download a relatively
short zip file, I place its contents in a StringIO object and feed it to zip
module to extract the real contents.


More information about the Python-list mailing list