-
Notifications
You must be signed in to change notification settings - Fork 285
Closed
Labels
Description
From Teodoras PR #1250 (https://github.com/theupdateframework/tuf/runs/1658331874), a seemingly unrelated failure on ServerProcess tests
Notes:
- seems windows-related
- this is flaky: other builds on same branch do not show this
- seems concentrated on TestServerProcess tests (other tests using a ServerProcess succeed at least on this run) maybe because those end up with many processes very quickly in row
- may be python 3.6 only: https://bugs.python.org/issue37380
- possible workaround may be to set something as stdin for the subprocess even if we don't use it https://stackoverflow.com/questions/40108816/python-running-as-windows-service-o
======================================================================
ERROR: test_cleanup (test_utils.TestServerProcess)
----------------------------------------------------------------------
Traceback (most recent call last):
File "d:\a\tuf\tuf\tests\utils.py", line 174, in __init__
self._start_server(timeout, extra_cmd_args, popen_cwd)
File "d:\a\tuf\tuf\tests\utils.py", line 190, in _start_server
self._start_process(extra_cmd_args, popen_cwd)
File "d:\a\tuf\tuf\tests\utils.py", line 207, in _start_process
stdout=subprocess.PIPE, stderr=subprocess.STDOUT, cwd=popen_cwd)
File "c:\hostedtoolcache\windows\python\3.6.8\x64\lib\subprocess.py", line 616, in __init__
_cleanup()
File "c:\hostedtoolcache\windows\python\3.6.8\x64\lib\subprocess.py", line 205, in _cleanup
res = inst._internal_poll(_deadstate=sys.maxsize)
File "c:\hostedtoolcache\windows\python\3.6.8\x64\lib\subprocess.py", line 1055, in _internal_poll
if _WaitForSingleObject(self._handle, 0) == _WAIT_OBJECT_0:
OSError: [WinError 6] The handle is invalid
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "D:\a\tuf\tuf\tests\test_utils.py", line 134, in test_cleanup
server='simple_server.py')
File "d:\a\tuf\tuf\tests\utils.py", line 178, in __init__
self.clean()
File "d:\a\tuf\tuf\tests\utils.py", line 316, in clean
self.flush_log()
File "d:\a\tuf\tuf\tests\utils.py", line 294, in flush_log
line = self._log_queue.get(block=False)
AttributeError: 'TestServerProcess' object has no attribute '_log_queue'
the latter exception seems like a separate bug that only comes up in this error case (_log_queue is not always defined when flush() gets called)
joshuagl