This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: ntpath.realpath munges os.devnull
Type: behavior Stage: test needed
Components: Library (Lib), Windows Versions: Python 2.7, Python 2.6
process
Status: closed Resolution: duplicate
Dependencies: Superseder:
Assigned To: Nosy List: amaury.forgeotdarc, ezio.melotti, jaraco
Priority: normal Keywords:

Created on 2010-03-02 22:52 by jaraco, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Messages (3)
msg100314 - (view) Author: Jason R. Coombs (jaraco) * (Python committer) Date: 2010-03-02 22:52
On Python 2.6 and Python 2.7a, calling ntpath.realpath(os.devnull) returns '\\\\nul' (two backslashes followed by nul), which is not a valid filename.

This appears to have been fixed in Python 3.1, as on 3.1.1, ntpath.realpath(os.devnull) returns '\\\\.\\nul' which apparently is the absolute path to the NULL file handle.
msg100316 - (view) Author: Ezio Melotti (ezio.melotti) * (Python committer) Date: 2010-03-02 23:01
This might be related to #7909.
msg100320 - (view) Author: Jason R. Coombs (jaraco) * (Python committer) Date: 2010-03-03 00:43
Indeed, this is a duplicate. My search failed probably because ntpath.abspath is ntpath.realpath.
History
Date User Action Args
2022-04-11 14:56:58adminsetgithub: 52291
2010-03-03 02:05:03benjamin.petersonsetresolution: duplicate
2010-03-03 00:43:13jaracosetstatus: open -> closed

messages: + msg100320
2010-03-03 00:40:22ezio.melottisetnosy: + amaury.forgeotdarc
2010-03-02 23:01:53ezio.melottisetpriority: normal

type: behavior
components: + Library (Lib)

nosy: + ezio.melotti
messages: + msg100316
stage: test needed
2010-03-02 22:52:03jaracocreate