Skip to content
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

Python 3.8/3.9 exception for multiprocessing #439

Open
Ashex opened this issue Apr 7, 2021 · 1 comment
Open

Python 3.8/3.9 exception for multiprocessing #439

Ashex opened this issue Apr 7, 2021 · 1 comment

Comments

@Ashex
Copy link
Collaborator

Ashex commented Apr 7, 2021

I've been doing all my testing under 3.7, when running on 3.8.8 and 3.9.2 will fails to start with the following exception.

Python versions:

  • 3.9.2
  • 3.8.8

Platform: OSX 11.2.3


CRITICAL:root:Error starting io adapter will.backends.io_adapters.slack: 
Traceback (most recent call last):
  File "/Users/evelyn/git/will/will/backends/io_adapters/base.py", line 119, in _start
    self.__event_listener_thread.start()
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/process.py", line 121, in start
    self._popen = self._Popen(self)
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/context.py", line 224, in _Popen
    return _default_context.get_context().Process._Popen(process_obj)
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/context.py", line 284, in _Popen
    return Popen(process_obj)
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/popen_spawn_posix.py", line 32, in __init__
    super().__init__(process_obj)
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/popen_fork.py", line 19, in __init__
    self._launch(process_obj)
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/popen_spawn_posix.py", line 47, in _launch
    reduction.dump(process_obj, fp)
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/reduction.py", line 60, in dump
    ForkingPickler(file, protocol).dump(obj)
TypeError: cannot pickle 'hiredis.Reader' object
CRITICAL:root:Error starting io adapter will.backends.io_adapters.slack: 
Traceback (most recent call last):
  File "/Users/evelyn/git/will/will/backends/io_adapters/base.py", line 119, in _start
    self.__event_listener_thread.start()
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/process.py", line 121, in start
    self._popen = self._Popen(self)
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/context.py", line 224, in _Popen
    return _default_context.get_context().Process._Popen(process_obj)
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/context.py", line 284, in _Popen
    return Popen(process_obj)
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/popen_spawn_posix.py", line 32, in __init__
    super().__init__(process_obj)
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/popen_fork.py", line 19, in __init__
    self._launch(process_obj)
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/popen_spawn_posix.py", line 47, in _launch
    reduction.dump(process_obj, fp)
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/reduction.py", line 60, in dump
    ForkingPickler(file, protocol).dump(obj)
TypeError: cannot pickle 'hiredis.Reader' object
CRITICAL:root:Error starting io adapter will.backends.io_adapters.slack: 
Traceback (most recent call last):
  File "/Users/evelyn/git/will/will/backends/io_adapters/base.py", line 119, in _start
    self.__event_listener_thread.start()
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/process.py", line 121, in start
    self._popen = self._Popen(self)
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/context.py", line 224, in _Popen
    return _default_context.get_context().Process._Popen(process_obj)
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/context.py", line 284, in _Popen
    return Popen(process_obj)
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/popen_spawn_posix.py", line 32, in __init__
    super().__init__(process_obj)
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/popen_fork.py", line 19, in __init__
    self._launch(process_obj)
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/popen_spawn_posix.py", line 47, in _launch
    reduction.dump(process_obj, fp)
  File "/usr/local/homebrew/Cellar/[email protected]/3.8.8_1/Frameworks/Python.framework/Versions/3.8/lib/python3.8/multiprocessing/reduction.py", line 60, in dump
    ForkingPickler(file, protocol).dump(obj)
TypeError: cannot pickle 'hiredis.Reader' object
@Ashex Ashex added the bug label Apr 7, 2021
@Ashex
Copy link
Collaborator Author

Ashex commented Apr 7, 2021

This is an OSX specific issue as multiprocessing behavior changed in 3.8:

https://chrissardegna.com/blog/multiprocessing-changes-python-3-8/

@Ashex Ashex changed the title Pytohn 3.8/3.9 exception for multiprocessing Python 3.8/3.9 exception for multiprocessing Apr 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant