Uploaded image for project: 'Python Driver'
  1. Python Driver
  2. PYTHON-3406

Using MongoClient causes a deadlock in child after a fork()

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Unknown Unknown
    • 4.3
    • Affects Version/s: None
    • Component/s: None
    • None

      test_many_threaded (test_fork.TestFork) ... Exception in thread Thread-230:
      Traceback (most recent call last):
        File "/opt/hostedtoolcache/PyPy/3.8.13/x64/lib/pypy3.8/threading.py", line 932, in _bootstrap_inner
          self.run()
        File "/home/runner/work/mongo-python-driver/mongo-python-driver/test/utils.py", line 965, in run
          super(ExceptionCatchingThread, self).run()
        File "/opt/hostedtoolcache/PyPy/3.8.13/x64/lib/pypy3.8/threading.py", line 870, in run
          self._target(*self._args, **self._kwargs)
        File "/home/runner/work/mongo-python-driver/mongo-python-driver/test/test_fork.py", line 156, in fork_behavior
          self.runner.assertEqual(0, os.waitpid(pid, 0)[1])
        File "/opt/hostedtoolcache/PyPy/3.8.13/x64/lib/pypy3.8/unittest/case.py", line 912, in assertEqual
          assertion_func(first, second, msg=msg)
        File "/opt/hostedtoolcache/PyPy/3.8.13/x64/lib/pypy3.8/unittest/case.py", line 905, in _baseAssertEqual
          raise self.failureException(msg)
      AssertionError: 0 != 65280
      FAIL
      ...
      FAIL: test_many_threaded (test_fork.TestFork)
      ----------------------------------------------------------------------
      Traceback (most recent call last):
        File "/home/runner/work/mongo-python-driver/mongo-python-driver/test/test_fork.py", line 168, in test_many_threaded
          self.assertIsNone(t.exc)
      AssertionError: AssertionError('0 != 65280') is not None
      

      https://github.com/mongodb/mongo-python-driver/runs/7908291585?check_suite_focus=true

            Assignee:
            shane.harvey@mongodb.com Shane Harvey
            Reporter:
            shane.harvey@mongodb.com Shane Harvey
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: