Message367054
> This behavior is inconsistent with `os.path.abspath` where it always
> returns lowercased drive letter,
ntpath.abspath calls GetFullPathNameW, which generally preserves the input case of the device/drive component. But it doesn't always preserve drive-letter case. In particular, a drive-relative path gets resolved with the upper-case drive letter:
>>> os.path.abspath('c:spam')
'C:\\Temp\\spam'
That's a corner case that maybe needs to be addressed for ntpath.abspath. However, regarding ntpath.realpath, I see no reason for it to preserve the input case. To the contrary, it should always make a best effort to normalize the input path to use the real device and component names and replace 8.3 short names with long names.
> and also causes a failure in Gecko build script:
> https://bugzilla.mozilla.org/show_bug.cgi?id=1628726
IMO, the bug there is using a case-insensitive path as a key without first case folding the string. |
|
Date |
User |
Action |
Args |
2020-04-22 22:00:35 | eryksun | set | recipients:
+ eryksun, saschanaz |
2020-04-22 22:00:35 | eryksun | set | messageid: <1587592835.92.0.407707188545.issue40368@roundup.psfhosted.org> |
2020-04-22 22:00:35 | eryksun | link | issue40368 messages |
2020-04-22 22:00:35 | eryksun | create | |
|