Version Info
- boxlite: v0.8.2
- OS: Windows + WSL2
Describe the bug
When running consecutive or concurrent exec commands against the same sandbox, the operation fails with the error:
failed to run container process received unexpected message: InitReady, expected: IntermediateReady(0)
Details
- Concurrent test cases: error occurs probabilistically
- Rapid serial test cases: error occurs probabilistically when interval between
exec calls is short
- Only occurs when targeting the same sandbox
- Same test cases pass without issues on macOS
Steps to Reproduce
- Create a single sandbox
- Run multiple
boxlite exec commands concurrently on the same sandbox OR Run multiple boxlite exec commands in rapid sequence on the same sandbox
- Error occurs immediately
Test cases
async def exec_task(task_id: int):
result = await sandbox.exec("sh", "-c", f"echo 'Task {task_id}'")
assert result.success
assert f"Task {task_id}" in result.stdout
return task_id
tasks = [exec_task(i) for i in range(10)]
results = await asyncio.gather(*tasks)
local_path = "/local/uploaded.txt"
remote_path = "/root/uploaded.txt"
await sandbox.exec("test", "-e", remote_path)
temp_remote = "/var/tmp/temp.txt"
await sandbox.exec("mkdir", "-p", "/var/tmp")
await sandbox.copy_in(local_path, temp_remote, overwrite=True)
await sandbox.exec("test", "-f", temp_remote)
remote_dir = os.path.dirname(remote_path)
if remote_dir:
await sandbox.exec("mkdir", "-p", remote_dir)
result = await sandbox.exec("mv", temp_remote, remote_path)
if result.exit_code != 0:
await sandbox.exec("rm", "-f", temp_remote)
Expected Behavior
exec commands should run successfully without errors in both concurrent and rapid serial scenarios.
Error Log
2026-04-08T07:12:32.434677Z ERROR libcontainer::container::builder_impl: failed to run container process received unexpected message: InitReady, expected: IntermediateReady(0)
2026-04-08T07:12:32.435128Z ERROR boxlite_guest::container::command: zygote build failed container_id=66996230db2d83b9819e8d76748eeb0e4c230e74788984998d16756126a6fea2 program=test args=["test", "-e", "/mnt/data/uploaded_to_volume.txt"] error=internal error: build failed: failed to create container: received unexpected message: InitReady, expected: IntermediateReady(0)
Version Info
Describe the bug
When running consecutive or concurrent
execcommands against the same sandbox, the operation fails with the error:failed to run container process received unexpected message: InitReady, expected: IntermediateReady(0)Details
execcalls is shortSteps to Reproduce
boxlite execcommands concurrently on the same sandbox OR Run multipleboxlite execcommands in rapid sequence on the same sandboxTest cases
Expected Behavior
execcommands should run successfully without errors in both concurrent and rapid serial scenarios.Error Log