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

Program hangs when num process is set to 1 for using multiprocessing #461

Open
sandeep-gh opened this issue Oct 12, 2023 · 0 comments
Open

Comments

@sandeep-gh
Copy link

sandeep-gh commented Oct 12, 2023

For the following

DOIT_CONFIG = {
    "parallel_type": 'process',
    "num_process": 2,
}

the program hangs:

File "/home/adming/.local/bin/doit", line 8, in <module>
    sys.exit(main())
             ^^^^^^
  File "/home/adming/.local/lib/python3.11/site-packages/doit/__main__.py", line 8, in main
    sys.exit(DoitMain().run(sys.argv[1:]))
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/adming/.local/lib/python3.11/site-packages/doit/doit_cmd.py", line 294, in run
    return command.parse_execute(args)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/adming/.local/lib/python3.11/site-packages/doit/cmd_base.py", line 150, in parse_execute
    return self.execute(params, args)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/adming/.local/lib/python3.11/site-packages/doit/cmd_base.py", line 570, in execute
    return self._execute(**exec_params)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/adming/.local/lib/python3.11/site-packages/doit/cmd_run.py", line 265, in _execute
    return runner.run_all(self.control.task_dispatcher())
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/adming/.local/lib/python3.11/site-packages/doit/runner.py", line 254, in run_all
    self.run_tasks(task_dispatcher)
  File "/home/adming/.local/lib/python3.11/site-packages/doit/runner.py", line 463, in run_tasks
    result = result_q.get()
             ^^^^^^^^^^^^^^
  File "/usr/lib64/python3.11/multiprocessing/queues.py", line 103, in get
    res = self._recv_bytes()
          ^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.11/multiprocessing/connection.py", line 215, in recv_bytes
    buf = self._recv_bytes(maxlength)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.11/multiprocessing/connection.py", line 413, in _recv_bytes
    buf = self._recv(4)
          ^^^^^^^^^^^^^
  File "/usr/lib64/python3.11/multiprocessing/connection.py", line 378, in _recv
    chunk = read(handle, remaining)
            ^^^^^^^^^^^^^^^^^^^^^^^
KeyboardInterrupt
^CException ignored in: <module 'threading' from '/usr/lib64/python3.11/threading.py'>

Environment

OS: Fedora 37 (6.5.5-100.fc37.aarch64)
python version: 3.11.5
doit version: VERSION = (0, 36, 0)

Upvote & Fund

  • We're using Polar.sh so you can upvote and help fund this issue.
  • We receive the funding once the issue is completed & confirmed by you.
  • Thank you in advance for helping prioritize & fund our backlog.
Fund with Polar
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

1 participant