Skip to content

Please disable forkserver for py3 by config flag #913

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
tumb1er opened this issue Feb 28, 2017 · 1 comment
Closed

Please disable forkserver for py3 by config flag #913

tumb1er opened this issue Feb 28, 2017 · 1 comment

Comments

@tumb1er
Copy link

tumb1er commented Feb 28, 2017

After #687 distributed client is not starting anymore from celery task.
That's because celery/billiard is patching multiprocessing module with it's own implementation.

  • distributed==1.14.3 works correctly
  • distributed>=1.15.0,<=1.15.2 freezes completely
  • distributed==1.16.0 crashes with:
# lots of stacks skipped
  File "/data/quokka/virtualenv/lib/python3.5/site-packages/tornado/gen.py", line 285, in wrapper
    yielded = next(result)
  File "/data/quokka/virtualenv/lib/python3.5/site-packages/distributed/nanny.py", line 207, in instantiate
    self.process.start()
  File "/usr/local/lib/python3.5/multiprocessing/process.py", line 105, in start
    self._popen = self._Popen(self)
  File "/usr/local/lib/python3.5/multiprocessing/context.py", line 281, in _Popen
    return Popen(process_obj)
  File "/usr/local/lib/python3.5/multiprocessing/popen_forkserver.py", line 36, in __init__
    super().__init__(process_obj)
  File "/usr/local/lib/python3.5/multiprocessing/popen_fork.py", line 20, in __init__
    self._launch(process_obj)
  File "/usr/local/lib/python3.5/multiprocessing/popen_forkserver.py", line 47, in _launch
    reduction.dump(prep_data, buf)
  File "/usr/local/lib/python3.5/multiprocessing/reduction.py", line 59, in dump
    ForkingPickler(file, protocol).dump(obj)
  File "/data/quokka/virtualenv/lib/python3.5/site-packages/billiard/process.py", line 330, in __reduce__
    'Pickling an AuthenticationString object is '
TypeError: Pickling an AuthenticationString object is disallowed for security reasons

So, flag for forkserver is necessary.

how to reproduce:

  1. define celery task
@celery.task
def some_task():
   c = distributed.Client()
  1. start celery worker
  2. send a task
some_task.delay()
@mrocklin
Copy link
Member

Should be resolved in #914

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants