fastapi_cache
fastapi_cache copied to clipboard
The sample code provided does not work
Hey,
The cache.set() doesn't work, due to the reason it it has no support for three parameters. The sample code provided however does that. If that is ttl, may be we may want to use .expire(), please look into it.
Same here: cache.set("TST_KEY", "TST_VAL", 5) TypeError: set() takes 3 positional arguments but 4 were given
i used this ===> await cache.set(access_token, data) await cache.expire(access_token,30) here 30 is time in seconds . This works fine for me.