test_execute_with_preexec_fn failed on Python 3.5

Bug #1688201 reported by ChangBo Guo(gcb)
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
oslo.concurrency
Fix Released
Medium
Yuriy Taraday

Bug Description

Got error recently as follow on Python 3.5 unit test CI job:

ft1.5: oslo_concurrency.tests.unit.test_processutils.UtilsTest.test_execute_with_preexec_fn_StringException: Empty attachments:
  stderr
  stdout

Traceback (most recent call last):
  File "/home/jenkins/workspace/gate-oslo.concurrency-python35/oslo_concurrency/tests/unit/test_processutils.py", line 120, in test_execute_with_preexec_fn
    preexec_fn=preexec_fn)
  File "/home/jenkins/workspace/gate-oslo.concurrency-python35/.tox/py35/lib/python3.5/site-packages/testtools/testcase.py", line 485, in assertRaises
    self.assertThat(our_callable, matcher)
  File "/home/jenkins/workspace/gate-oslo.concurrency-python35/.tox/py35/lib/python3.5/site-packages/testtools/testcase.py", line 496, in assertThat
    mismatch_error = self._matchHelper(matchee, matcher, message, verbose)
  File "/home/jenkins/workspace/gate-oslo.concurrency-python35/.tox/py35/lib/python3.5/site-packages/testtools/testcase.py", line 547, in _matchHelper
    mismatch = matcher.match(matchee)
  File "/home/jenkins/workspace/gate-oslo.concurrency-python35/.tox/py35/lib/python3.5/site-packages/testtools/matchers/_exception.py", line 108, in match
    mismatch = self.exception_matcher.match(exc_info)
  File "/home/jenkins/workspace/gate-oslo.concurrency-python35/.tox/py35/lib/python3.5/site-packages/testtools/matchers/_higherorder.py", line 62, in match
    mismatch = matcher.match(matchee)
  File "/home/jenkins/workspace/gate-oslo.concurrency-python35/.tox/py35/lib/python3.5/site-packages/testtools/testcase.py", line 475, in match
    reraise(*matchee)
  File "/home/jenkins/workspace/gate-oslo.concurrency-python35/.tox/py35/lib/python3.5/site-packages/testtools/_compat3x.py", line 16, in reraise
    raise exc_obj.with_traceback(exc_tb)
  File "/home/jenkins/workspace/gate-oslo.concurrency-python35/.tox/py35/lib/python3.5/site-packages/testtools/matchers/_exception.py", line 101, in match
    result = matchee()
  File "/home/jenkins/workspace/gate-oslo.concurrency-python35/.tox/py35/lib/python3.5/site-packages/testtools/testcase.py", line 1049, in __call__
    return self._callable_object(*self._args, **self._kwargs)
  File "/home/jenkins/workspace/gate-oslo.concurrency-python35/oslo_concurrency/processutils.py", line 374, in execute
    env=env_variables)
  File "/home/jenkins/workspace/gate-oslo.concurrency-python35/.tox/py35/lib/python3.5/site-packages/eventlet/green/subprocess.py", line 55, in __init__
    subprocess_orig.Popen.__init__(self, args, 0, *argss, **kwds)
  File "/usr/lib/python3.5/subprocess.py", line 947, in __init__
    restore_signals, start_new_session)
  File "/usr/lib/python3.5/subprocess.py", line 1552, in _execute_child
    raise child_exception_type(err_msg)
subprocess.SubprocessError: Exception occurred in preexec_fn.

Revision history for this message
ChangBo Guo(gcb) (glongwave) wrote :
Changed in oslo.concurrency:
assignee: nobody → Yuriy Taraday (yorik-sar)
status: New → In Progress
importance: Undecided → Medium
Revision history for this message
Yuriy Taraday (yorik-sar) wrote :

Upstream issue: https://github.com/eventlet/eventlet/issues/413 - eventlet makes a hidden reimport of subprocess module before inheriting from subprocess.Popen causing all exceptions raised from it becoming uncatchable.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/oslo.concurrency 3.21.0

This issue was fixed in the openstack/oslo.concurrency 3.21.0 release.

Changed in oslo.concurrency:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.