mirror of
https://github.com/bytedance/deer-flow.git
synced 2026-05-21 07:26:50 +00:00
b67c2a4e56
When a sandbox container crashes (e.g. due to an internal error), the agent enters a connection-refused loop because AioSandboxProvider.get() returns a cached but dead sandbox object. Add a liveness check in get() that detects crashed containers via backend.is_alive() and evicts them from all caches, allowing ensure_sandbox_initialized() to transparently recreate a fresh container on the next acquire(). The behavior is controlled by a new config option (default: true). Set to false to skip health checks and preserve the old behavior of returning stale cached sandboxes. Closes #2788