flask-cache
flask-cache copied to clipboard
Is that possible to delete_memoized according to part of parameters?
Example:
@cache.memoize()
def param_func(a, b):
return a+b+random.randrange(1, 50)
For the function above:
cache.delete_memoized('random_func')will delete all caches of this function;cache.delete_memoized('param_func', 1, 2)will delete the cache with parameters a=1 and b=2;- Is that possible to delete the caches with parameters a=1 for all b values, something like
cache.delete_memoized('param_func', 1)?