Repository navigation
Conversation
… process startDaemonRuntime no longer calls process.exit or installs process handlers; src/daemon.ts owns signals, fatal errors and the exit code. close() is idempotent and resolves to a ShutdownReport. A runtime that fails during startup rolls back what it acquired. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
… uploads and requests Provider admission, interactor resolution, artifact and upload tracking, resumable uploads, materialized paths, session-open locks and request cancellation are owned by the runtime instance instead of module scope. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
The Apple runner's sessions, locks, recycle ledger and owner state belong to the daemon runtime that composed them. The PNG worker is held by every runtime that uses it and stops with the last one. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Size Report
Startup median (7 runs, lower is better):
|
There was a problem hiding this comment.
All reported issues were addressed across 52 files
You’re at about 94% of the monthly reviewed-line limit. You may want to disable incremental reviews to conserve quota. Reviews will continue until that limit is exceeded. If you need help avoiding interruptions, please contact contact@cubic.dev.
Reply with feedback, questions, or to request a fix.
View guided diff | Turn on auto-fix | Re-trigger cubic
…moves temp files Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
There was a problem hiding this comment.
All reported issues were addressed across 9 files (changes from recent commits).
You’re at about 95% of the monthly reviewed-line limit. You may want to disable incremental reviews to conserve quota. Reviews will continue until that limit is exceeded. If you need help avoiding interruptions, please contact contact@cubic.dev.
Reply with feedback, questions, or to request a fix.
View guided diff | Turn on auto-fix | Re-trigger cubic
…one removal helper Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
|
Closing one runtime can still kill another runtime's Apple runner build, so this needs one more change before merge (reviewed at c047776). CI is green (12 checks, none failing), and I know of no other merge issue. The Apple runner state in runner-artifact.ts is still process-wide. I found this by reading the code. I did not run two runtimes with an Apple runner. The PR body shows no artifacts for the live simulator run, and that run covers one runtime only, so per-runtime Apple isolation rests on Not blocking, and fine to take or leave: Could On the open review threads, all are addressed at this head except none still apply as live issues. These can be resolved: PNG/plugins/lock release in closeOnHost, isolation test cleanup, close test assertions, materialized-path dispose, resumable-upload dispose, shutdown error in daemon.ts, artifact-tracking dispose, releasePngWorker, composition test resolver, infoPath and lockPath assertions, removeBestEffort, all fixed at this head. The dispose ordering thread is benign: dispose runs after the servers close and in-flight work settles, and only a force-cut handler could still touch the temp dir, with its connection already gone. Before merge, Apple start admissions and the prep-process ledger must be per runtime, with a regression test showing B's prep child survives A's stop-all. |
…s to the runtime Closing one daemon runtime no longer retires another runtime's start admissions or signals its prep builds. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
The runtime context, the per-runtime state list and the session teardown helpers move beside the other shutdown mechanics. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
…ranch * refactor/host-environment: fix(host): resolve every client read from the client's host
|
Pushed
Not done here: consolidating the per-module runtime-state owners into one is a follow-up. |
Summary
Part of #3747, stacked on #3763. Closes #3752.
A daemon runtime no longer assumes it owns the process.
startDaemonRuntimenever callsprocess.exitand installs noprocess.on/oncehandler.src/daemon.tsowns signals, fatal errors and the exit code. A startup refusal rejects withdetails.exitCode(daemonStartupExitCode).close()is idempotent: concurrent calls share one promise that resolves to aShutdownReport(provider releases, runners, sessions, plugins).closedsettles whoever closes (idle reap). Provider runtimes dispose exactly once; a startup that fails rolls back what it acquired.daemon stop --jsonstill reportsproviderReleases.pending.AsyncResource.bind). The PNG worker is held by every runtime that uses it and stops with the last.Validation
pnpm check:affected --run --head 0b83711eb1passed (exact commit). New tests: two runtimes in one process serve, close and keep state independently; idempotentclose()and rollback; runner state per runtime; PNG worker refcount.Live on iPhone 17e simulator (clean daemon,
/private/tmpstate dir): open, snapshot, close; gracefuldaemon stophanded the runner off (ios_runner_session_detached, runner kept alive) and a new daemon adopted it with no second xcodebuild;daemon stop --cleananddevice statusleft no claims or runners.🤖 Generated with Claude Code