bpo-39481: Make functools.cached_property, partial, ... by emmatyping · Pull Request #19427 · python/cpython (original) (raw)
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 andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Conversation10 Commits4 Checks0 Files changed
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
[ Show hidden characters]({{ revealButtonHref }})
... partialmethod, _lru_cache_wrapper generic.
I noticed that _lru_cache_wrapper
's Python implementation is a function, what should be done about that? I feel like it would be weird to have code that runs without the compiled functools to break on a subscripted lru_cache. Perhaps it should be a class instead?
https://bugs.python.org/issue39481
... partialmethod, _lru_cache_wrapper generic
emmatyping changed the title
Make functools.cached_property, partial, ... bpo-39481: Make functools.cached_property, partial, ...
The conflicts are really annoying. I think we should merge these one at a time and then resolve conflicts in one following PR and land that before merging the next one. That will take a lot of time, because each time we must wait for the tests... :-(
I noticed that
_lru_cache_wrapper
's Python implementation is a function, what should be done about that? I feel like it would be weird to have code that runs without the compiled functools to break on a subscripted lru_cache. Perhaps it should be a class instead?
Based on this I withdraw my approval. @rhettinger what do you think?
@ethanhs If you want to make progress, remove _lru_cache_wrapper
from this PR?
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
_lru_cache_wrapper
issue.
A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core developers that would be appreciated.
Once you have made the requested changes, please leave a comment on this pull request containing the phrase I have made the requested changes; please review again
. I will then notify any core developers who have left a review that you're ready for them to take another look at this pull request.
I suggest omitting the lru_cache() for now.
Also, it would be nice to have a few tests.
I have made the requested changes; please review again
Thanks for making the requested changes!
@gvanrossum: please review the changes made to this pull request.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think Raymond should be happy, so I'll merge now.
@gvanrossum: Please replace #
with GH-
in the commit message next time. Thanks!