[path-PEP] Path inherits from basestring again
Robert Kern
rkern at ucsd.edu
Sat Jul 23 10:43:00 EDT 2005
Peter Hansen wrote:
> Under Linux isn't it possible to open and read from directories much as
> with files?
Not really, no.
Python 2.3.4 (#2, Jan 5 2005, 08:24:51)
[GCC 3.3.5 (Debian 1:3.3.5-5)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> d = open('/usr/bin')
Traceback (most recent call last):
File "<stdin>", line 1, in ?
IOError: [Errno 21] Is a directory
>>>
--
Robert Kern
rkern at ucsd.edu
"In the fields of hell where the grass grows high
Are the graves of dreams allowed to die."
-- Richard Harter
More information about the Python-list
mailing list