Repository navigation
feat(patchy): run patch repos locally with fixtures - #223
Conversation
Astra reviewReviewed StandardsNo merge-blocking method or YAGNI findings. SpecBlocking — intent: fresh/reset dev databases lose published constraints. packages/patchy/src/devResources.ts:145–152 #207 requires provisioning “with the same additive diff and refusals” and says “after it, the baseline is the published inventory.” Its linked dev decision also requires the same operations and schemas to behave the same.
Reproduced with a published Materialize the cumulative published schema, including retained columns and indexes, then apply the current manifest with the existing additive provisioner rather than replacing whole baseline table definitions. Keep a focused regression for this case. Verification: the three focused dev-runtime suites passed (6 tests); the separate disposable PGlite probe reproduced the divergence above. No live instance or production data was used. Summary: Standards: 0 blockers (method/YAGNI). Spec: 1 blocker; worst: fresh/reset dev state silently drops published uniqueness constraints. |
Sol reviewReviewed Standards
Spec
VerificationFocused suites passed: dev state 4/4, dev resources 1/1, dev server 1/1, Postgres dev 4/4, runtime API 11/11, client transport 12/12, plus the cumulative shared-inventory SDK case 1/1. Summary: Standards — 4 findings (worst: P1). Spec — 3 findings (worst: P1). |
|
Opus replaces Sol as the cross-family review. All 11 Opus findings are addressed in Stack merge
Standards — all five addressed
Spec — all three addressed
Method / YAGNI — all three addressed
CI-discovered correctionNode 24 CI on Kept, with reasons
Local verification
Latest-commit CI — all greenVerified on
Latest CI workflow · Label workflow. GitHub reports MERGEABLE and CLEAN; the PR is not a draft. No unresolved Opus findings or CI blockers remain. Ready to merge into the stack base |
Opus reviewReviewed Verification run: Standards1. [Blocking] const Keyring = yield* Effect.promise(() => import("./CredentialKeys.js"));
const { RuntimeLog } = yield* Effect.promise(() => import("@patchy/runtime"));
That makes a packaging constraint into server startup behaviour. The module is doing two jobs (Divergent Change). Smallest fix: move 2. [Blocking]
It is also backwards: the dev layer lives in the shared module, the production layer in the module named for its environment. Put 3. 4. **5. Spec1. [Blocking] Four "Done when" bullets have no test anywhere. #207: " Nothing in the repo invokes 2. 3. I built the two documents and served them to real Chromium with the real Method and YAGNIThe lifecycle split ( Three places where the model is larger than the behaviour needs:
SummaryStandards — 5 findings, worst: production Spec — 3 findings, worst: |
e9e7564 to
3d96fcc
Compare
Patch repos can be initialized and refreshed, but cannot yet be published without switching to a standalone HTML file. Add repo publishing for tiers 0 and 1, with release and declaration checks, typechecking, single-file bundling, and recoverable publication. Creates save the returned patch ID; share and delete use that repo identity. Update the CLI contracts and skills, and cover interrupted publication and bundle refusal paths. Stacked on `sdk/205-tier1-shell` (#221). This PR targets that branch and contains the #206 changes, not the preceding stack. Closes #206. ## Verification - `pnpm test`: 672 tests passed across 70 files. - `pnpm format:check`, `pnpm lint`, and `pnpm typecheck` passed. - `pnpm test:packed-cli-e2e` passed against a real disposable server. - Real-server/browser smoke verified provisioning, additive updates, refusal paths, and starter saves through the broker. - Standards and spec reviews completed; all findings fixed and confirmed resolved. Implemented with GPT-6 Astra in the Oh My Pi harness. Merge preparation: three multi-process CLI scenarios exceeded Vitest's five-second default on Node 22. Backported #223's existing 30-second budgets for the credential-precedence sequence and two repo-build scenarios. Assertions and product code are unchanged. All 113 CLI tests passed locally on Node 22 with two CPUs; all four focused cases passed with one CPU. Formatting and lint passed. CI correction and merge preparation: GPT-6 in Codex.
476d781 to
796508f
Compare
The SDK needs an end-to-end check of the shipped package and real-Postgres coverage for races that PGlite cannot prove. Adds the packed init → dev → headless insert → stop → publish → authenticated runtime → additive republish flow, plus one real-Postgres block covering the seven concurrency invariants. Both run as unconditional CI checks with fatal startup failures; the test-tier docs explain the commands and isolation. Dev rows remain local, so the hosted flow inserts and reads its own row. **Stacked on `sdk/207-patchy-dev` (#223).** This PR contains only the #208 commit above that branch. Closes #208. ## Verification - Packed e2e and platform/lifecycle/signal probes passed. - Real-Postgres concurrency: 3/3 passed; unavailable Postgres and missing Chromium controls exited 1. - Typecheck, lint and formatting passed; Standards and Spec reviews found no issues. - Full offline suite: 701/701 passed with `--maxWorkers=4`. The initial default-worker run hit a 5-second timeout in the unchanged Postgres runtime test; that test passed independently. GitHub branch-protection settings were not changed; both workflow jobs are unconditional. ## After this PR reaches main - [ ] Once this PR reaches `main`, add `postgres-concurrency` (and the packed e2e job if separate from the already-required `cli-smoke`) to the `main` ruleset; do not add it earlier, because the thirteen stacked PRs below do not emit that context. Implemented with GPT-6 Astra in the Oh My Pi harness.
Patch repos need a way to exercise declared capabilities locally before publishing, without copying production data or replacing the real sandbox with a Vite preview.
Add
patchy devover PGlite and invented fixtures, using the production shell, broker and runtime handlers. The detached lifecycle binds the machine user's identity, checks the release, watches single-file builds, and uses published inventory for additive schema checks. Includes CLI/docs/skill updates and fixes from Standards and Spec review.Stacked on
sdk/206-repo-publish; this PR targets that branch, notmain.Closes #207.
Verification
pnpm lintandpnpm typecheckpassed.pnpm test: 699 tests passed across 74 files.Implemented and reviewed with OpenAI GPT-6 Astra through the Oh My Pi harness.