Title: GH-104104: Optimize `pathlib.Path.glob()` by avoiding repeated calls to `os.path.normcase()` by barneygale · Pull Request #104105 · python/cpython · GitHub
Open Graph Title: GH-104104: Optimize `pathlib.Path.glob()` by avoiding repeated calls to `os.path.normcase()` by barneygale · Pull Request #104105 · python/cpython
X Title: GH-104104: Optimize `pathlib.Path.glob()` by avoiding repeated calls to `os.path.normcase()` by barneygale · Pull Request #104105 · python/cpython
Description: Use re.IGNORECASE to implement case-insensitive matching. This restores behaviour from before #31691. $ ./python -m timeit -s 'from pathlib import Path; p = Path()' 'list(p.glob("Lib/*.py"))' 500 loops, best of 5: 403 usec per loop # before 1000 loops, best of 5: 389 usec per loop # after Issue: gh-104104
Open Graph Description: Use re.IGNORECASE to implement case-insensitive matching. This restores behaviour from before #31691. $ ./python -m timeit -s 'from pathlib import Path; p = Path()' 'list(p.glob("L...
X Description: Use re.IGNORECASE to implement case-insensitive matching. This restores behaviour from before #31691. $ ./python -m timeit -s 'from pathlib import Path; p = Path()' 'list(p....
Opengraph URL: https://github.com/python/cpython/pull/104105
X: @github
Domain: github.com
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:1a45d400-d66c-bba4-9e03-f8d6331b7606 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | D90C:E3A3B:8074B:AC99D:69696314 |
| html-safe-nonce | a218fb25abfde5cd9f11300556cbf2a5ce2206b6d8231a0e2b8df8a4f98c7f56 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEOTBDOkUzQTNCOjgwNzRCOkFDOTlEOjY5Njk2MzE0IiwidmlzaXRvcl9pZCI6IjM5NzMzMzYxNjc4NDE2MjA3NTYiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 2b47f7a39efc46c254205ec83fbe9d2487f6c55bae4eb2f28ac912332336608a |
| hovercard-subject-tag | pull_request:1335782494 |
| 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 | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/python/cpython/pull/104105/files |
| twitter:image | https://avatars.githubusercontent.com/u/960340?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/960340?s=400&v=4 |
| og:image:alt | Use re.IGNORECASE to implement case-insensitive matching. This restores behaviour from before #31691. $ ./python -m timeit -s 'from pathlib import Path; p = Path()' 'list(p.glob("L... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | 48487c1ad776a7975b7132d95f4240ff3ae37cd5b8e3cb597102a4edb76738f1 |
| 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 | 669463fcc54773a88c1f5a44eef6b99a5504b9c7 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width