forked from python/cpython
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[3.11] pythongh-100809: Fix handling of drive-relative paths in pathl…
…ib.Path.absolute() (pythonGH-100812) Resolving the drive independently uses the OS API, which ensures it starts from the current directory on that drive.. (cherry picked from commit 072011b) Co-authored-by: Barney Gale <barney.gale@gmail.com>
- Loading branch information
1 parent
559d0e8
commit 09ecea7
Showing
4 changed files
with
64 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 3 additions & 0 deletions
3
Misc/NEWS.d/next/Library/2023-01-06-21-14-41.gh-issue-100809.I697UT.rst
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
Fix handling of drive-relative paths (like 'C:' and 'C:foo') in | ||
:meth:`pathlib.Path.absolute`. This method now uses the OS API | ||
to retrieve the correct current working directory for the drive. |