You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm encountering an error when trying to use Celery with Redis in my Python project. Despite having installed both Celery and Redis, I'm getting the following error:
class PrefixedStrictRedis(GlobalKeyPrefixMixin, redis.Redis):
AttributeError: 'NoneType' object has no attribute 'Redis'
This error occurs in the Kombu library, which is a dependency of Celery. I've already tried the following steps:
I am using Redis docker. I tried testing using the below script and it returned true:
import redis
r = redis.Redis(host='localhost', port=6379, db=0)
try:
r.ping()
print("Successfully connected to Redis")
except redis.ConnectionError:
print("Failed to connect to Redis")
What could be causing this error, and how can I resolve it? Is there a potential version conflict or misconfiguration that I'm overlooking?
The error is triggered when I try to execute the following train function using my FastAPI endpoint:
I'm encountering an error when trying to use Celery with Redis in my Python project. Despite having installed both Celery and Redis, I'm getting the following error:
This error occurs in the Kombu library, which is a dependency of Celery. I've already tried the following steps:
Installed Redis: pip install redis
Installed Celery: pip install celery
Verified that the Redis server is running
I checked that I am using the correct virtual environment
My environment:
I am using Redis docker. I tried testing using the below script and it returned true:
What could be causing this error, and how can I resolve it? Is there a potential version conflict or misconfiguration that I'm overlooking?
The error is triggered when I try to execute the following train function using my FastAPI endpoint:
The text was updated successfully, but these errors were encountered: