onaio / kaznet-web

a tasking application built on top of Onadata
Apache License 2.0
4 stars 1 forks source link

Fix error thrown by celery worker #340

Closed FrankApiyo closed 5 years ago

FrankApiyo commented 5 years ago

the celery worker currently throws this error:


The message has been ignored and discarded.                                                                                                                                  

Did you remember to import the module containing this task?                                                                                                                  
Or maybe you're using relative imports?                                                                                                                                      

Please see                                                                                                                                                                   
http://docs.celeryq.org/en/latest/internals/protocol.html                                                                                                                    
for more information.                                                                                                                                                        

The full contents of the message body was:                                                                                                                                   
b'[[], {}, {"callbacks": null, "errbacks": null, "chain": null, "chord": null}]' (77b)                                                                                       
Traceback (most recent call last):                                                                                                                                           
  File "/home/kaznet-stage/.virtualenvs/kaznet-stage/lib/python3.6/site-packages/celery/worker/consumer/consumer.py", line 559, in on_task_received                          
    strategy = strategies[type_]                                                                                                                                             
KeyError: 'task_sync_outdated_submission_reviews'```