KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
The flask-cache extension has a @cache.memoize decorator to cache a view including the view's *args and **kwargs . Some of my views however take a URL query string as well, for example /foo/image?width=640 . The decorator adds a make_cache_key method to the decorated view function that can be used to customise the cache key However I do not know how to get the request.args outside of the normal request context. Any ideas how to make the @cache.memoize work with URL query strings as well?
Tags (comma-separated)
Save Edits
Cancel