How to debug Celery/Django tasks running locally in Eclipse
You should consider the option to run the celery task in the same thread as the main process (normally it runs on a separate process), this will make the debug much easier.
You can tell celery to run the task in sync by adding this setting to your settings.py module:
CELERY_TASK_ALWAYS_EAGER = True
# use this if you are on older versions of celery
# CELERY_ALWAYS_EAGER = True
Note: this is only meant to be in use for debugging or development stages!
You can do it using Celery's rdb:
from celery.contrib import rdb
rdb.set_trace()
Then, in a different terminal type telnet localhost 6900
, and you will get the debug prompt.