[NOT READY FOR REVIEW] feat(dev): CodeZip dev runner and process lifecycle core - #1883
Open
tejaskash wants to merge 5 commits into
Open
[NOT READY FOR REVIEW] feat(dev): CodeZip dev runner and process lifecycle core#1883tejaskash wants to merge 5 commits into
tejaskash wants to merge 5 commits into
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## feat/project-foundation #1883 +/- ##
===========================================================
- Coverage 96.04% 95.79% -0.25%
===========================================================
Files 211 214 +3
Lines 9916 10113 +197
===========================================================
+ Hits 9524 9688 +164
- Misses 392 425 +33 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
tejaskash
force-pushed
the
feat/dev-server-core
branch
from
July 31, 2026 16:55
f5e0f3a to
ba41e68
Compare
tejaskash
force-pushed
the
feat/dev-server-core
branch
4 times, most recently
from
August 3, 2026 18:01
750364c to
fe79c87
Compare
The first executable slice of agentcore project dev. CodeZipDevRunner bootstraps a uv venv (or node_modules) on first run, then serves the entrypoint with uvicorn --reload (or tsx watch). spawnServer owns process lifecycle: line-streamed logs, SIGTERM->SIGKILL escalation on stop, and a process-group reaper so a detached server can't outlive the CLI and hold the port. The DevRunner interface lives with its consumer (handlers/project/dev), per the dependency-inversion convention. Command execution and server spawning are injectable, so runner tests never start real uv or uvicorn; process tests use real short-lived node processes because process handling is the thing under test. run.ts duplicates the CommandRunner shape from #1872 deliberately; fold into src/io/exec.ts once that lands.
…to src/errors All typed errors live in src/errors; the dev module was defining its own inline.
tejaskash
force-pushed
the
feat/dev-server-core
branch
from
August 3, 2026 21:16
fe79c87 to
356b555
Compare
The exit event can fire before the shell-mode child's piped output is drained on Windows, so tests saw exited resolve with zero log lines. close waits for stdio to flush. The missing-binary test now asserts the shared cross-platform contract: POSIX fails spawn outright while the win32 shell exits non-zero with stderr output.
… once Applies the full set of review findings on this PR: - No shell: true. Windows argument boundaries were corrupted going through cmd.exe. Commands are now ProcessCommand records with extension-qualified executables (windowsExecutable), spawned directly. - parseEntrypoint interprets an entrypoint exactly once. main.py:application was classified as TypeScript by the old endsWith check and launched under tsx watch. - ProcessSupervisor owns all children with one CLI-exit reaper; Windows termination goes through taskkill /T for the whole tree. - stop() is awaitable and exited resolves as a structured ProcessExit (exited/signaled/spawn-error) after stdio flushes. - readline splits output lines, handling CRLF and chunk-split characters. - Node installs detect pnpm/yarn/npm from the lockfile.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
SIGTERMtoSIGKILLescalationCodeZipDevRunnersupport for Python projects usinguvanduvicorn --reloadCodeZipDevRunnersupport for TypeScript projects usingnpmandtsx watchPORT,LOCAL_DEV, and caller-provided environment variables to the agent processDevRunnerinterface alongside its future handler and inject process dependencies for isolated testsVerification
bun test(565 tests)