On 2007-04-11 19:54:52 +0400, Tomash Brechko wrote:
I have no knowledge of Python, so I can't fix it myself, but perhaps
one should check for symlink before 'if os.path.isdir(i):'.
Correct. From the Python library reference:
isdir(path)
Return True if path is an existing directory. This follows
symbolic links, so both islink() and isdir() can be true for the
same path.
So, os.path.islink() would be the function to use.
--
Karl Hasselström, kha@treskal.com
www.treskal.com/kalle