Skip to content

gh-96851 Doc: clarify lru_cache on class methods #96852

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

Conversation

codicocodes
Copy link

@codicocodes codicocodes commented Sep 15, 2022

Clarify that when using the lru_cache decorator on class methods the cached function keeps a reference to each instance (self), which prevents the class instance from being garbage collected.

Issue: #96851

Clarify that when using the lru_cache decorator on class methods
the cached function keeps a reference to each instance (self),
which prevents the class instance from being garbage collected.
@ghost
Copy link

ghost commented Sep 15, 2022

All commit authors signed the Contributor License Agreement.
CLA signed

@rhettinger rhettinger closed this Sep 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awaiting review docs Documentation in the Doc dir skip news
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants