-
-
Notifications
You must be signed in to change notification settings - Fork 32k
gh-82367: Use FindFirstFile
Win32 API in ntpath.realpath()
#110298
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
gh-82367: Use FindFirstFile
Win32 API in ntpath.realpath()
#110298
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Misc/NEWS.d/next/Windows/2023-10-03-12-30-59.gh-issue-82367.nxwfMx.rst
Outdated
Show resolved
Hide resolved
The code change looks great to me. Awesome job! With Zach's requested doc changes, I think this is good to merge. |
2c49ffc
to
4590347
Compare
…ython#110298) * Use `FindFirstFile` Win32 API to fix a bug where `ntpath.realpath()` breaks out of traversing a series of paths where a (handled) `ERROR_ACCESS_DENIED` or `ERROR_SHARING_VIOLATION` occurs. * Update docs to reflect that `ntpath.realpath()` eliminates MS-DOS style names.
4590347
to
f675a4f
Compare
…ython#110298) * Use `FindFirstFile` Win32 API to fix a bug where `ntpath.realpath()` breaks out of traversing a series of paths where a (handled) `ERROR_ACCESS_DENIED` or `ERROR_SHARING_VIOLATION` occurs. * Update docs to reflect that `ntpath.realpath()` eliminates MS-DOS style names.
d88c757
to
e17852c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Thank you, Moonsik, and thanks also for taking the extra time to make the test more robust.
…ython#110298) * Use `FindFirstFile` Win32 API to fix a bug where `ntpath.realpath()` breaks out of traversing a series of paths where a (handled) `ERROR_ACCESS_DENIED` or `ERROR_SHARING_VIOLATION` occurs. * Update docs to reflect that `ntpath.realpath()` eliminates MS-DOS style names.
1766bc3
to
2b5a29e
Compare
Thanks Steve and Eryk for the reviews, and Moonsik for the patch and excellent collaboration! |
…ythonGH-110298) * Use `FindFirstFile` Win32 API to fix a bug where `ntpath.realpath()` breaks out of traversing a series of paths where a (handled) `ERROR_ACCESS_DENIED` or `ERROR_SHARING_VIOLATION` occurs. * Update docs to reflect that `ntpath.realpath()` eliminates MS-DOS style names.
ntpath.realpath()
breaks out of traversing a series of paths where a (handled) ERROR_ACCESS_DENIED or ERROR_SHARING_VIOLATION occurs.Using
FindFirstFile
Win32 API, we can query their real name to correct the case and also resolve MS-DOS (also called 8.3) style file names such asC:\\LONGFI~1.TXT
.📚 Documentation preview 📚: https://cpython-previews--110298.org.readthedocs.build/