Wrong OSError message from os.rename() when dst is a non-empty directory
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
python3.4 (Ubuntu) |
Fix Released
|
Medium
|
Unassigned |
Bug Description
Under Python 3.3, if renaming a directory with `os.rename()` when the destination is an existing, non-empty directory, like this:
os.rename(
You'll get an OSError with a message like this:
OSError: [Errno 39] Directory not empty: '/tmp/bar'
However, in the current Python 3.4.0b1 package in Trusty, this error message will contain the source directory name instead of the destination directory name, like this:
OSError: [Errno 39] Directory not empty: '/tmp/foo'
I've attached a test case, which also covers renaming directories relative to an open directory descriptor. This test case works on Python 3.3, fails on Python 3.4.
ProblemType: Bug
DistroRelease: Ubuntu 14.04
Package: python3.4 3.4~b1-0ubuntu3
ProcVersionSign
Uname: Linux 3.12.0-7-generic x86_64
ApportVersion: 2.12.7-0ubuntu3
Architecture: amd64
CurrentDesktop: Unity
Date: Fri Dec 27 19:57:28 2013
SourcePackage: python3.4
UpgradeStatus: No upgrade log present (probably fresh install)
Changed in python3.4 (Ubuntu): | |
status: | Confirmed → Triaged |
importance: | Undecided → Medium |
milestone: | none → trusty-updates |
I didn't find an existing upstream up for this, so I filed one: http:// bugs.python. org/issue20093