Environment: adk CLI 2.0.1 (linux-x64 release binary); Ubuntu (kernel 6.17).
Each adk dev boot spawns an opencode serve child. When the parent adk dev dies — killed, crashed, or exited — the child is not terminated: it reparents to init/systemd and keeps running. On a day of repeated dev-server restarts (working around eval-run fragility reported separately) we accumulated 13 orphaned opencode serve processes at roughly 230 MB RSS each (~3 GB total), one per restart.
Expected: the child dies with the parent (process group kill, prctl PDEATHSIG, or an exit handler), or at minimum adk dev reaps stale instances on its next boot.
Repro:
adk dev (note the opencode serve child in pgrep -af 'opencode serve').
- Kill the parent (
Ctrl-C or kill <pid>; also happens when it crashes).
- The
opencode serve process is still running, now parented to init. Repeat to accumulate.
Workaround: pkill -f "opencode serve" after killing adk dev.
Environment: adk CLI 2.0.1 (linux-x64 release binary); Ubuntu (kernel 6.17).
Each
adk devboot spawns anopencode servechild. When the parentadk devdies — killed, crashed, or exited — the child is not terminated: it reparents to init/systemd and keeps running. On a day of repeated dev-server restarts (working around eval-run fragility reported separately) we accumulated 13 orphanedopencode serveprocesses at roughly 230 MB RSS each (~3 GB total), one per restart.Expected: the child dies with the parent (process group kill, prctl PDEATHSIG, or an exit handler), or at minimum
adk devreaps stale instances on its next boot.Repro:
adk dev(note theopencode servechild inpgrep -af 'opencode serve').Ctrl-Corkill <pid>; also happens when it crashes).opencode serveprocess is still running, now parented to init. Repeat to accumulate.Workaround:
pkill -f "opencode serve"after killingadk dev.