Skip to content

bpo-44310: Note that lru_cache keep references to both arguments and results #26715

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

Merged
merged 26 commits into from
Jun 14, 2021

Conversation

rhettinger
Copy link
Contributor

@rhettinger rhettinger commented Jun 14, 2021

Separately, I may also submit a FAQ on approaches for caching methods.

https://bugs.python.org/issue44310

rhettinger and others added 26 commits March 15, 2021 21:12
.
Merge branch 'master' of github.com:python/cpython
.
Merge branch 'master' of github.com:python/cpython
.
Merge branch 'master' of github.com:python/cpython
.
Merge branch 'master' of github.com:python/cpython
Merge branch 'main' of github.com:python/cpython into main
Merge branch 'main' of github.com:python/cpython
@rhettinger rhettinger added docs Documentation in the Doc dir skip news needs backport to 3.10 only security fixes labels Jun 14, 2021
@rhettinger rhettinger merged commit fafcfff into python:main Jun 14, 2021
@miss-islington
Copy link
Contributor

Thanks @rhettinger for the PR 🌮🎉.. I'm working now to backport this PR to: 3.10.
🐍🍒⛏🤖

@bedevere-bot
Copy link

GH-26716 is a backport of this pull request to the 3.10 branch.

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Jun 14, 2021
…results (pythonGH-26715)

* Simplify the count_vowels example
* Hits and misses are fetched while a lock is held
* Add note that references are kept for arguments and return values
* Clarify behavior when *typed* is false.
(cherry picked from commit fafcfff)

Co-authored-by: Raymond Hettinger <[email protected]>
@sweeneyde
Copy link
Member

To get rid of the extra commits shown here you should be able to do this to your main branch:

$ git fetch upstream main
$ git reset --hard upstream/main

(where upstream is the python/cpython repo). Then any future branches won't show all the extra merge commits.

jdevries3133 pushed a commit to jdevries3133/cpython that referenced this pull request Jun 19, 2021
…results (pythonGH-26715)

* Simplify the count_vowels example
* Hits and misses are fetched while a lock is held
* Add note that references are kept for arguments and return values
* Clarify behavior when *typed* is false.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Documentation in the Doc dir skip news
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants