Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions tests/test_harbor_local_mode.py
Original file line number Diff line number Diff line change
Expand Up @@ -3346,8 +3346,16 @@ async def exercise() -> object | None:
try:
asyncio.run(exercise())
child_pid = int(child_pid_path.read_text(encoding="ascii"))
with pytest.raises(ProcessLookupError):
os.kill(child_pid, 0)
# On macOS the group probe can report EPERM after SIGKILL while this
# descendant is still finishing its exit. Allow bounded exit completion.
deadline = time.monotonic() + 5
while True:
try:
os.kill(child_pid, 0)
except ProcessLookupError:
break
assert time.monotonic() < deadline, "a SIGTERM-ignoring descendant survived cleanup"
Comment thread
rng1995 marked this conversation as resolved.
Resolved
time.sleep(0.01)
finally:
if child_pid is None and child_pid_path.exists():
child_pid = int(child_pid_path.read_text(encoding="ascii"))
Expand Down
Loading