celery: daemonic processes are not allowed to have children

前端 未结 4 1710
走了就别回头了
走了就别回头了 2021-02-19 03:32

In Python (2.7) I try to create processes (with multiprocessing) in a celery task (celery 3.1.17) but it gives the error:

daemonic processes are not allowed to h         


        
4条回答
  •  佛祖请我去吃肉
    2021-02-19 03:38

    I got this when I use multiprocessing with Celery 4.2.0 and Python3.6. Solved this by using billiard.

    I changed my source code from

    from multiprocessing import Process

    to

    from billiard.context import Process

    solved this error.

    Attention, import source is billiard.context not billiard.process

提交回复
热议问题