Using celery without djcelery
Closed this issue · 7 comments
Hello,
DB mailer works with celery only when djcelery is installed. But with latest version of celery it's possible to use celery with django without this library. How I can use db-mailer with celery without djcelery installed?
Hi, can you show errors when celery is not installed?
It doesn't raise any error, it just ignore use_celery parameter when djcelery isn't installed. In your init.py you have following code:
def celery_supported():
try:
from dbmail import tasks
if not app_installed('djcelery'):
raise ImportError
return True
except ImportError:
return False
So celery_supported will always return False if you haven't djcelery, even if you use celery in your project.
Can you try disable this code, and check how app working without djcelery
?
After disabling this code it works fine, so problem in this function.
what about queue and another functionality?
and additional question: how we can check celery
configuration without djcelery
app?
I setup celery using this tutorial from docs http://docs.celeryproject.org/en/latest/django/first-steps-with-django.html. Then I run celery using this command celery -A project worker -l info -Q default
. Also in django-celery repo I found this warning
THIS PROJECT IS ONLY REQUIRED IF YOU WANT TO USE DJANGO RESULT BACKEND AND ADMIN INTEGRATION
So I didn't install it because admin integration and results not important for me.