[New-bugs-announce] [issue1669] shutils.rmtree fails on symlink, after deleting contents

Tim Koopman report at bugs.python.org
Thu Dec 20 09:53:22 CET 2007


New submission from Tim Koopman:

When using rmtree with a symlink to a directory as path, it will first
follow the symlink, (try to) remove all the contents of the source
directory and then raise the exception "OSError: [Errno 20] Not a
directory".

Expected behaviour: The function should only raise an exception.

If the current behaviour is indeed wanted, it should a least be documented.

----------
components: Library (Lib)
messages: 58864
nosy: Tesiph
severity: normal
status: open
title: shutils.rmtree fails on symlink, after deleting contents
type: behavior
versions: Python 2.5

__________________________________
Tracker <report at bugs.python.org>
<http://bugs.python.org/issue1669>
__________________________________


More information about the New-bugs-announce mailing list