Open
Description
The Python redis library didn't have async support before 4.2.0, but the check for whether redis is installed doesn't take that into account:
Line 14 in 19e0466
If redis
is importable, the code then goes on to import redis.asyncio
, which for older versions doesn't exist:
aiocache/aiocache/backends/redis.py
Line 5 in 19e0466
While, technically, this isn't something that one should do, we hit this problem because of our complicated dependencies, where an internal library we use in our async code also depends on an older redis, even though that part is not used by our async code.
I think rather than hardcoding a version check, an import redis.asyncio
in the try/except block.
Metadata
Metadata
Assignees
Labels
No labels