classification
Title: test_4_daemon_threads() fails randomly on "x86 Windows Server 2003 [SB] 3.x"
Type: crash Stage:
Components: Versions: Python 3.4
process
Status: closed Resolution: out of date
Dependencies: Superseder:
Assigned To: Nosy List: BreamoreBoy, neologix, pitrou, sbt, tim.golden, vstinner
Priority: normal Keywords:

Created on 2014-02-21 09:03 by vstinner, last changed 2015-03-18 13:27 by vstinner. This issue is now closed.

Messages (4)
msg211830 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2014-02-21 09:03
The test test_4_daemon_threads() does crash randomly on the buildbot "x86 Windows Server 2003 [SB] 3.x". It may be an old bug which was not seen before because it was hidden by another bug (#19424 which is now fixed).

Charles-Fran├žois Natali repeated that daemons threads can crash randomly at exit if they are waiting for a blocking call with the GIL released, and still use memory that is being freed by the main thread at exit.

http://buildbot.python.org/all/builders/x86%20Windows%20Server%202003%20%5BSB%5D%203.x/builds/2166/steps/test/logs/stdio

======================================================================
FAIL: test_4_daemon_threads (test.test_threading.ThreadJoinOnShutdown)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "E:\Data\buildslave\cpython\3.x.snakebite-win2k3r2sp2-x86\build\lib\test\test_threading.py", line 773, in test_4_daemon_threads
    rc, out, err = assert_python_ok('-c', script)
  File "E:\Data\buildslave\cpython\3.x.snakebite-win2k3r2sp2-x86\build\lib\test\script_helper.py", line 69, in assert_python_ok
    return _assert_python(True, *args, **env_vars)
  File "E:\Data\buildslave\cpython\3.x.snakebite-win2k3r2sp2-x86\build\lib\test\script_helper.py", line 55, in _assert_python
    "stderr follows:\n%s" % (rc, err.decode('ascii', 'ignore')))
AssertionError: Process return code is 3221225477, stderr follows:


Related issues:

- #19424: _warnings: patch to avoid conversions from/to UTF-8
- #19442: Python crashes when a warning is emitted during shutdown
- #19466: Clear state of threads earlier in Python shutdown => my changes from this issue have been reverted
msg211831 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2014-02-21 09:11
I'm unable to reproduce the issue on my Windows XP and Windows 7 virtual machines.
msg211901 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2014-02-22 00:44
The test failed also on "AMD64 Windows7 SP1 3.x" buildbot:

http://buildbot.python.org/all/builders/AMD64%20Windows7%20SP1%203.x/builds/4144/steps/test/logs/stdio

======================================================================
FAIL: test_4_daemon_threads (test.test_threading.ThreadJoinOnShutdown)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "C:\buildbot.python.org\3.x.kloth-win64\build\lib\test\test_threading.py", line 773, in test_4_daemon_threads
    rc, out, err = assert_python_ok('-c', script)
  File "C:\buildbot.python.org\3.x.kloth-win64\build\lib\test\script_helper.py", line 69, in assert_python_ok
    return _assert_python(True, *args, **env_vars)
  File "C:\buildbot.python.org\3.x.kloth-win64\build\lib\test\script_helper.py", line 55, in _assert_python
    "stderr follows:\n%s" % (rc, err.decode('ascii', 'ignore')))
AssertionError: Process return code is 3221225477, stderr follows:
msg236230 - (view) Author: Mark Lawrence (BreamoreBoy) * Date: 2015-02-19 18:39
The "AMD64 Windows7 SP1 3.x" buildbot is currently green although it did fail at Feb 18 02:17.  The "x86 Windows Server 2003 [SB] 3.4" has been showing an exception for the last two days.  I'm sorry but I do not know how to investigate this further myself.
History
Date User Action Args
2015-03-18 13:27:27vstinnersetstatus: open -> closed
resolution: out of date
2015-02-19 18:39:19BreamoreBoysetnosy: + BreamoreBoy
messages: + msg236230
2014-02-22 00:45:33brian.curtinsetnosy: - brian.curtin
2014-02-22 00:44:17vstinnersetmessages: + msg211901
2014-02-21 09:11:27vstinnersetnosy: + tim.golden, brian.curtin
messages: + msg211831
2014-02-21 09:03:55vstinnercreate