[issue2564] Python hangs on FreeBSD7 in test_capi
Amaury Forgeot d'Arc
report at bugs.python.org
Tue Apr 8 16:35:33 CEST 2008
Amaury Forgeot d'Arc <amauryfa at gmail.com> added the comment:
I think that this problem is not FreeBSD specific:
- "import test.autotest" runs the whole test suite as a side-effect of
an import statement.
- in the test suite test_capi spawns threads, which also import.
- a lock ensues...
See for example test_threaded_import.py::
# This triggers on, e.g., from test import autotest.
raise TestSkipped("can't run when import lock is held")
I the test_capi case, I think that the two imports in TestThreadState
should be moved outside the function.
Also, the backtrace file shows two other threads locked in a "import
socket" statement. I suspect problems in test_urllib2.py or
Tracker <report at bugs.python.org>
More information about the Python-bugs-list