Skip to content

Move graph exports behind v19 public API boundary - #726

Merged
flyingrobots merged 16 commits into
mainfrom
continuum-observer-runtime-facade
Jul 5, 2026
Merged

Move graph exports behind v19 public API boundary#726
flyingrobots merged 16 commits into
mainfrom
continuum-observer-runtime-facade

Conversation

@flyingrobots

@flyingrobots flyingrobots commented Jul 5, 2026

Copy link
Copy Markdown
Member

Summary

  • documents supported-outcome settlement and the v19 "write intents, read timelines, keep receipts" API direction
  • moves graph/worldline/optic/witness/diagnostic exports out of root/browser and into explicit subpaths
  • deprecates the graph-first legacy API as migration-only so new users do not see two valid product paths
  • adds strict root/browser public API boundary tests and updates package-surface audits

Self-review

  • Found stale script audits that still asserted the old root contract; updated them to enforce root/browser boundary and legacy deprecation.
  • Found the README v19 sample could be read as a shipped quick start; clarified it as the planned v19 facade contract.
  • Found migration wording that implied old patch/open helpers could move to diagnostics; corrected those rows so legacy write/open helpers remain deprecated legacy only.
  • Found post-review root exports that still exposed substrate/index internals; removed them from root and expanded the v19 boundary test.
  • Found receipt examples that collapsed supported outcomes; replaced them with explicit accepted/obstructed/conflicted/underdetermined/rejected handling.

Test plan

  • npm run lint:sludge
  • npm run lint:md
  • npm run lint:md:code
  • npm run lint:docs-topology
  • npm run lint -- --quiet
  • npm run typecheck:src
  • npm run typecheck:test
  • npm run typecheck:consumer
  • npm run typecheck:policy
  • npm run typecheck:surface
  • npx vitest run test/unit/scripts/v18-package-surface-audit.test.ts test/unit/scripts/v19-public-api-boundary.test.ts test/unit/scripts/worldline-api-deprecation.test.ts test/unit/domain/index.exports.test.ts
  • npm run test:coverage:ci
  • pre-push IRONCLAD M9: link check, static gates, and stable unit-test shards

ADR checks

  • No ADR required; this PR implements the already documented v19 API boundary and migration posture.
  • Public API rationale is captured in docs/topics/api/README.md.
  • Migration plan is captured in docs/migrations/v19/README.md.
  • Legacy API remains available only as deprecated migration compatibility.

Validation

  • Pre-push IRONCLAD M9 passed: link check, lint, typecheck:src, typecheck:test, typecheck:consumer, typecheck:surface, typecheck:policy, markdown/doc topology gates, and stable unit-test shards.
  • Focused v19 boundary/audit tests passed.
  • Coverage CI command passed locally: 580 test files, 7,379 tests.
  • Markdown sample lint and git diff whitespace check passed.

Refs #712

@coderabbitai

coderabbitai Bot commented Jul 5, 2026

Copy link
Copy Markdown

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 4250abe8-958a-41ba-a61a-3353e802d611

📥 Commits

Reviewing files that changed from the base of the PR and between 0982174 and 97cfd45.

📒 Files selected for processing (1)
  • docs/migrations/v19/README.md
📜 Recent review details
⏰ Context from checks skipped due to timeout. (3)
  • GitHub Check: coverage-threshold
  • GitHub Check: test-node (22)
  • GitHub Check: preflight
🔇 Additional comments (1)
docs/migrations/v19/README.md (1)

140-142: 🎯 Functional Correctness | ⚡ Quick win

Clarify the write example to use a concrete intent call.

timeline.write(intent) reads like the namespace object itself is passed to write, which does not match the surrounding example. Please spell out the actual intent shape here so readers don't copy an invalid call.

Proposed fix
-`commit((patch) => ...)` is deprecated legacy API. The first-use write surface
-is `timeline.write(intent)`.
+`commit((patch) => ...)` is deprecated legacy API. The first-use write surface
+is `timeline.write(intent.property.set(...))`.

📝 Walkthrough

Summary by CodeRabbit

  • New Features
    • Added new public subpath entry points: storage, advanced, diagnostics, and legacy.
  • Changed
    • Narrowed the default package and browser entry-point surfaces to align with the v19 intent/timeline/reading/receipt API.
    • Deprecated the graph-first legacy API as first-use; legacy is now for explicit migration compatibility.
  • Documentation
    • Updated the README and public API reflection docs, plus added a v19 migration guide with Before/After examples.
  • Tests
    • Adjusted conformance and type-check coverage to validate the new public entry points and boundary posture.

Walkthrough

This PR narrows the package root into a v19 application boundary, moves legacy graph-first compatibility into explicit subpaths, and updates docs, tests, and release checks to match the new public surface.

Changes

v19 API Boundary Restructuring

Layer / File(s) Summary
New subpaths and export surface
advanced.ts, diagnostics.ts, storage.ts, legacy.ts, index.ts, browser.ts, jsr.json, package.json, tsconfig.publish.json, tsconfig.src.json
Adds the new subpath entrypoints, narrows the root/browser export surfaces, and registers the new files in package metadata and build config.
Docs and migration guidance
README.md, CHANGELOG.md, docs/topics/*, docs/migrations/v19/README.md, examples/*, src/domain/WarpApp.ts, src/domain/WarpCore.ts, src/domain/WarpGraph.ts, src/domain/WarpWorldline.ts
Rewrites the public-facing docs, migration guide, examples, and deprecation text around the v19 intent/timeline/reading/receipt model and legacy compatibility.
Boundary and legacy-surface tests
test/conformance/*, test/unit/**, test/type-check/consumer.ts
Redirects tests to legacy.ts and adds assertions for the narrowed root/browser boundary and updated deprecation wording.
Docs-topology and release guards
scripts/check-docs-topology.sh, scripts/release-guard.sh
Treats the v19 migration guide as current and counts unmanaged migration docs during release checks.

Estimated code review effort: 4 (Complex) | ~60 minutes

Possibly related issues

Possibly related PRs

Poem

A rabbit skips where old roots fade,
New burrows mark the v19 grade.
Intents now write, timelines sing,
Receipts still whisper everything.
🐇

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the main change: moving graph exports behind the v19 public API boundary.
Description check ✅ Passed The description matches the template with Summary, Issue, Test plan, and ADR checks sections filled in.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

Comment @coderabbitai help to get the list of available commands.

@github-actions

github-actions Bot commented Jul 5, 2026

Copy link
Copy Markdown

Release Preflight

  • package version: 18.2.1
  • prerelease: false
  • npm dist-tag on release: latest
  • npm pack dry-run: passed
  • jsr publish dry-run: passed

If this PR is from a release/* branch and merges to main, Main Push Release Branch Check will run final preflight and create v18.2.1. A maintainer who is a JSR @git-stunts scope member must then dispatch the Release workflow manually.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 4

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@docs/migrations/v19/README.md`:
- Around line 115-125: The example in the receipt handling section treats every
non-accepted outcome as a generic error, which hides the distinct obstructed,
conflicted, and underdetermined flows used later. Update the snippet around
events.write and receipt.outcome to branch on those specific outcomes instead of
immediately throwing Error(receipt.reason), and preserve the
repair/resolve/support data so readers see how to handle each case correctly.

In `@examples/bounded-reads.ts`:
- Around line 2-10: Update the example header in the bounded-reads sample so it
no longer describes the APIs as the “advanced openWarpGraph() surface,” since
the import comes from the legacy subpath; keep the wording aligned with the
actual symbols GitGraphAdapter and openWarpGraph imported from
`@git-stunts/git-warp/legacy`, and make the text clearly distinguish this
migration example from the new /advanced path to avoid steering readers to the
wrong import.

In `@index.ts`:
- Around line 6-11: The package root exports in index.ts still include
graph-first and storage internals that should be kept behind the documented v19
boundary. Remove the root re-exports for IndexRebuildService,
BitmapIndexBuilder, BitmapIndexReader, BlobStoragePort, and
InMemoryBlobStorageAdapter, and leave those symbols available only through
legacy.ts or the appropriate subpath exports. If any of these must remain at the
root, update the index.ts boundary docstring and related boundary test to
explicitly document that exception.

In `@legacy.ts`:
- Line 216: Keep the top-level call to installDefaultRuntimeHostNodePorts() only
if it is guaranteed to be idempotent, since it runs on import as a module side
effect; otherwise move it behind an explicit initialization path in legacy.ts.
Also revisit the WarpApp default export in the same module and remove the
v15-era compatibility export if it is no longer needed, or otherwise leave a
clear migration-only compatibility path without adding additional deprecation
layers.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: fb0dff67-28d0-4817-97e7-f05595813a1a

📥 Commits

Reviewing files that changed from the base of the PR and between 16cd880 and dcf8d7b.

📒 Files selected for processing (69)
  • CHANGELOG.md
  • README.md
  • advanced.ts
  • bin/cli/commands/optic.ts
  • browser.ts
  • diagnostics.ts
  • docs/migrations/v19/README.md
  • docs/topics/README.md
  • docs/topics/api/README.md
  • docs/topics/continuum-boundary.md
  • docs/topics/getting-started.md
  • docs/topics/git-substrate.md
  • docs/topics/querying.md
  • docs/topics/reference.md
  • docs/topics/strands.md
  • docs/topics/supported-outcome-settlement.md
  • docs/topics/sync.md
  • examples/README.md
  • examples/bounded-reads.ts
  • examples/observers.ts
  • examples/optics.ts
  • index.ts
  • jsr.json
  • legacy.ts
  • package.json
  • scripts/check-docs-topology.sh
  • scripts/release-guard.sh
  • src/domain/WarpApp.ts
  • src/domain/WarpCore.ts
  • src/domain/WarpGraph.ts
  • src/domain/WarpWorldline.ts
  • storage.ts
  • test/conformance/btrProvenanceBoundary.test.ts
  • test/conformance/btrSigningBytesOwnership.test.ts
  • test/conformance/snapshotPublicApiSurface.test.ts
  • test/conformance/v18BoundedMemoryLargeGraphGate.test.ts
  • test/conformance/v18CoordinateOpticPublicPath.test.ts
  • test/conformance/v18FirstUseOpticsHonesty.test.ts
  • test/type-check/consumer.ts
  • test/unit/cli/optic.test.ts
  • test/unit/domain/WarpApp.facade.test.ts
  • test/unit/domain/WarpCore.apiSurface.test.ts
  • test/unit/domain/WarpCore.effectPipeline.test.ts
  • test/unit/domain/WarpCore.emit.test.ts
  • test/unit/domain/WarpGraph.public-sync.test.ts
  • test/unit/domain/WarpGraph.strands.compare.test.ts
  • test/unit/domain/WarpWorldline.test.ts
  • test/unit/domain/continuum/GitWarpReceiptEnvelopeBoundary.test.ts
  • test/unit/domain/index.exports.test.ts
  • test/unit/domain/publicApiExecutableExamples.test.ts
  • test/unit/domain/publicReadApiExecutablePaths.test.ts
  • test/unit/domain/publicReadingSurface.behavior.test.ts
  • test/unit/domain/publicStrandAndRuntimeSeams.test.ts
  • test/unit/domain/services/merge/TtdMergeInspector.test.ts
  • test/unit/domain/services/query/BoundedSupportRule.test.ts
  • test/unit/domain/services/query/CausalIndexPlan.test.ts
  • test/unit/domain/services/query/SupportFragmentPlan.test.ts
  • test/unit/index.exports.test.ts
  • test/unit/scripts/jsr-publish-root-graph-shape.test.ts
  • test/unit/scripts/openwarpgraph-composition-root.test.ts
  • test/unit/scripts/public-api-aperture-noun.test.ts
  • test/unit/scripts/public-api-facade-split.test.ts
  • test/unit/scripts/root-export-line-budget.test.ts
  • test/unit/scripts/v18-package-surface-audit.test.ts
  • test/unit/scripts/v19-public-api-boundary.test.ts
  • test/unit/scripts/worldline-api-deprecation.test.ts
  • test/unit/v7-guards.test.ts
  • tsconfig.publish.json
  • tsconfig.src.json
📜 Review details
⏰ Context from checks skipped due to timeout. (3)
  • GitHub Check: coverage-threshold
  • GitHub Check: test-node (22)
  • GitHub Check: preflight
🧰 Additional context used
📓 Path-based instructions (4)
**/*.{ts,tsx,js,jsx}

📄 CodeRabbit inference engine (AGENTS.md)

**/*.{ts,tsx,js,jsx}: Do not use direct imports from src/infrastructure/** in src/domain/** or src/ports/**; depend on a port instead.
Do not use direct Node built-ins in src/domain/** or src/ports/**; use a port instead.

Files:

  • test/conformance/v18BoundedMemoryLargeGraphGate.test.ts
  • test/unit/domain/WarpApp.facade.test.ts
  • test/unit/index.exports.test.ts
  • test/unit/domain/publicStrandAndRuntimeSeams.test.ts
  • src/domain/WarpCore.ts
  • test/unit/v7-guards.test.ts
  • test/unit/domain/publicReadApiExecutablePaths.test.ts
  • test/conformance/v18CoordinateOpticPublicPath.test.ts
  • test/type-check/consumer.ts
  • test/unit/scripts/root-export-line-budget.test.ts
  • test/unit/scripts/v19-public-api-boundary.test.ts
  • src/domain/WarpApp.ts
  • test/unit/domain/services/query/CausalIndexPlan.test.ts
  • test/unit/scripts/openwarpgraph-composition-root.test.ts
  • test/unit/domain/WarpCore.apiSurface.test.ts
  • src/domain/WarpGraph.ts
  • test/unit/scripts/jsr-publish-root-graph-shape.test.ts
  • test/unit/domain/services/query/SupportFragmentPlan.test.ts
  • test/unit/domain/WarpGraph.strands.compare.test.ts
  • storage.ts
  • test/unit/domain/continuum/GitWarpReceiptEnvelopeBoundary.test.ts
  • test/unit/domain/WarpCore.effectPipeline.test.ts
  • test/unit/domain/index.exports.test.ts
  • test/unit/domain/WarpGraph.public-sync.test.ts
  • test/unit/domain/WarpWorldline.test.ts
  • test/unit/scripts/public-api-facade-split.test.ts
  • bin/cli/commands/optic.ts
  • test/unit/cli/optic.test.ts
  • examples/bounded-reads.ts
  • test/conformance/btrProvenanceBoundary.test.ts
  • test/conformance/v18FirstUseOpticsHonesty.test.ts
  • src/domain/WarpWorldline.ts
  • test/unit/domain/services/query/BoundedSupportRule.test.ts
  • examples/optics.ts
  • test/unit/domain/publicReadingSurface.behavior.test.ts
  • diagnostics.ts
  • test/unit/domain/publicApiExecutableExamples.test.ts
  • test/conformance/btrSigningBytesOwnership.test.ts
  • test/conformance/snapshotPublicApiSurface.test.ts
  • test/unit/scripts/worldline-api-deprecation.test.ts
  • advanced.ts
  • test/unit/domain/WarpCore.emit.test.ts
  • legacy.ts
  • test/unit/scripts/public-api-aperture-noun.test.ts
  • test/unit/scripts/v18-package-surface-audit.test.ts
  • examples/observers.ts
  • test/unit/domain/services/merge/TtdMergeInspector.test.ts
  • browser.ts
  • index.ts
src/**/*.{ts,tsx,js,jsx}

📄 CodeRabbit inference engine (AGENTS.md)

src/**/*.{ts,tsx,js,jsx}: Do not introduce any, as any, as unknown as, unknown (outside adapters), Record<string, unknown> (outside adapters), *Like placeholder types, JSON.parse/JSON.stringify (outside adapters), fetch (outside adapters), process.env (outside adapters), @ts-ignore, or z.any() in core code; use validated boundary models and ports instead.
Use constructor-injected ports for external capabilities; do not rely on ambient dependencies for I/O, clocks, persistence, or entropy.
Do not create utils.ts, helpers.ts, misc.ts, or common.ts; name files after the actual concept they model.
Prefer one file per class, type, or object; if a file accumulates peer concepts, split it.
Keep helper corridors, fake shape trust, transitional duplication, and compile-time theater out of the codebase; runtime-honest TypeScript must reflect actual behavior.
No enum usage; prefer runtime-backed domain forms and unions.
Do not use boolean trap parameters; prefer named option objects or separate methods.
Avoid magic strings or numbers when a named constant should exist.
Keep domain bytes as Uint8Array; Buffer belongs in infrastructure adapters.

Files:

  • src/domain/WarpCore.ts
  • src/domain/WarpApp.ts
  • src/domain/WarpGraph.ts
  • src/domain/WarpWorldline.ts
src/domain/**/*.{ts,tsx,js,jsx}

📄 CodeRabbit inference engine (AGENTS.md)

src/domain/**/*.{ts,tsx,js,jsx}: In src/domain/**, do not use Date.now(), new Date(), Date(), performance.now(), Math.random(), crypto.randomUUID(), crypto.getRandomValues(), setTimeout, setInterval, raw new Error(...)/new TypeError(...), or direct imports from Node built-ins; time, entropy, and external capabilities must enter through ports or parameters, and domain errors should extend WarpError.
Construct domain objects only in core when doing so establishes validated runtime truth; do not build infrastructure adapters, host APIs, persistence implementations, wall clocks, or entropy sources inside core.
Prefer discriminated unions and explicit result types instead of boolean-flag bags, and model expected failures as return values rather than exceptions.
src/domain/ must not import host APIs or Node-specific globals; hexagonal architecture boundaries are mandatory.
Domain code must not use the wall clock directly; time must enter through a port or parameter.

Files:

  • src/domain/WarpCore.ts
  • src/domain/WarpApp.ts
  • src/domain/WarpGraph.ts
  • src/domain/WarpWorldline.ts
src/domain/**/!(*.test).{ts,tsx,js,jsx}

📄 CodeRabbit inference engine (AGENTS.md)

Use explicit domain concepts with validated constructors, Object.freeze, and instanceof dispatch; domain objects should be runtime-backed nouns, not ad hoc shape bags.

Files:

  • src/domain/WarpCore.ts
  • src/domain/WarpApp.ts
  • src/domain/WarpGraph.ts
  • src/domain/WarpWorldline.ts
🧠 Learnings (2)
📚 Learning: 2026-03-08T19:50:17.519Z
Learnt from: flyingrobots
Repo: git-stunts/git-warp PR: 65
File: CHANGELOG.md:88-88
Timestamp: 2026-03-08T19:50:17.519Z
Learning: Follow the Keep a Changelog convention for CHANGELOG.md. Allow duplicate subheadings across versions (e.g., '### Added', '### Fixed'). Configure markdownlint MD024 with {"siblings_only": true} to avoid cross-version false positives.

Applied to files:

  • CHANGELOG.md
📚 Learning: 2026-03-04T12:08:30.347Z
Learnt from: flyingrobots
Repo: git-stunts/git-warp PR: 63
File: package.json:126-126
Timestamp: 2026-03-04T12:08:30.347Z
Learning: Vitest 4 removes vite-node as a dependency and rewrites its pool system. Do not flag the absence of vite-node in package.json or lockfiles as an error for Vitest 4 projects. Use this as a general guideline: if a project uses Vitest 4, missing vite-node is expected and correct; only flag issues if there is evidence the project is not using Vitest 4 or if vite-node is explicitly required by the project.

Applied to files:

  • package.json
🪛 LanguageTool
docs/topics/supported-outcome-settlement.md

[style] ~65-~65: Three successive sentences begin with the same word. Consider rewording the sentence or use a thesaurus to find a synonym.
Context: ...port semantics into git-warp storage. - Do not require zk proof systems for base B...

(ENGLISH_WORD_REPEAT_BEGINNING_RULE)


[style] ~66-~66: Three successive sentences begin with the same word. Consider rewording the sentence or use a thesaurus to find a synonym.
Context: ...oof systems for base BTR publication. - Do not call typed obstructions counterfact...

(ENGLISH_WORD_REPEAT_BEGINNING_RULE)

docs/migrations/v19/README.md

[style] ~314-~314: Three successive sentences begin with the same word. Consider rewording the sentence or use a thesaurus to find a synonym.
Context: ... reads with read(reading.*) calls. 5. Replace seek()/coordinate-first call sites wi...

(ENGLISH_WORD_REPEAT_BEGINNING_RULE)

docs/topics/api/README.md

[style] ~14-~14: To elevate your writing, try using a synonym here.
Context: ...e boundary should be small, boring, and hard to misuse. ## Why Change The v18 publ...

(HARD_TO)

🔇 Additional comments (71)
CHANGELOG.md (1)

10-19: LGTM!

README.md (1)

3-3: LGTM!

Also applies to: 32-43, 54-103, 121-129, 260-279, 333-348

docs/topics/README.md (1)

19-20: LGTM!

docs/topics/continuum-boundary.md (1)

43-43: LGTM!

Also applies to: 67-67

docs/topics/getting-started.md (1)

1-6: LGTM!

Also applies to: 26-33, 51-53

docs/topics/git-substrate.md (1)

6-18: LGTM!

docs/topics/api/README.md (1)

127-129: 📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win

Fix the relative links on this page.

Lines 127-129 use paths as if this file lived at the repo root, but it is nested under docs/topics/api/, so the links resolve incorrectly from here.

Proposed fix
-See the [v19 API reflection](docs/topics/api/), the
-[v19 migration guide](docs/migrations/v19/), and
-[Optic reads](docs/topics/optic-reads.md) for the model.
+See the [v19 API reflection](./), the
+[v19 migration guide](../../migrations/v19/), and
+[Optic reads](../optic-reads.md) for the model.
			> Likely an incorrect or invalid review comment.
docs/topics/querying.md (1)

1-5: LGTM!

Also applies to: 14-29, 42-45

docs/topics/reference.md (1)

15-28: LGTM!

Also applies to: 29-34, 35-105, 107-117

docs/topics/strands.md (1)

3-4: LGTM!

Also applies to: 26-27

docs/topics/supported-outcome-settlement.md (1)

1-66: LGTM!

docs/topics/sync.md (1)

25-26: LGTM!

Also applies to: 39-41

docs/migrations/v19/README.md (1)

1-112: LGTM!

Also applies to: 128-358

scripts/check-docs-topology.sh (1)

18-20: LGTM!

Also applies to: 62-70, 72-96

scripts/release-guard.sh (2)

77-80: LGTM!

Also applies to: 90-99, 403-403


423-449: 📐 Maintainability & Code Quality

No action needed docs/migrations is README-only today, so this scan won’t block any non-doc assets in the current layout.

index.ts (2)

20-55: LGTM!


60-63: LGTM!

Also applies to: 66-102

test/unit/domain/WarpCore.effectPipeline.test.ts (1)

10-10: LGTM!

test/unit/domain/WarpCore.emit.test.ts (1)

5-5: LGTM!

test/unit/domain/WarpGraph.public-sync.test.ts (1)

2-2: LGTM!

test/unit/domain/continuum/GitWarpReceiptEnvelopeBoundary.test.ts (1)

3-3: LGTM!

test/unit/scripts/jsr-publish-root-graph-shape.test.ts (1)

7-7: LGTM!

test/unit/scripts/root-export-line-budget.test.ts (1)

21-26: LGTM!

legacy.ts (2)

1-12: LGTM!


21-21: 🎯 Functional Correctness

No issue: these ports are runtime abstract classes, so the plain imports/exports are fine.

			> Likely an incorrect or invalid review comment.
src/domain/WarpGraph.ts (1)

363-368: LGTM!

test/conformance/btrProvenanceBoundary.test.ts (1)

10-10: LGTM!

test/conformance/btrSigningBytesOwnership.test.ts (1)

8-8: LGTM!

test/conformance/snapshotPublicApiSurface.test.ts (1)

9-9: LGTM!

test/unit/domain/publicApiExecutableExamples.test.ts (1)

3-14: LGTM!

test/unit/domain/publicReadingSurface.behavior.test.ts (1)

9-9: LGTM!

examples/optics.ts (1)

2-12: LGTM!

advanced.ts (1)

1-69: LGTM!

browser.ts (1)

1-45: LGTM!

package.json (1)

4-4: LGTM!

Also applies to: 37-56, 169-174

bin/cli/commands/optic.ts (1)

1-1: 🎯 Functional Correctness

CLI now depends on the deprecated legacy.ts facade.

openWarpWorldline is sourced from legacy.ts, which per this PR's other changes is documented as a "migration-only compatibility facade" pointing to the v19 root API. Shipping CLI production code (not test code) against a module intended for migration-only use is a reasonable stopgap if the v19 root doesn't yet expose equivalent worldline functionality, but should be tracked for follow-up migration once the root API supports it.

test/unit/cli/optic.test.ts (1)

12-21: LGTM!

test/unit/domain/index.exports.test.ts (1)

1-6: 📐 Maintainability & Code Quality | 💤 Low value

Stale header comment.

Header still says "Tests for the main index.ts exports" / "supporting ... the package entry point," but the file now imports from legacy.ts (Lines 9, 143). Update the comment to reflect that this file exercises the legacy.ts compatibility entrypoint, not the root index.ts.

test/unit/domain/services/query/BoundedSupportRule.test.ts (1)

6-6: LGTM!

test/unit/domain/services/query/CausalIndexPlan.test.ts (1)

1-61: LGTM!

diagnostics.ts (1)

1-38: LGTM!

test/conformance/v18FirstUseOpticsHonesty.test.ts (1)

4-4: LGTM!

test/unit/domain/publicReadApiExecutablePaths.test.ts (1)

3-3: LGTM!

test/unit/domain/publicStrandAndRuntimeSeams.test.ts (1)

7-7: LGTM!

test/unit/domain/services/merge/TtdMergeInspector.test.ts (1)

7-10: LGTM!

test/unit/domain/services/query/SupportFragmentPlan.test.ts (1)

8-8: LGTM!

test/unit/index.exports.test.ts (1)

2-21: LGTM!

test/unit/scripts/openwarpgraph-composition-root.test.ts (1)

5-5: LGTM!

Also applies to: 167-170

storage.ts (1)

1-24: LGTM!

jsr.json (1)

10-23: LGTM!

tsconfig.publish.json (1)

14-17: LGTM!

tsconfig.src.json (1)

6-9: LGTM!

test/unit/scripts/v18-package-surface-audit.test.ts (1)

20-104: LGTM!

examples/observers.ts (1)

2-12: LGTM!

test/unit/scripts/v19-public-api-boundary.test.ts (1)

40-63: 🎯 Functional Correctness

No issue here parseExportBlock already strips inline type modifiers, so export { type Bar } is counted correctly.

			> Likely an incorrect or invalid review comment.
src/domain/WarpApp.ts (1)

95-99: LGTM!

src/domain/WarpCore.ts (1)

22-24: LGTM!

src/domain/WarpWorldline.ts (1)

2-5: LGTM!

Also applies to: 158-163

test/unit/domain/WarpCore.apiSurface.test.ts (1)

2-2: LGTM!

test/unit/domain/WarpGraph.strands.compare.test.ts (1)

552-552: LGTM!

test/unit/domain/WarpWorldline.test.ts (1)

3-3: LGTM!

test/unit/scripts/worldline-api-deprecation.test.ts (1)

62-68: LGTM!

Also applies to: 70-76, 77-84, 86-95, 96-103

examples/README.md (1)

1-5: LGTM!

Also applies to: 14-18

test/conformance/v18BoundedMemoryLargeGraphGate.test.ts (1)

3-3: LGTM!

test/conformance/v18CoordinateOpticPublicPath.test.ts (1)

2-2: LGTM!

test/type-check/consumer.ts (1)

149-149: LGTM!

test/unit/domain/WarpApp.facade.test.ts (1)

3-3: LGTM!

test/unit/scripts/public-api-aperture-noun.test.ts (1)

2-9: LGTM!

test/unit/scripts/public-api-facade-split.test.ts (1)

6-7: LGTM!

test/unit/v7-guards.test.ts (1)

1-15: LGTM!

Comment thread docs/migrations/v19/README.md
Comment thread examples/bounded-reads.ts
Comment thread index.ts
Comment thread legacy.ts
@flyingrobots

Copy link
Copy Markdown
Member Author

@codex review please

Code Lawyer Activity Summary

Item Severity Source File(s) Commit Outcome
Root exported substrate/index internals despite v19 boundary P2 Major CodeRabbit index.ts, test/unit/scripts/v19-public-api-boundary.test.ts, docs/topics/reference.md 54200c7c Removed root exports for IndexRebuildService, BitmapIndexBuilder, BitmapIndexReader, BlobStoragePort, and InMemoryBlobStorageAdapter; expanded boundary test.
Legacy compatibility wording and source-version lint P3 Medium CI/Self src/domain/WarpApp.ts, WarpCore.ts, WarpGraph.ts, WarpWorldline.ts, legacy/audit tests d211a4b5 Removed version-name violations from source comments, preserved migration-only deprecation posture, and made the clean-checkout declaration audit tolerant of absent dist/index.d.ts.
Receipt example collapsed supported outcomes P4 Minor CodeRabbit/Self docs/migrations/v19/README.md, docs/topics/api/README.md b7775d0f Replaced generic non-accepted throw with explicit accepted / obstructed / conflicted / underdetermined / rejected handling.
Legacy bounded-read example implied /advanced path P4 Minor CodeRabbit examples/bounded-reads.ts b7775d0f Reworded header to identify openWarpGraph() as legacy migration surface.
Legacy import side effect and default export needed clearer posture P5 Trivial CodeRabbit legacy.ts d211a4b5 Verified installer idempotence and documented why repeated imports do not stack; softened default-export wording to migration-only compatibility.
Markdown style/readability notes P5 Trivial Self/CodeRabbit docs/topics/api/README.md, docs/topics/supported-outcome-settlement.md, docs/migrations/v19/README.md 33d3cfcb Cleaned repeated sentence starts and mechanical wording without changing semantics.

Validation

  • npm run lint:sludge
  • npm run lint:md
  • npm run lint:md:code
  • npm run lint:docs-topology
  • npm run lint -- --quiet
  • npm run typecheck:src
  • npm run typecheck:test
  • npm run typecheck:consumer
  • npm run typecheck:policy
  • npm run typecheck:surface
  • npx vitest run test/unit/scripts/v18-package-surface-audit.test.ts test/unit/scripts/v19-public-api-boundary.test.ts test/unit/scripts/worldline-api-deprecation.test.ts test/unit/domain/index.exports.test.ts
  • npm run test:coverage:ci passed locally: 580 test files, 7,379 tests
  • Pre-push IRONCLAD M9 passed twice after these fixes: link check, all static gates, and stable unit-test shards

Current Gate

  • Review threads: 0 unresolved.
  • PR description: updated with explicit Test plan and ADR checks.
  • Merge gate remains locked until the latest GitHub CI run and CodeRabbit review finish.

@github-actions

github-actions Bot commented Jul 5, 2026

Copy link
Copy Markdown

Release Preflight

  • package version: 18.2.1
  • prerelease: false
  • npm dist-tag on release: latest
  • npm pack dry-run: passed
  • jsr publish dry-run: passed

If this PR is from a release/* branch and merges to main, Main Push Release Branch Check will run final preflight and create v18.2.1. A maintainer who is a JSR @git-stunts scope member must then dispatch the Release workflow manually.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (2)
examples/bounded-reads.ts (1)

5-10: 📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win

"Diagnostic read path" wording now collides with the new /diagnostics subpath.

The "advanced" → "legacy" wording fix from the prior review was applied, but the file still describes materializeSlice() as a "diagnostic read path" (unchanged line 6). Since this PR adds a real diagnostics.ts subpath, this phrasing risks the same migration confusion previously flagged for "advanced" — readers may assume this bounded-cone read belongs on /diagnostics.

✏️ Suggested wording fix
- * openWarpGraph() surface; materializeSlice() is a diagnostic read path.
+ * openWarpGraph() surface; materializeSlice() is a bounded causal-cone read.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@examples/bounded-reads.ts` around lines 5 - 10, Update the comment in
examples/bounded-reads.ts so materializeSlice() is no longer described as a
“diagnostic read path,” since that wording now conflicts with the new
diagnostics subpath. Keep the existing legacy/migration-testing guidance, but
rewrite the doc text near the import of GitGraphAdapter and openWarpGraph to
make it clear this bounded read path is part of the legacy surface and not
related to /diagnostics.
test/unit/scripts/v18-package-surface-audit.test.ts (1)

73-81: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value

Consider asserting the new /advanced and /diagnostics subpaths in the index module doc too.

The check only verifies @git-stunts/git-warp/legacy and @git-stunts/git-warp/storage are mentioned; the PR also introduces advanced.ts and diagnostics.ts as part of the same boundary story.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@test/unit/scripts/v18-package-surface-audit.test.ts` around lines 73 - 81,
The v19 boundary doc test in the package surface audit only checks the existing
legacy and storage subpaths, so update the assertion block in the v18 package
surface audit test to also verify the index module documentation includes the
new /advanced and /diagnostics subpaths. Use the existing indexModuleDoc
expectations in this test to add containment checks for the new subpath
references alongside `@git-stunts/git-warp/legacy` and
`@git-stunts/git-warp/storage`.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@test/unit/domain/index.exports.test.ts`:
- Around line 2-11: This test name is misleading because it validates the legacy
compatibility exports from legacy.ts rather than index.ts. Rename the test file
and any related test description/fixture references to reflect the legacy
compatibility surface, using the existing publicApi import and legacy.ts scope
so it sits logically alongside test/unit/index.exports.test.ts.

---

Outside diff comments:
In `@examples/bounded-reads.ts`:
- Around line 5-10: Update the comment in examples/bounded-reads.ts so
materializeSlice() is no longer described as a “diagnostic read path,” since
that wording now conflicts with the new diagnostics subpath. Keep the existing
legacy/migration-testing guidance, but rewrite the doc text near the import of
GitGraphAdapter and openWarpGraph to make it clear this bounded read path is
part of the legacy surface and not related to /diagnostics.

In `@test/unit/scripts/v18-package-surface-audit.test.ts`:
- Around line 73-81: The v19 boundary doc test in the package surface audit only
checks the existing legacy and storage subpaths, so update the assertion block
in the v18 package surface audit test to also verify the index module
documentation includes the new /advanced and /diagnostics subpaths. Use the
existing indexModuleDoc expectations in this test to add containment checks for
the new subpath references alongside `@git-stunts/git-warp/legacy` and
`@git-stunts/git-warp/storage`.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: d2a898b9-0f95-497a-8d6d-153f466a4c35

📥 Commits

Reviewing files that changed from the base of the PR and between dcf8d7b and b7775d0.

📒 Files selected for processing (14)
  • docs/migrations/v19/README.md
  • docs/topics/api/README.md
  • docs/topics/reference.md
  • examples/bounded-reads.ts
  • index.ts
  • legacy.ts
  • src/domain/WarpApp.ts
  • src/domain/WarpCore.ts
  • src/domain/WarpGraph.ts
  • src/domain/WarpWorldline.ts
  • test/unit/domain/index.exports.test.ts
  • test/unit/scripts/v18-package-surface-audit.test.ts
  • test/unit/scripts/v19-public-api-boundary.test.ts
  • test/unit/scripts/worldline-api-deprecation.test.ts
💤 Files with no reviewable changes (1)
  • index.ts
📜 Review details
⏰ Context from checks skipped due to timeout. (3)
  • GitHub Check: preflight
  • GitHub Check: test-node (22)
  • GitHub Check: coverage-threshold
🧰 Additional context used
📓 Path-based instructions (4)
**/*.{ts,tsx,js,jsx}

📄 CodeRabbit inference engine (AGENTS.md)

**/*.{ts,tsx,js,jsx}: Do not use direct imports from src/infrastructure/** in src/domain/** or src/ports/**; depend on a port instead.
Do not use direct Node built-ins in src/domain/** or src/ports/**; use a port instead.

Files:

  • examples/bounded-reads.ts
  • src/domain/WarpApp.ts
  • src/domain/WarpGraph.ts
  • src/domain/WarpWorldline.ts
  • src/domain/WarpCore.ts
  • test/unit/scripts/v19-public-api-boundary.test.ts
  • test/unit/scripts/v18-package-surface-audit.test.ts
  • test/unit/domain/index.exports.test.ts
  • test/unit/scripts/worldline-api-deprecation.test.ts
  • legacy.ts
src/**/*.{ts,tsx,js,jsx}

📄 CodeRabbit inference engine (AGENTS.md)

src/**/*.{ts,tsx,js,jsx}: Do not introduce any, as any, as unknown as, unknown (outside adapters), Record<string, unknown> (outside adapters), *Like placeholder types, JSON.parse/JSON.stringify (outside adapters), fetch (outside adapters), process.env (outside adapters), @ts-ignore, or z.any() in core code; use validated boundary models and ports instead.
Use constructor-injected ports for external capabilities; do not rely on ambient dependencies for I/O, clocks, persistence, or entropy.
Do not create utils.ts, helpers.ts, misc.ts, or common.ts; name files after the actual concept they model.
Prefer one file per class, type, or object; if a file accumulates peer concepts, split it.
Keep helper corridors, fake shape trust, transitional duplication, and compile-time theater out of the codebase; runtime-honest TypeScript must reflect actual behavior.
No enum usage; prefer runtime-backed domain forms and unions.
Do not use boolean trap parameters; prefer named option objects or separate methods.
Avoid magic strings or numbers when a named constant should exist.
Keep domain bytes as Uint8Array; Buffer belongs in infrastructure adapters.

Files:

  • src/domain/WarpApp.ts
  • src/domain/WarpGraph.ts
  • src/domain/WarpWorldline.ts
  • src/domain/WarpCore.ts
src/domain/**/*.{ts,tsx,js,jsx}

📄 CodeRabbit inference engine (AGENTS.md)

src/domain/**/*.{ts,tsx,js,jsx}: In src/domain/**, do not use Date.now(), new Date(), Date(), performance.now(), Math.random(), crypto.randomUUID(), crypto.getRandomValues(), setTimeout, setInterval, raw new Error(...)/new TypeError(...), or direct imports from Node built-ins; time, entropy, and external capabilities must enter through ports or parameters, and domain errors should extend WarpError.
Construct domain objects only in core when doing so establishes validated runtime truth; do not build infrastructure adapters, host APIs, persistence implementations, wall clocks, or entropy sources inside core.
Prefer discriminated unions and explicit result types instead of boolean-flag bags, and model expected failures as return values rather than exceptions.
src/domain/ must not import host APIs or Node-specific globals; hexagonal architecture boundaries are mandatory.
Domain code must not use the wall clock directly; time must enter through a port or parameter.

Files:

  • src/domain/WarpApp.ts
  • src/domain/WarpGraph.ts
  • src/domain/WarpWorldline.ts
  • src/domain/WarpCore.ts
src/domain/**/!(*.test).{ts,tsx,js,jsx}

📄 CodeRabbit inference engine (AGENTS.md)

Use explicit domain concepts with validated constructors, Object.freeze, and instanceof dispatch; domain objects should be runtime-backed nouns, not ad hoc shape bags.

Files:

  • src/domain/WarpApp.ts
  • src/domain/WarpGraph.ts
  • src/domain/WarpWorldline.ts
  • src/domain/WarpCore.ts
🔇 Additional comments (16)
legacy.ts (3)

216-218: Idempotency and default-export concerns from prior review addressed.

The added comment clarifies the installDefaultRuntimeHostNodePorts() side effect is idempotent (and ES module top-level code only runs once per module instance regardless of import count, so this is a non-issue), and the default-export comment now reflects "old migration callers" as suggested.

Also applies to: 476-477


14-215: LGTM!

Also applies to: 220-260, 261-429


138-138: 🎯 Functional Correctness

No change needed: WarpOpenOptions is a runtime class, so the value import/export is correct.

			> Likely an incorrect or invalid review comment.
examples/bounded-reads.ts (1)

13-38: LGTM!

src/domain/WarpGraph.ts (1)

366-368: LGTM!

src/domain/WarpWorldline.ts (1)

2-5: LGTM!

Also applies to: 158-163

test/unit/scripts/v18-package-surface-audit.test.ts (2)

62-71: LGTM!

Also applies to: 83-106


23-23: 📐 Maintainability & Code Quality

The guard is intentional. The unit-test jobs build first, so this check only skips runs where dist/index.d.ts was never generated.

			> Likely an incorrect or invalid review comment.
test/unit/domain/index.exports.test.ts (1)

12-143: LGTM!

Also applies to: 146-648

docs/migrations/v19/README.md (1)

123-136: LGTM!

docs/topics/api/README.md (1)

121-163: LGTM!

Also applies to: 254-299

docs/topics/reference.md (1)

37-112: LGTM!

src/domain/WarpApp.ts (1)

95-98: LGTM!

src/domain/WarpCore.ts (1)

22-24: LGTM!

test/unit/scripts/v19-public-api-boundary.test.ts (1)

18-39: LGTM!

Also applies to: 111-118

test/unit/scripts/worldline-api-deprecation.test.ts (1)

65-67: LGTM!

Also applies to: 70-80, 86-103

Comment thread test/unit/domain/legacy.exports.test.ts
@github-actions

github-actions Bot commented Jul 5, 2026

Copy link
Copy Markdown

Release Preflight

  • package version: 18.2.1
  • prerelease: false
  • npm dist-tag on release: latest
  • npm pack dry-run: passed
  • jsr publish dry-run: passed

If this PR is from a release/* branch and merges to main, Main Push Release Branch Check will run final preflight and create v18.2.1. A maintainer who is a JSR @git-stunts scope member must then dispatch the Release workflow manually.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@docs/migrations/v19/README.md`:
- Around line 324-325: The migration steps incorrectly present `write(intent.*)`
and `read(reading.*)` as standalone APIs; update the wording in the README to
use the timeline receiver explicitly. In the migration guide section that
mentions `commit((patch) => ...)`, revise the examples and surrounding text to
reference `timeline.write(...)` and `timeline.read(...)` so the docs match the
public receiver-based API and avoid implying a non-existent entry point.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 69098446-7eb3-4ed6-883b-95613f60347d

📥 Commits

Reviewing files that changed from the base of the PR and between b7775d0 and 33d3cfc.

📒 Files selected for processing (3)
  • docs/migrations/v19/README.md
  • docs/topics/api/README.md
  • docs/topics/supported-outcome-settlement.md
📜 Review details
🔇 Additional comments (2)
docs/topics/supported-outcome-settlement.md (1)

1-67: LGTM!

docs/topics/api/README.md (1)

14-14: LGTM!

Comment thread docs/migrations/v19/README.md Outdated
@github-actions

github-actions Bot commented Jul 5, 2026

Copy link
Copy Markdown

Release Preflight

  • package version: 18.2.1
  • prerelease: false
  • npm dist-tag on release: latest
  • npm pack dry-run: passed
  • jsr publish dry-run: passed

If this PR is from a release/* branch and merges to main, Main Push Release Branch Check will run final preflight and create v18.2.1. A maintainer who is a JSR @git-stunts scope member must then dispatch the Release workflow manually.

@flyingrobots

Copy link
Copy Markdown
Member Author

Code Lawyer Addendum

Item Severity Source File(s) Commit Outcome
Legacy export test filename still implied root index.ts coverage P5 Trivial CodeRabbit test/unit/domain/legacy.exports.test.ts 09821741 Renamed test/unit/domain/index.exports.test.ts to legacy.exports.test.ts; kept header aligned with legacy.ts compatibility surface.
Legacy bounded-read example used /diagnostics-confusing wording P4 Minor CodeRabbit examples/bounded-reads.ts 09821741 Reworded materializeSlice() as a bounded causal-cone read, not a diagnostic read path.
Boundary doc audit missed /advanced and /diagnostics assertions P5 Trivial CodeRabbit test/unit/scripts/v18-package-surface-audit.test.ts 09821741 Added module-doc assertions for both subpaths.
Migration guide implied standalone write() / read() entry points P4 Minor CodeRabbit docs/migrations/v19/README.md 97cfd458 Reworded migration steps to timeline.write(...) and timeline.read(...).

Validation for addendum fixes:

  • npx vitest run test/unit/scripts/v18-package-surface-audit.test.ts test/unit/domain/legacy.exports.test.ts
  • npm run lint:md
  • npm run lint:md:code
  • npm run lint:docs-topology
  • pre-push IRONCLAD M9 passed for both follow-up pushes

Current gate: review threads are resolved; latest CI and CodeRabbit are still running after 97cfd458.

@github-actions

github-actions Bot commented Jul 5, 2026

Copy link
Copy Markdown

Release Preflight

  • package version: 18.2.1
  • prerelease: false
  • npm dist-tag on release: latest
  • npm pack dry-run: passed
  • jsr publish dry-run: passed

If this PR is from a release/* branch and merges to main, Main Push Release Branch Check will run final preflight and create v18.2.1. A maintainer who is a JSR @git-stunts scope member must then dispatch the Release workflow manually.

@flyingrobots
flyingrobots merged commit eefb956 into main Jul 5, 2026
17 checks passed
@flyingrobots
flyingrobots deleted the continuum-observer-runtime-facade branch July 5, 2026 11:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant