Describe the bug or question
A clear and concise description of what the bug or question is.
To Reproduce
Please provide a self-contained, minimal, and reproducible example of your use case
async def is_rate_limited(db: AsyncSession, user_id: int, path: str, limit: int, period: int) -> bool:
if client is None:
logger.error("Redis client is not initialized.")
raise Exception("Redis client is not initialized.")
Description
Redis client was recognised as none when I tried to create background tasks in Swagger and caught exception in is_rate_limited
Screenshots
Additional context
Add any other context about the problem here.
Describe the bug or question A clear and concise description of what the bug or question is.
To Reproduce Please provide a self-contained, minimal, and reproducible example of your use case
Description Redis client was recognised as none when I tried to create background tasks in Swagger and caught exception in
is_rate_limited
Screenshots
Additional context Add any other context about the problem here.