Uh oh!
There was an error while loading. Please reload this page.
bpo-44002: Switch to lru_cache in urllib.parse. - #25798
Conversation
urllib.parse now uses functool.lru_cache for its internal URL splitting and quoting caches instead of rolling its own like its the 90s. The undocumented internal Quoted class and clear_cache() APIs are now deprecated, for removal in 3.14.
gpshead
commented
May 1, 2021
I won't merge this until after the 3.10 branch is cut and all of the https://bugs.python.org/issue43882 fixes are in. |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
gpshead
left a comment
There was a problem hiding this comment.
The test that's failing due to an unexpected BytesWarning in CI is annoying... that means we need to use lru_cache(typed=True) on the urlsplit decorator for safety to avoid other people who enable BytesWarning from seeing that warning.
Uh oh!
There was an error while loading. Please reload this page.
rhettinger
commented
May 2, 2021
It looks like the Travis CI failed only because of excess whitespace. Running 'make patchcheck' would likely clear it. |
orsenthil
commented
May 3, 2021
This final change, which addressed the review comments from the reviewers looks good to me. |
twisted, gevent, and our own libregrtest use it in test suites. We'll keep it for them. ... and skip Pending on Quoter's DeprecationWarning. No uses of that have been found externally. Also reoragnizes the unittest a bit to be cleaner and fixes a whitespace problem.
gpshead
commented
May 3, 2021
Status: awaiting a copy of #25853 to be merged into |
Uh oh!
There was an error while loading. Please reload this page.
miss-islington
commented
May 11, 2021
@gpshead: Status check is done, and it's a failure ❌ . |
miss-islington
commented
May 11, 2021
@gpshead: Status check is done, and it's a success ❌ . |
orsenthil
commented
May 12, 2021
Excellent change. @gpshead :) |
urllib.parse now uses functool.lru_cache for its internal URL splitting and
quoting caches instead of rolling its own like its the 90s.
The undocumented internal Quoted class is now deprecated, for removal in 3.14.
No existing users were found.
clear_cache() is kept as twisted, gevent, and our own regression test runner were
found to be using it in their test suites.
https://bugs.python.org/issue44002
Automerge-Triggered-By: GH:gpshead