mirror of
https://github.com/BerriAI/litellm.git
synced 2026-11-13 08:52:02 +00:00
The test spawned a real Python child that installs a SIGTERM handler, slept 0.3s, then cancelled the supervisor and expected the child to exit 0. CI runs with --cov, and pytest-cov starts coverage in every spawned Python process, so the child is often still starting when SIGTERM lands and dies with -15. open_children now takes the process spawner the same way it takes the platform, and only needs the platform to signal and stop children. The test uses a fake child whose wait() blocks on an event and a fake platform that records stop_group, so it checks the shielded stop-then-wait with no real process and no sleep. It also checks the child is still being waited on, because anyio's wait_all_tasks_blocked on asyncio can return one loop tick before a task group finishes. |
||
|---|---|---|
| .. | ||
| supervisor | ||
| __init__.py | ||
| test_mode.py | ||
| test_peer.py | ||