feat(framework): --serve gates the loop on the app actually running#171
Merged
Conversation
Make 'production-grade' mean the generated app really boots and serves, not just
that an agent review passed.
ai-autopilot:
- LocalRunner.adopt(dir): bind an EXISTING directory as the workspace (exec/
start/preview inside it) and do NOT delete it on dispose. Fills a runner-seam
gap (verify code another tool wrote); the framework hit it for deploy too.
framework:
- runFramework({ serve }): adopt the agent's cwd, mergeChecklists(driverChecklist,
serveCheck) so the checklist gates on install/build/start/fetch. Boot failure
or 5xx -> a blocker the loop hands back to the agent to fix.
- CLI: --serve / --serve-install / --serve-build / --serve-port / --serve-path;
serve progress streams to the dashboard.
Tests: LocalRunner.adopt (survives dispose, seeds files); framework serve gate
(real seeded server passes; a server that never boots blocks). 36 framework +
259 ai-autopilot tests green, full-repo typecheck + build clean.
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.
Follow-up to #166. Makes
production-grademean the generated app really boots and serves, not just that Claude Code said its review passed. This is the on-brand guardrail: gate on the outcome, not the agent's opinion.How. With
--serve <cmd>, the checklist becomesmergeChecklists(driverChecklist, serveCheck)- the agent review AND a realserveCheckthat installs, builds, starts, and fetches the app. A boot failure or a 5xx is a blocker the loop hands back to the agent to fix, then re-checks.Runner-seam gap this exposed.
serveCheckneeds aRunnerSessionbound to the workspace the agent wrote to, butLocalRunnermkdtemps a fresh dir and deletes it on dispose. So this addsLocalRunner.adopt(dir)to@gemstack/ai-autopilot: adopt an existing directory as the workspace, run inside it, and leave it alone on dispose. (Same gap I worked around for deploy withhostExecutor;adoptis the general fix.)New:
LocalRunner.adopt,runFramework({ serve }), and CLI flags--serve/--serve-install/--serve-build/--serve-port/--serve-path. Serve progress streams to the dashboard.Tests.
adopt(survives dispose, seeds files) + framework serve gate (a real seeded server passes; a server that never boots blocks). 36 framework + 259 ai-autopilot green; full-repo typecheck + build clean. Two changesets (both minor). Opt-in:--fakeand default runs are unaffected.