feat(backend): remove smolmachines; firecracker is the Linux default
lint / lint (push) Successful in 1m54s
test / unit (pull_request) Successful in 58s
test / integration (pull_request) Successful in 18s
test / coverage (pull_request) Failing after 1m3s

Delete the smolmachines backend (the whole bot_bottle/backend/smolmachines
package and its tests). It had fatal Linux issues (TSI networking under
sustained use, exec-channel contention, no SIGWINCH) and is superseded by
the Firecracker backend (issue #342).

Backend selection now:
- default is macos-container on macOS, firecracker on KVM-capable Linux
  hosts, and docker as the last resort (was smolmachines).
- firecracker is selected on a KVM host even when the `firecracker`
  binary isn't installed, so start routes through its preflight and
  prints an install pointer (same UX as require_container), instead of
  silently falling back. Split is_host_capable() (Linux + KVM) out of
  is_available() (adds the binary check) to drive this.

Retarget the cross-backend tests (parity, print-parity, prepare,
workspace, freezer, selection) from smolmachines to firecracker rather
than dropping the coverage. Remove docker.util.image_id/save, which only
smolmachines used. Update README/AGENTS/example bottles and stale
comments; historical docs/prds are left as a point-in-time record.

BREAKING: BOT_BOTTLE_BACKEND=smolmachines now errors as unknown.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WBMWTEtQdJ4W5UrWuLHCck
This commit is contained in:
2026-07-11 13:24:47 -04:00
parent c276f7b0b1
commit c07ebca867
73 changed files with 305 additions and 6218 deletions
+3 -3
View File
@@ -1,7 +1,7 @@
"""Unit: egress_entrypoint.sh argv construction (PRD 0023 chunk 3).
The egress entrypoint is a small POSIX-sh script that builds
the mitmdump argv from env vars. The smolmachines backend
the mitmdump argv from env vars. A VM backend (e.g. firecracker)
controls egress's bind address via EGRESS_LISTEN_HOST; the
docker backend leaves it unset and gets mitmdump's default
(all interfaces).
@@ -67,7 +67,7 @@ class TestEgressEntrypointArgv(unittest.TestCase):
)
def test_listen_host_127_0_0_1_emits_flag(self):
# smolmachines backend sets EGRESS_LISTEN_HOST=127.0.0.1
# A VM backend sets EGRESS_LISTEN_HOST=127.0.0.1
# to scope egress to localhost inside the bundle.
argv = _run_entrypoint({"EGRESS_LISTEN_HOST": "127.0.0.1"})
self.assertIn("--listen-host\n127.0.0.1", argv)
@@ -79,7 +79,7 @@ class TestEgressEntrypointArgv(unittest.TestCase):
self.assertNotIn("--listen-host", argv)
def test_upstream_mode_combined_with_listen_host(self):
# smolmachines mode also sets EGRESS_UPSTREAM_PROXY so
# VM-backend mode also sets EGRESS_UPSTREAM_PROXY so
# both flags should compose correctly.
argv = _run_entrypoint({
"EGRESS_UPSTREAM_PROXY": "http://192.168.50.2:8888",