[New-bugs-announce] [issue39340] shutil.rmtree and write protected files
Peter Liedholm
report at bugs.python.org
Wed Jan 15 04:35:33 EST 2020
New submission from Peter Liedholm <peterfromswe884 at gmail.com>:
Ubuntu 18.4 and Windows 7 has different behaviour when deleting write protected files with rmtree.
Ubuntu silently deletes them (unexpected?)
Windows moans about access denied (expected?)
Reproduction method linux
mkdir test; touch test/file.txt; chmod -w test/file.txt
Reproduction method windows
mkdir test && type nul > test\file.txt && attrib +R test\file.txt
Reproduction method cont.
python3 -c "import shutil; shutil.rmtree('test')"
----------
components: Library (Lib)
messages: 360033
nosy: PeterFS
priority: normal
severity: normal
status: open
title: shutil.rmtree and write protected files
versions: Python 3.6, Python 3.8
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue39340>
_______________________________________
More information about the New-bugs-announce
mailing list