Skip to content

cachetools: precise typing for decorators and cached(); expose cache_info/cache_clear and fix keys signatures#14770

Merged
srittau merged 12 commits into
python:mainfrom
ashm-dev:cachetools
Oct 21, 2025
Merged

cachetools: precise typing for decorators and cached(); expose cache_info/cache_clear and fix keys signatures#14770
srittau merged 12 commits into
python:mainfrom
ashm-dev:cachetools

Conversation

@ashm-dev

Copy link
Copy Markdown
Contributor

Closes: #14766

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@ashm-dev

Copy link
Copy Markdown
Contributor Author

@srittau @sobolevn
Could you take a look at my PR when you have a chance?

@github-actions

This comment has been minimized.

@srittau

srittau commented Sep 30, 2025

Copy link
Copy Markdown
Collaborator

Considering this is a quite complex change, could you have a look at #14768, where I add some tests for functools.cache and add some similar tests for this change? The tests go into stubs/cachetools/@tests/test_cases/check_*.py (where the asterisk is a stand-in for an appropriate name).

@ashm-dev

Copy link
Copy Markdown
Contributor Author

Yes, of course, I’ll take care of it)

@github-actions

This comment has been minimized.

@ashm-dev

Copy link
Copy Markdown
Contributor Author

@srittau I added the tests, please check them!

@github-actions

Copy link
Copy Markdown
Contributor

According to mypy_primer, this change has no effect on the checked open source code. 🤖🎉

@srittau srittau left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@srittau srittau merged commit fa0e5fc into python:main Oct 21, 2025
48 checks passed
@ashm-dev ashm-dev deleted the cachetools branch October 21, 2025 11:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[cachetools] Support cache_info on functions

2 participants