diff --git a/pandora/user/tasks.py b/pandora/user/tasks.py index d782d5fa..30482864 100644 --- a/pandora/user/tasks.py +++ b/pandora/user/tasks.py @@ -36,7 +36,10 @@ def update_statistics(): @task(ignore_results=True, queue='default') def parse_data(key): from . import models - session_data = models.SessionData.objects.get(session_key=key) + try: + session_data = models.SessionData.objects.get(session_key=key) + except models.SessionData.DoesNotExist: + return session_data.parse_data() session_data.save()