diff --git a/cms/celery.py b/cms/celery.py index 6e1db257b314..3184dc656584 100644 --- a/cms/celery.py +++ b/cms/celery.py @@ -9,7 +9,6 @@ import os from celery import Celery -from django.conf import settings from openedx.core.lib.celery.routers import AlternateEnvironmentRouter diff --git a/cms/envs/common.py b/cms/envs/common.py index 1c29f6d23f5e..96adfb0319c2 100644 --- a/cms/envs/common.py +++ b/cms/envs/common.py @@ -1213,13 +1213,6 @@ ################################# CELERY ###################################### -# Auto discover tasks fails to detect contentstore tasks -CELERY_IMPORTS = ( - 'cms.djangoapps.contentstore.tasks', - 'openedx.core.djangoapps.bookmarks.tasks', - 'openedx.core.djangoapps.ccxcon.tasks', -) - # Message configuration CELERY_TASK_SERIALIZER = 'json' diff --git a/lms/celery.py b/lms/celery.py index a8f0fce6e1ce..dd9a23a8cf8b 100644 --- a/lms/celery.py +++ b/lms/celery.py @@ -9,12 +9,11 @@ import os from celery import Celery -from django.conf import settings from openedx.core.lib.celery.routers import AlternateEnvironmentRouter # set the default Django settings module for the 'celery' program. -os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'proj.settings') +os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'lms.envs.production') APP = Celery('proj') diff --git a/lms/envs/common.py b/lms/envs/common.py index cf147b1876c7..d5a1f21dede0 100644 --- a/lms/envs/common.py +++ b/lms/envs/common.py @@ -2230,15 +2230,6 @@ def _make_locale_paths(settings): # pylint: disable=missing-function-docstring ################################# CELERY ###################################### -# Celery's task autodiscovery won't find tasks nested in a tasks package. -# Tasks are only registered when the module they are defined in is imported. -CELERY_IMPORTS = ( - 'poll.tasks', - 'lms.djangoapps.instructor_task.tasks', - 'lms.djangoapps.bulk_email.tasks', - 'openedx.core.djangoapps.bookmarks.tasks', -) - # Message configuration CELERY_TASK_SERIALIZER = 'json'