isn't that just a rewrite of the built-in walk function?

but if you want check ftputil again, it has a isdir() function that calls
'LIST' and interprets the result, this i think is what makes the walk function
very slow, since it has to call 'LIST' and make a new socket for the reply, a
very large number of times, a walk on my site ( 50 files 5 dirs. ) took
several minutes,

an idea.
a rewrite of walk that does 'CWD' (change working directory) and using the
reply code to tell retrospectively if its a directory, might not be a lot more
efficient, the current method has the benefit that it gets file size, dates
etc., but due the way its coded does a 'LIST' for each file!, for a walk you
only need to know if its a directory and you'll have to do a 'CWD' anyway,
also you don't generate any new sockets.

Search Discussions

Discussion Posts


Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 8 of 8 | next ›
Discussion Overview
grouppython-list @
postedAug 6, '03 at 9:45p
activeAug 12, '03 at 5:09p

2 users in discussion

Simon place: 4 posts Conatic: 4 posts



site design / logo © 2022 Grokbase