Skip to content

test(dogfood): full package-lifecycle gate for package-first authoring (ADR-0070 D3/D4/D5)#2358

Merged
os-zhuang merged 1 commit into
mainfrom
adr0070-dogfood-gate
Jun 27, 2026
Merged

test(dogfood): full package-lifecycle gate for package-first authoring (ADR-0070 D3/D4/D5)#2358
os-zhuang merged 1 commit into
mainfrom
adr0070-dogfood-gate

Conversation

@xuyushun441-sys

Copy link
Copy Markdown
Contributor

What

Extends the ADR-0070 dogfood gate from the D1/D2 backstop alone to the full package-lifecycle contract, against the real booted stack.

Until now package-first-authoring.dogfood.test.ts only proved D1/D2 (the kernel rejects a runtime-only create into a read-only code package with writable_package_required). ADR-0070's other guarantee — "the package is the authoring & delete unit" (D3/D4/D5) — was only ever live-verified by hand (the ADR's app.iojn dogfood). This closes the Epic #2278 "Dogfood gate" item by automating that chain.

New coverage (3 added blocks, all green)

Regressing deletePackage / duplicatePackage / reassignOrphanedMetadata now turns this red, alongside the original D1 backstop.

Notes

  • Test-only change to the private @objectstack/dogfood package → no changeset.
  • Asserts against the durable sys_metadata store (what every lifecycle method reads), so the checks are deterministic.
  • Local run: 5 passed (5).

🤖 Generated with Claude Code

…g (ADR-0070 D3/D4/D5)

The existing dogfood gate only proved the D1/D2 backstop (kernel rejects a
runtime-only create into a read-only code package with `writable_package_required`).
ADR-0070's other guarantee — "the package is the authoring & delete unit" — was
only ever live-verified by hand. This promotes that manual dogfood into an
automated proof against the real booted stack:

- D3/D4 full chain: create -> bind -> publish -> editable -> discoverable
  (getMetaItems by package) -> delete-cascade (deletePackage empties the base).
  The "editable" step guards the #2252 read-only-after-publish trap directly.
- D5 migration: reassignOrphanedMetadata rebinds a legacy package-less row
  (the #2252/#1946 stopgap shape: package_id = null) onto a base.
- D4 duplicate: duplicatePackage clones ACTIVE items into a new base,
  re-namespacing object names and rewriting intra-package references.

Regressing deletePackage / duplicatePackage / reassignOrphanedMetadata now turns
this red, alongside the original D1 backstop.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@vercel

vercel Bot commented Jun 27, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
spec Ready Ready Preview, Comment Jun 27, 2026 11:36am

Request Review

@github-actions

Copy link
Copy Markdown
Contributor

📓 Docs Drift Check

No hand-written docs reference the 1 changed package(s). ✅

@os-zhuang
os-zhuang merged commit e7b59f9 into main Jun 27, 2026
17 checks passed
@os-zhuang
os-zhuang deleted the adr0070-dogfood-gate branch June 27, 2026 14:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants