[ python-Bugs-1076515 ] shutil.move clobbers read-only files.
SourceForge.net
noreply at sourceforge.net
Wed Dec 1 06:40:47 CET 2004
Bugs item #1076515, was opened at 2004-12-01 00:40
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1076515&group_id=5470
Category: Python Library
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Jeremy Fincher (jemfinch)
Assigned to: Nobody/Anonymous (nobody)
Summary: shutil.move clobbers read-only files.
Initial Comment:
The summary states it fine. shutil.move happily overwrites read-
only files.
It looks like it indiscriminately catches OSError, and never bothers
to check whether it's a permission error.
It'd be nice if permission errors raised an exception that was a
subclass of OSError, then it'd be cake to fix this (at least for
*nices; I'm not sure about the Windows implications).
According to tracker #810879, clobbering read-only files isn't the
desired behavior for shutil.copyfile, so I doubt it's desired for
shutil.move.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1076515&group_id=5470
More information about the Python-bugs-list
mailing list