PEP on path module for standard library

John Roth newsgroups at
Fri Jul 22 18:55:13 CEST 2005

"Daniel Dittmar" <daniel.dittmar at sap.corp> wrote in message 
news:dbr79q$ftg$1 at
> Duncan Booth wrote:
>>  I would have expected a path object to be a sequence of path elements 
>> rather than a sequence of characters.
> Maybe it's nitpicking, but I don't think that a path object should be a 
> 'sequence of path elements' in an iterator context.
> This means that
> for element in pathobject:
> has no intuitive meaning for me, so it shouldn't be allowed.

However, a path as a sequence of characters has even less
meaning - I can't think of a use, while I have an application
where traversing a path as a sequence of path elements makes
perfect sense: I need to descend the directory structure, directory
by directory, looking for specific files and types.

John Roth
> Daniel 

More information about the Python-list mailing list