Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork33.3k
gh-94909: fix joining of absolute and relative Windows paths in pathlib#95450
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
gh-94909: fix joining of absolute and relative Windows paths in pathlib#95450
Uh oh!
There was an error while loading.Please reload this page.
Conversation
9c3730d to643d20eCompareHey@serhiy-storchaka, would you be willing to review? You fixed the same issue in |
Uh oh!
There was an error while loading.Please reload this page.
@barneygale if@serhiy-storchaka doesn't review in a week I will go ahead and merge; feel free to ping me to do it if I forget (I'm also stalling because 3.11.0.rc1 is being cut today and I don't want to have to remember to merge into 3.11 once the branch opens again and then forget). 😅 |
Co-authored-by: Brett Cannon <brett@python.org>
Wait a moment. This change goes against the initial approach. It can be slower and inconsistent with other pathlib code (the definition of "drive" was different in pathlib and os.path, and can still be different). |
Could you give an example where its inconsistent with other parts of pathlib? It might be slower (I haven't checked) but I don't think pathlib, as ahigh level path library, should care about beating the performance of |
We could de-risk this by skipping backporting. It's a niche bug, and I only need it solved in |
To keep things simple I only did this to |
Uh oh!
There was an error while loading.Please reload this page.
Have pathlib use
os.path.join()to join arguments to thePurePathinitialiser, which fixes a minor bug when handling relative paths with drives.Previously:
Now:
Automerge-Triggered-By: GH:brettcannon