Skip to content
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

Clearing cache based on method parameters #53

Open
quoimec opened this issue May 7, 2021 · 2 comments
Open

Clearing cache based on method parameters #53

quoimec opened this issue May 7, 2021 · 2 comments

Comments

@quoimec
Copy link

quoimec commented May 7, 2021

The ability to cache a method based on the function parameters to that method is extremely useful. However, at the moment, if I need to invalidate the cache for a specific set of arguments, I have to clear the entire cache for that method.

Are there any future plans for allowing individual sections of the cache to be cleared based on method parameters?

@shaypal5
Copy link
Collaborator

shaypal5 commented May 9, 2021

No current plans, but it should be a simple addition. It just requires adding optional parameters to the clear_cache function and have it clear param-specific entries if these are provided. It's just a matter of someone stepping up and providing a code contribution implementing this feature. :)

I'd love for you to open a PR, if you think you can spare the time!

@quoimec
Copy link
Author

quoimec commented May 10, 2021

Hmm ok! I may have a look at this in the next week or two as it would be really useful for my use case.

Thanks for the reply and the package!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants