| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:20a9e922-ee48-9221-4a81-4ef6dfe530e1 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | DD06:1F9980:19B5FA1:226D47A:6969ADFE |
| html-safe-nonce | 36cff2bcb58a0244ade1d24d1999f904b5fa3d69f1500ca7844bb4215795553e |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJERDA2OjFGOTk4MDoxOUI1RkExOjIyNkQ0N0E6Njk2OUFERkUiLCJ2aXNpdG9yX2lkIjoiMjkyODQzNjU3ODI0MjYzNzMxMCIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 097723f8d09833939b798940e9a82b8b820f1f729cf1cbf77b562f92189eaba5 |
| hovercard-subject-tag | pull_request:411326870 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | ///pull_requests/show/files |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/python/cpython/pull/19813/files |
| twitter:image | https://avatars.githubusercontent.com/u/64558788?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/64558788?s=400&v=4 |
| og:image:alt | By default, :meth:pathlib.PurePath.relative_to doesn't deal with paths that are not a direct prefix of the other, raising an exception in that instance. This change adds a walk_up parameter tha... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | 24c4c97a2d520cb286b35e1a4c22d7a4df3c26a2fa28dd7cdf0e65db327b4de7 |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/python/cpython git https://github.com/python/cpython.git |
| octolytics-dimension-user_id | 1525981 |
| octolytics-dimension-user_login | python |
| octolytics-dimension-repository_id | 81598961 |
| octolytics-dimension-repository_nwo | python/cpython |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 81598961 |
| octolytics-dimension-repository_network_root_nwo | python/cpython |
| turbo-body-classes | logged-out env-production page-responsive full-width |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 124667f43168afb6c9c03b7c02eb5b1d2e1be3d9 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| Skip to content | https://github.com/python/cpython/pull/19813/files#start-of-content |
|
| https://github.com/ |
|
Sign in
| https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fpull%2F19813%2Ffiles |
| GitHub CopilotWrite better code with AI | https://github.com/features/copilot |
| GitHub SparkBuild and deploy intelligent apps | https://github.com/features/spark |
| GitHub ModelsManage and compare prompts | https://github.com/features/models |
| MCP RegistryNewIntegrate external tools | https://github.com/mcp |
| ActionsAutomate any workflow | https://github.com/features/actions |
| CodespacesInstant dev environments | https://github.com/features/codespaces |
| IssuesPlan and track work | https://github.com/features/issues |
| Code ReviewManage code changes | https://github.com/features/code-review |
| GitHub Advanced SecurityFind and fix vulnerabilities | https://github.com/security/advanced-security |
| Code securitySecure your code as you build | https://github.com/security/advanced-security/code-security |
| Secret protectionStop leaks before they start | https://github.com/security/advanced-security/secret-protection |
| Why GitHub | https://github.com/why-github |
| Documentation | https://docs.github.com |
| Blog | https://github.blog |
| Changelog | https://github.blog/changelog |
| Marketplace | https://github.com/marketplace |
| View all features | https://github.com/features |
| Enterprises | https://github.com/enterprise |
| Small and medium teams | https://github.com/team |
| Startups | https://github.com/enterprise/startups |
| Nonprofits | https://github.com/solutions/industry/nonprofits |
| App Modernization | https://github.com/solutions/use-case/app-modernization |
| DevSecOps | https://github.com/solutions/use-case/devsecops |
| DevOps | https://github.com/solutions/use-case/devops |
| CI/CD | https://github.com/solutions/use-case/ci-cd |
| View all use cases | https://github.com/solutions/use-case |
| Healthcare | https://github.com/solutions/industry/healthcare |
| Financial services | https://github.com/solutions/industry/financial-services |
| Manufacturing | https://github.com/solutions/industry/manufacturing |
| Government | https://github.com/solutions/industry/government |
| View all industries | https://github.com/solutions/industry |
| View all solutions | https://github.com/solutions |
| AI | https://github.com/resources/articles?topic=ai |
| Software Development | https://github.com/resources/articles?topic=software-development |
| DevOps | https://github.com/resources/articles?topic=devops |
| Security | https://github.com/resources/articles?topic=security |
| View all topics | https://github.com/resources/articles |
| Customer stories | https://github.com/customer-stories |
| Events & webinars | https://github.com/resources/events |
| Ebooks & reports | https://github.com/resources/whitepapers |
| Business insights | https://github.com/solutions/executive-insights |
| GitHub Skills | https://skills.github.com |
| Documentation | https://docs.github.com |
| Customer support | https://support.github.com |
| Community forum | https://github.com/orgs/community/discussions |
| Trust center | https://github.com/trust-center |
| Partners | https://github.com/partners |
| GitHub SponsorsFund open source developers | https://github.com/sponsors |
| Security Lab | https://securitylab.github.com |
| Maintainer Community | https://maintainers.github.com |
| Accelerator | https://github.com/accelerator |
| Archive Program | https://archiveprogram.github.com |
| Topics | https://github.com/topics |
| Trending | https://github.com/trending |
| Collections | https://github.com/collections |
| Enterprise platformAI-powered developer platform | https://github.com/enterprise |
| GitHub Advanced SecurityEnterprise-grade security features | https://github.com/security/advanced-security |
| Copilot for BusinessEnterprise-grade AI features | https://github.com/features/copilot/copilot-business |
| Premium SupportEnterprise-grade 24/7 support | https://github.com/premium-support |
| Pricing | https://github.com/pricing |
| Search syntax tips | https://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax |
| documentation | https://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax |
|
Sign in
| https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fpull%2F19813%2Ffiles |
|
Sign up
| https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=python%2Fcpython |
| Reload | https://github.com/python/cpython/pull/19813/files |
| Reload | https://github.com/python/cpython/pull/19813/files |
| Reload | https://github.com/python/cpython/pull/19813/files |
|
python
| https://github.com/python |
| cpython | https://github.com/python/cpython |
| Please reload this page | https://github.com/python/cpython/pull/19813/files |
|
Notifications
| https://github.com/login?return_to=%2Fpython%2Fcpython |
|
Fork
33.9k
| https://github.com/login?return_to=%2Fpython%2Fcpython |
|
Star
71.1k
| https://github.com/login?return_to=%2Fpython%2Fcpython |
|
Code
| https://github.com/python/cpython |
|
Issues
5k+
| https://github.com/python/cpython/issues |
|
Pull requests
2.1k
| https://github.com/python/cpython/pulls |
|
Actions
| https://github.com/python/cpython/actions |
|
Projects
31
| https://github.com/python/cpython/projects |
|
Security
Uh oh!
There was an error while loading. Please reload this page.
| https://github.com/python/cpython/security |
| Please reload this page | https://github.com/python/cpython/pull/19813/files |
|
Insights
| https://github.com/python/cpython/pulse |
|
Code
| https://github.com/python/cpython |
|
Issues
| https://github.com/python/cpython/issues |
|
Pull requests
| https://github.com/python/cpython/pulls |
|
Actions
| https://github.com/python/cpython/actions |
|
Projects
| https://github.com/python/cpython/projects |
|
Security
| https://github.com/python/cpython/security |
|
Insights
| https://github.com/python/cpython/pulse |
| Sign up for GitHub
| https://github.com/signup?return_to=%2Fpython%2Fcpython%2Fissues%2Fnew%2Fchoose |
| terms of service | https://docs.github.com/terms |
| privacy statement | https://docs.github.com/privacy |
| Sign in | https://github.com/login?return_to=%2Fpython%2Fcpython%2Fissues%2Fnew%2Fchoose |
| miss-islington | https://github.com/miss-islington |
| python:main | https://github.com/python/cpython/tree/main |
| domragusa:relative_to_strict_param | https://github.com/domragusa/cpython/tree/relative_to_strict_param |
|
Conversation
45
| https://github.com/python/cpython/pull/19813 |
|
Commits
17
| https://github.com/python/cpython/pull/19813/commits |
|
Checks
0
| https://github.com/python/cpython/pull/19813/checks |
|
Files changed
| https://github.com/python/cpython/pull/19813/files |
| Please reload this page | https://github.com/python/cpython/pull/19813/files |
|
gh-84538: add strict argument to pathlib.PurePath.relative_to
| https://github.com/python/cpython/pull/19813/files#top |
|
Show all changes
17 commits
| https://github.com/python/cpython/pull/19813/files |
|
ec64368
bpo-40358: add strict param to pathlib.PurePath.relative_to
domragusa Apr 30, 2020
| https://github.com/python/cpython/pull/19813/commits/ec643681ce35ad01f84986dc935ad7787b62f2b4 |
|
6d721a0
resolve conflicts with GH-19611
domragusa May 28, 2020
| https://github.com/python/cpython/pull/19813/commits/6d721a0ee1fbc841fd555d3acf173f56f36ba410 |
|
09422e7
Merge branch 'python:main' into relative_to_strict_param
domragusa May 15, 2021
| https://github.com/python/cpython/pull/19813/commits/09422e77a9f78f90f4339ba0235414a68d14dc35 |
|
d9c07c2
Update Doc/library/pathlib.rst
domragusa May 15, 2021
| https://github.com/python/cpython/pull/19813/commits/d9c07c2f0f73dcf5c7dc863f9d4eeaeb3cfe64c4 |
|
029c3d5
fix wording in documentation as requested
domragusa May 17, 2021
| https://github.com/python/cpython/pull/19813/commits/029c3d5ce9acb7dc1bfc8e2b9cce1e0e54cc0b51 |
|
01e789b
fix typo
domragusa May 17, 2021
| https://github.com/python/cpython/pull/19813/commits/01e789b0e9493c45745865419203749f3920a0f5 |
|
39b24f3
change strict argument to walk_up in pathlib.PurePath.relative_to
domragusa May 29, 2021
| https://github.com/python/cpython/pull/19813/commits/39b24f3bc17010d930f3572c98635730fb085466 |
|
ad9c0dd
Merge branch 'main' into relative_to_strict_param
domragusa Oct 14, 2022
| https://github.com/python/cpython/pull/19813/commits/ad9c0ddea49275bdd90241a8f9a66e6b768519e8 |
|
8401974
make the documentation clearer
domragusa Oct 14, 2022
| https://github.com/python/cpython/pull/19813/commits/8401974d96fdbc035162eaddf49e903e96ecc979 |
|
e255f99
Apply suggestions from code review
domragusa Oct 22, 2022
| https://github.com/python/cpython/pull/19813/commits/e255f99c8cedf21212988f1ca3d1a52bb1d6304d |
|
b781356
Update Lib/pathlib.py
domragusa Oct 22, 2022
| https://github.com/python/cpython/pull/19813/commits/b7813562abff8f0af8b56c5dd110d209cc817312 |
|
7974ee9
fix doc warning
domragusa Oct 22, 2022
| https://github.com/python/cpython/pull/19813/commits/7974ee93be5aae33e0719615c69ff10df71d69b7 |
|
8a4edb5
improve variable names
domragusa Oct 22, 2022
| https://github.com/python/cpython/pull/19813/commits/8a4edb5dac97c6c076d31ebebc8a3bbc1466e4c0 |
|
e6cf222
remove trailing spaces
domragusa Oct 22, 2022
| https://github.com/python/cpython/pull/19813/commits/e6cf222257b744a714ed3ab438da833e0ab2da0d |
|
b8b218c
Merge branch 'main' into relative_to_strict_param
domragusa Oct 22, 2022
| https://github.com/python/cpython/pull/19813/commits/b8b218c902362cab5ca65ff117fa6f5973311789 |
|
a4c77c2
Update Doc/library/pathlib.rst
brettcannon Oct 28, 2022
| https://github.com/python/cpython/pull/19813/commits/a4c77c2fbb6d7094b1e0b0d6443eb4a4c68edbc4 |
|
97a5e22
Merge branch 'main' into relative_to_strict_param
brettcannon Oct 28, 2022
| https://github.com/python/cpython/pull/19813/commits/97a5e228e92510ada2e0734426419dc6d6d2b366 |
|
Clear filters
| https://github.com/python/cpython/pull/19813/files |
| Please reload this page | https://github.com/python/cpython/pull/19813/files |
| Please reload this page | https://github.com/python/cpython/pull/19813/files |
|
pathlib.rst
| https://github.com/python/cpython/pull/19813/files#diff-1134e36a94ecfde1df43bee5efd285de5d67426fbca086425201ecc753f9139c |
|
3.12.rst
| https://github.com/python/cpython/pull/19813/files#diff-0f2c1763c64530268325a0ee2dfaa4f5d555c4ac27deb78bd77102c8ce1b886b |
|
pathlib.py
| https://github.com/python/cpython/pull/19813/files#diff-fa525485738fc33d05b06c159172ff1f319c26e88d8c6bb39f7dbaae4dc4105c |
|
test_pathlib.py
| https://github.com/python/cpython/pull/19813/files#diff-3dd97d2dc8816848d0b0c442e8fdeec9650b3de77935289a93f37ac6396ee17f |
|
ACKS
| https://github.com/python/cpython/pull/19813/files#diff-d1243956feb505c5459fc05387e194609efb5c350cee202942be47ed30d7d7d0 |
|
2020-04-30-02-15-08.bpo-40358.A4ygqe.rst
| https://github.com/python/cpython/pull/19813/files#diff-a6eeb8773189ed36054c2c09b047c18d2c93a561fb68dad893858bb7663b0423 |
|
| https://github.com/python/cpython/blob/main/.github/CODEOWNERS#L525 |
| Doc/library/pathlib.rst | https://github.com/python/cpython/pull/19813/files#diff-1134e36a94ecfde1df43bee5efd285de5d67426fbca086425201ecc753f9139c |
|
View file
| https://github.com/domragusa/cpython/blob/97a5e228e92510ada2e0734426419dc6d6d2b366/Doc/library/pathlib.rst |
|
Open in desktop
| https://desktop.github.com |
| https://github.co/hiddenchars |
| https://github.com/python/cpython/pull/19813/{{ revealButtonHref }} |
|
| https://github.com/python/cpython/pull/19813/files#diff-1134e36a94ecfde1df43bee5efd285de5d67426fbca086425201ecc753f9139c |
|
| https://github.com/python/cpython/pull/19813/files#diff-1134e36a94ecfde1df43bee5efd285de5d67426fbca086425201ecc753f9139c |
|
| https://github.com/python/cpython/pull/19813/files#diff-1134e36a94ecfde1df43bee5efd285de5d67426fbca086425201ecc753f9139c |
|
| https://github.com/python/cpython/blob/main/.github/CODEOWNERS#L114 |
| Doc/whatsnew/3.12.rst | https://github.com/python/cpython/pull/19813/files#diff-0f2c1763c64530268325a0ee2dfaa4f5d555c4ac27deb78bd77102c8ce1b886b |
|
View file
| https://github.com/domragusa/cpython/blob/97a5e228e92510ada2e0734426419dc6d6d2b366/Doc/whatsnew/3.12.rst |
|
Open in desktop
| https://desktop.github.com |
| https://github.co/hiddenchars |
| https://github.com/python/cpython/pull/19813/{{ revealButtonHref }} |
|
| https://github.com/python/cpython/pull/19813/files#diff-0f2c1763c64530268325a0ee2dfaa4f5d555c4ac27deb78bd77102c8ce1b886b |
|
| https://github.com/python/cpython/pull/19813/files#diff-0f2c1763c64530268325a0ee2dfaa4f5d555c4ac27deb78bd77102c8ce1b886b |
| Lib/pathlib.py | https://github.com/python/cpython/pull/19813/files#diff-fa525485738fc33d05b06c159172ff1f319c26e88d8c6bb39f7dbaae4dc4105c |
|
View file
| https://github.com/domragusa/cpython/blob/97a5e228e92510ada2e0734426419dc6d6d2b366/Lib/pathlib.py |
|
Open in desktop
| https://desktop.github.com |
| https://github.co/hiddenchars |
| https://github.com/python/cpython/pull/19813/{{ revealButtonHref }} |
|
| https://github.com/python/cpython/pull/19813/files#diff-fa525485738fc33d05b06c159172ff1f319c26e88d8c6bb39f7dbaae4dc4105c |
| Please reload this page | https://github.com/python/cpython/pull/19813/files |
|
| https://github.com/python/cpython/pull/19813/files#diff-fa525485738fc33d05b06c159172ff1f319c26e88d8c6bb39f7dbaae4dc4105c |
| Please reload this page | https://github.com/python/cpython/pull/19813/files |
|
| https://github.com/python/cpython/pull/19813/files#diff-fa525485738fc33d05b06c159172ff1f319c26e88d8c6bb39f7dbaae4dc4105c |
| Lib/test/test_pathlib.py | https://github.com/python/cpython/pull/19813/files#diff-3dd97d2dc8816848d0b0c442e8fdeec9650b3de77935289a93f37ac6396ee17f |
|
View file
| https://github.com/domragusa/cpython/blob/97a5e228e92510ada2e0734426419dc6d6d2b366/Lib/test/test_pathlib.py |
|
Open in desktop
| https://desktop.github.com |
| https://github.co/hiddenchars |
| https://github.com/python/cpython/pull/19813/{{ revealButtonHref }} |
|
| https://github.com/python/cpython/pull/19813/files#diff-3dd97d2dc8816848d0b0c442e8fdeec9650b3de77935289a93f37ac6396ee17f |
|
| https://github.com/python/cpython/pull/19813/files#diff-3dd97d2dc8816848d0b0c442e8fdeec9650b3de77935289a93f37ac6396ee17f |
|
| https://github.com/python/cpython/pull/19813/files#diff-3dd97d2dc8816848d0b0c442e8fdeec9650b3de77935289a93f37ac6396ee17f |
|
| https://github.com/python/cpython/pull/19813/files#diff-3dd97d2dc8816848d0b0c442e8fdeec9650b3de77935289a93f37ac6396ee17f |
|
| https://github.com/python/cpython/pull/19813/files#diff-3dd97d2dc8816848d0b0c442e8fdeec9650b3de77935289a93f37ac6396ee17f |
|
| https://github.com/python/cpython/pull/19813/files#diff-3dd97d2dc8816848d0b0c442e8fdeec9650b3de77935289a93f37ac6396ee17f |
|
| https://github.com/python/cpython/pull/19813/files#diff-3dd97d2dc8816848d0b0c442e8fdeec9650b3de77935289a93f37ac6396ee17f |
|
| https://github.com/python/cpython/pull/19813/files#diff-3dd97d2dc8816848d0b0c442e8fdeec9650b3de77935289a93f37ac6396ee17f |
|
| https://github.com/python/cpython/pull/19813/files#diff-3dd97d2dc8816848d0b0c442e8fdeec9650b3de77935289a93f37ac6396ee17f |
| Misc/ACKS | https://github.com/python/cpython/pull/19813/files#diff-d1243956feb505c5459fc05387e194609efb5c350cee202942be47ed30d7d7d0 |
|
View file
| https://github.com/domragusa/cpython/blob/97a5e228e92510ada2e0734426419dc6d6d2b366/Misc/ACKS |
|
Open in desktop
| https://desktop.github.com |
| https://github.co/hiddenchars |
| https://github.com/python/cpython/pull/19813/{{ revealButtonHref }} |
|
| https://github.com/python/cpython/pull/19813/files#diff-d1243956feb505c5459fc05387e194609efb5c350cee202942be47ed30d7d7d0 |
|
| https://github.com/python/cpython/pull/19813/files#diff-d1243956feb505c5459fc05387e194609efb5c350cee202942be47ed30d7d7d0 |
| Misc/NEWS.d/next/Library/2020-04-30-02-15-08.bpo-40358.A4ygqe.rst | https://github.com/python/cpython/pull/19813/files#diff-a6eeb8773189ed36054c2c09b047c18d2c93a561fb68dad893858bb7663b0423 |
|
View file
| https://github.com/domragusa/cpython/blob/97a5e228e92510ada2e0734426419dc6d6d2b366/Misc/NEWS.d/next/Library/2020-04-30-02-15-08.bpo-40358.A4ygqe.rst |
|
Open in desktop
| https://desktop.github.com |
| https://github.co/hiddenchars |
| https://github.com/python/cpython/pull/19813/{{ revealButtonHref }} |
|
| https://github.com |
| Terms | https://docs.github.com/site-policy/github-terms/github-terms-of-service |
| Privacy | https://docs.github.com/site-policy/privacy-policies/github-privacy-statement |
| Security | https://github.com/security |
| Status | https://www.githubstatus.com/ |
| Community | https://github.community/ |
| Docs | https://docs.github.com/ |
| Contact | https://support.github.com?tags=dotcom-footer |