Created
March 2, 2013 13:54
-
-
Save sehmaschine/5071098 to your computer and use it in GitHub Desktop.
celery update_state issue
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from tasks import full_export_task | |
def export_year_zip(user): | |
full_export_task.update_state(state="PROGRESS", meta={}) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
task() | |
def full_export_task(user, task_id=None): | |
from export.views.user_full_export import export_year_zip | |
result = export_year_zip(user) | |
return result |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I think the problem is that you're calling
update_state
from outside the@task
-decorated function. Not really sure, sorry.