django-q2 icon indicating copy to clipboard operation
django-q2 copied to clipboard

sometimes the task was lost

Open sunlin-xiaonai opened this issue 11 months ago • 2 comments

i found in my task code, sometime is successful ,but i find error frequently, it show me task function is not defined in my mac m3. i have no idea what's happend? the django-q2 is only suitable for linux? or some other cause? i am sure my code is written correctly

Uploading image.png…

sunlin-xiaonai avatar Mar 12 '24 02:03 sunlin-xiaonai

Function apps.orders.tasks.story_asr_short_audio is not defined : Traceback (most recent call last): File "/home/pom/.local/share/virtualenvs/danc-DNLmilTk/lib/python3.8/site-packages/django_q/worker.py", line 96, in worker raise ValueError(f"Function {task['func']} is not defined") ValueError: Function apps.orders.tasks.story_asr_short_audio is not defined

sunlin-xiaonai avatar Mar 12 '24 02:03 sunlin-xiaonai

Django-q2 should work on any OS. Are you sure the reference to that function is correct? It's basically saying that it can't find the task by going to apps.orders.tasks.story_asr_short_audio.

sometime is successful ,but i find error frequently

You are saying that same task reference is successful sometimes, but also sometimes fails with that error you posted above?

GDay avatar May 05 '24 01:05 GDay