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: os.readlink should support getting the target's printname in Windows
Type: enhancement Stage: needs patch
Components: Library (Lib), Windows Versions: Python 3.10, Python 3.9, Python 3.8
process
Status: open Resolution:
Dependencies: Superseder:
Assigned To: Nosy List: eryksun, mattblovell, paul.moore, steve.dower, tim.golden, zach.ware
Priority: normal Keywords:

Created on 2020-05-30 16:31 by eryksun, last changed 2022-04-11 14:59 by admin.

Messages (1)
msg370389 - (view) Author: Eryk Sun (eryksun) * (Python triager) Date: 2020-05-30 16:31
As discussed in issue 40654, os.readlink should provide a way to get the print name of a symlink target. This is the target path that was actually passed to WinAPI CreateSymbolicLinkW (except for drive-relative paths) and is what a shell would display as the link target (e.g. CMD's "dir" command). Perhaps a keyword-only parameter could be supported to query the print name, e.g. readlink(path, printname=True). In POSIX, passing printname=True would make no difference, since a POSIX symlink only has a substitute name.
History
Date User Action Args
2022-04-11 14:59:31adminsetgithub: 85004
2020-06-15 18:19:06mattblovellsetnosy: + mattblovell
2020-05-30 16:31:07eryksuncreate