You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
tests: avoid fork from a threaded parent in consolidate exit regressions #801
Pipeline40444948084, unit job121993924014, head a1fc938 passes 10,911 tests but reports
two Python 3.12 DeprecationWarnings in
tests_py/hooks/test_consolidate_background_exit.py:
Both reach multiprocessing/popen_fork.py:66. Python warns that fork() in a
multi-threaded process may deadlock the child.
Inspect why the test parent has threads at process creation. Make process
creation safe while preserving the original regression: the unfixed child
must demonstrate the store-exit problem and the fixed child must exit cleanly.
Do not suppress the warning or weaken either assertion. Run the focused tests
on hosted CI, with this warning treated as an error, then run the normal suite.
Cause racine : pyproject.toml fixe timeout_method = "thread". pytest-timeout lance donc un thread minuteur pour chaque test, et le parent est toujours multi-thread au moment de ctx.Process(...).start() avec le contexte fork. Preuve locale sur Python 3.12.3 : l'avertissement popen_fork.py:66 disparaît avec -o timeout=0. Le correctif lance l'enfant avec spawn : _child_main installe lui-même tous les patchs, les deux assertions restent inchangées et aucun avertissement n'est filtré. Localement, on obtient 2 passed sans l'avertissement, et aussi avec -W error::DeprecationWarning:multiprocessing.popen_fork.
Non vérifié : le run CI hébergé avec l'avertissement transformé en erreur, ainsi que Python 3.11, 3.13 et 3.14, macOS et Windows.
Activity
cdeust commentedon Nov 6, 2026
CI autopilot : PR ouverte, #908 (commit
3cb7ab0).Cause racine :
pyproject.tomlfixetimeout_method = "thread". pytest-timeout lance donc un thread minuteur pour chaque test, et le parent est toujours multi-thread au moment dectx.Process(...).start()avec le contextefork. Preuve locale sur Python 3.12.3 : l'avertissementpopen_fork.py:66disparaît avec-o timeout=0. Le correctif lance l'enfant avecspawn:_child_maininstalle lui-même tous les patchs, les deux assertions restent inchangées et aucun avertissement n'est filtré. Localement, on obtient2 passedsans l'avertissement, et aussi avec-W error::DeprecationWarning:multiprocessing.popen_fork.Non vérifié : le run CI hébergé avec l'avertissement transformé en erreur, ainsi que Python 3.11, 3.13 et 3.14, macOS et Windows.
Generated by Claude Code
fix(tests): name the Windows home and wait on pipes without select (#692
test(hooks): spawn the consolidate exit child instead of forking a th…
fix(tests): name the Windows home and wait on pipes without select (#692
fix(tests): name the Windows home and wait on pipes without select (#692
cdeust commentedon Nov 6, 2026
Fermée par #908 (fusionnée le 2026-11-06 par le résolveur,
github-actions[bot]: leCloses #801n'a pas déclenché la fermeture automatique).Critères de l'issue :
timeout_method = "thread") ; l'enfant démarre maintenant parspawn.unit128047753848 (run 42258308676, tête de test(hooks): spawn the consolidate exit child instead of forking a threaded parent (#801) #908) passe 11 846 tests sans aucune occurrence depopen_forkdans le log, et la ligne de résumé ne compte plus d'avertissement, alors que le run 40444948084 en comptait deux.fixup! ci: close the issues a resolver-merged PR names (close-issues …
ci: close the issues a resolver-merged PR names (close-issues job) (#922