os.path.walk problem

Steve Holden sholden at holdenweb.com
Tue Aug 13 07:40:25 EDT 2002


"Terry Hancock" <hancock at anansispaceworks.com> wrote ...
> From: "Steve Holden" <sholden at holdenweb.com>
> > "Terry Hancock" <hancock at anansispaceworks.com> wrote ...
[os.path.walk() inconsistencies]
>
> No it wouldn't. Like I said, I checked that possibility
> out very thoroughly as it is the most obvious trouble
> point.
>
> > Just insert a test for subdirectories and ignore them?
>
> Yeah. That's what I'm going to do.  I just was surprised
> by it, because it worked in the other settings. Now I
> perceive that the mystery is why it didn't fail before!
> ;-)
>
> I suppose it could be that FreeBSD's os.path.walk isn't
> the same code, and is perhaps not completely in line
> with this spec.  It may also be that my image-loading
> code somehow fails silently on directories instead of
> raising an exception. (Both would have to be true to
> explain what I observe).
>
I guess you may have uncovered a bug. I'd personally regard it as a FreeBSD
bug if the behavior differs from other platforms, but I'm guessing that
posixpath.walk() is just exposing the underlying platform's semantics. If
that's the case there may be less chance of fixing it, but I'd still like to
see it reported as a bug.

> Hmm.
>
Indeed. Food for thought!


regards
-----------------------------------------------------------------------
Steve Holden                                 http://www.holdenweb.com/
Python Web Programming                http://pydish.holdenweb.com/pwp/
-----------------------------------------------------------------------








More information about the Python-list mailing list