Roundup Robot added the comment:
New changeset 28bb1aa9ca3d by Victor Stinner in branch '3.4':
Issue #19629: Fix support.rmtree(), use os.lstat() to check if the file is a
http://hg.python.org/cpython/rev/28bb1aa9ca3d
New changeset e405bcbf761c by Victor Stinner in branch 'default':
Merge
Roundup Robot added the comment:
New changeset c026ed24a211 by Victor Stinner in branch '3.4':
Issue #19629: Add missing import stat
http://hg.python.org/cpython/rev/c026ed24a211
New changeset 168cd3d19fef by Victor Stinner in branch 'default':
(Merge 3.4) Issue #19629: Add missing import stat
Changes by Berker Peksag berker.pek...@gmail.com:
--
resolution: - fixed
stage: needs patch - resolved
status: open - closed
versions: +Python 3.5 -Python 3.3
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19629
Changes by STINNER Victor victor.stin...@gmail.com:
--
nosy: +haypo
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19629
___
___
Python-bugs-list
Jeremy Kloth added the comment:
The attached patch changes support.rmtree to use os.lstat() instead of the
builtin _isdir() to test for directory-ness of a path.
--
keywords: +patch
Added file: http://bugs.python.org/file32875/symlink.patch
___
STINNER Victor added the comment:
Why not starting to use pathlib? pathlib.Path(path).resolve().is_dir().
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19629
___
Antoine Pitrou added the comment:
Why not starting to use pathlib? pathlib.Path(path).resolve().is_dir().
I would rather keep using low-level APIs in test support functions.
--
___
Python tracker rep...@bugs.python.org
Antoine Pitrou added the comment:
Note that using shutil.rmtree() means there are sporadic test_pathlib failures
under Windows:
http://buildbot.python.org/all/builders/AMD64%20Windows7%20SP1%203.x/builds/3436/steps/test/logs/stdio
--
nosy: +steve.dower
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
nosy: +r.david.murray
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19629
___
___
Changes by Jeremy Kloth jeremy.kloth+python-trac...@gmail.com:
--
nosy: +jkloth
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19629
___
___
New submission from Antoine Pitrou:
support.rmtree doesn't work under Windows when there are symlinks (the symlinks
aren't deleted anymore), while shutil.rmtree() works fine:
support.rmtree(@test_2160_tmp)
os.listdir(@test_2160_tmp)
['dirA', 'dirB', 'dirC', 'fileA', 'linkA', 'linkB']
Antoine Pitrou added the comment:
shutil.rmtree() uses os.lstat() while support.rmtree() calls os.path.isdir()
instead.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19629
___
12 matches
Mail list logo