fastapi-cache icon indicating copy to clipboard operation
fastapi-cache copied to clipboard

fastapi-cache is a tool to cache fastapi response and function result, with backends support redis and memcached.

Results 119 fastapi-cache issues
Sort by recently updated
recently updated
newest added

Hi Folks, I have a function that returns an user querying the username: The endpoint: ```python @app.get("/users/u/{username}", response_model=schemas.Artist) @cache(expire=180, key_builder=request_key_builder) async def read_user(username: str, db: Session = Depends(get_db)) -> schemas.Artist:...

I'm seeing this error in Sentry: TypeError - Pendulum.parse() got an unexpected keyword argument 'exact' ``` fastapi_cache/coder.py in at line 15 from starlette.responses import JSONResponse from starlette.templating import _TemplateResponse as...

Adding libsql as an optional backend, enabling embedded or disk-local caches. Embedded db performance is much better than the other options for some use cases, since it means no network...

What's the point of md5 usage? https://github.com/long2ice/fastapi-cache/blob/63c9fd5f8cdc89633bf9df6382e2a6cf109d9af5/fastapi_cache/key_builder.py#L17 md5 was proofed to be [insecure][wiki]. It's possible to find collisions fast. A potential attacker theoretically can send unique query parameters which weren't...

Bumps [towncrier](https://github.com/twisted/towncrier) from 22.12.0 to 23.6.0. Release notes Sourced from towncrier's releases. Towncrier 23.6.0 towncrier 23.6.0 (2023-06-06) This is the last release to support Python 3.7. Features Make towncrier create...

dependencies
python

I believe there's a use-case for allowing some non-GET requests to be cacheable. Given restrictions on the length of HTTP requests, it is sometimes necessary to embed data into requests....

@cache's type hint allowed only awaitables, although the implementation supported both. This commit allows both awaitables and non-awaitables for @cache's type hint.

This idea comes from Spring Cache, which mainly provides caching function for methods or functions, similar to `functools.cache` in Python. These features are often applied to "CRUD" methods, while the...

enhancement

If I'm not mistaken, I found out that this library does not support RedisJSON, can I work to add it?

Hi, has anyone done or thought of solving 'dogpiling' somehow with fastapi-cache? The dogpile.cache lib describes the problem nicely, https://dogpilecache.sqlalchemy.org/en/latest/ Briefly, in the case of an empty initial cache, it's...