Fix maximum recursion depth triggered on exception exit (#4438)

This commit is contained in:
Lianmin Zheng
2025-03-14 15:12:26 -07:00
committed by GitHub
parent 862fe52241
commit e73167ade3

View File

@@ -527,6 +527,9 @@ def kill_process_tree(parent_pid, include_parent: bool = True, skip_pid: int = N
pass
if include_parent:
if parent_pid == os.getpid():
sys.exit(0)
try:
itself.kill()