AsyncResult(task_id) returns "PENDING" state even after the task started
For Celery 4.1.0 and Django 1.11.7 this is what you need in the config.py file:
Correct:
task_track_started = True
Also Correct:
CELERY_TASK_TRACK_STARTED = True
WRONG!:
CELERY_TRACK_STARTED = True
Just took me 2 hours to figure out. Hope this serves somebody in the near future
It's probably related to CELERY_TRACK_STARTED setting. Quoting the docs:
CELERY_TRACK_STARTED
If True the task will report its status as “started” when the task is executed by a worker. The default value is False as the normal behaviour is to not report that level of granularity. Tasks are either pending, finished, or waiting to be retried. Having a “started” state can be useful for when there are long running tasks and there is a need to report which task is currently running.
Maybe you have CELERY_TRACK_STARTED = True
in your development settings, but not in production ?