Skip to content

docs: fourth-review documentation pass and the lint fix - #670

Merged
pdlug merged 4 commits into
integration/ontology-semanticsfrom
docs/review4-pass
Sep 11, 2026
Merged

pdlug merged 4 commits into
integration/ontology-semanticsfrom
docs/review4-pass

Conversation

@pdlug

@pdlug pdlug commented Sep 11, 2026

Copy link
Copy Markdown
Contributor

Fourth whole-branch review of #637: the lint failure on the integration head and the documentation findings.

Lint

The reparent refusal test bound a filter directly to an awaited read, which the lint rule against await-expression members refuses; the read is bound first now. That was the only CI failure; the Build job was the aggregate gate reporting it.

Documentation

The equivalence-is-subsumption changeset told readers to drop includeSubClasses to stop expansion. Omission now defaults to subclass expansion, so it names expansion: "exact" and points at the typed-subsumption changeset for the migration.

cascadedParts is documented where receipts and hooks are introduced, not only on the limitations page: the receipt guide gains a worked example of a whole's delete reporting its parts on the onOperationEnd context, on the transactionWithReceipt receipt, and on a tx.measure scope's receipt, and states that cascaded parts are refs beside the write-intent counters and never folded into them. The displayed OperationHookContext definition carries the field.

The identity guide's first transitionsOf example read as complete while discarding nextFrom; it now says a page and shows the paging loop first, with a single call described as the first page. The source guide annotated the widened alias kind as a literal union; the comment separates the runtime values from the static type.

The get-or-create partOf postcondition moves out of the required-existence refusals into its own subsection with an outcome table, since it applies to optional parts too and most of its outcomes are successes; the required-existence list is now two refusals with a pointer to it.

Two runnable examples cover the workflows the review found untaught. 28-composition-lifecycle.ts declares a required pair whose realizing edge carries a required property, refuses a bare create, attaches through getOrCreateByConstraint's postcondition (created, found, refused for a different whole), reparents between wholes and to the current whole as a no-op, exports the complete owned unit with subgraph({ composition: true }), and reads the cascade from an onOperationEnd hook and a receipt. 29-identity-history.ts pages transitionsOf and replay on nextFrom with a limit small enough to produce several pages, prunes with pruneIdentityTransitions and shows the no-op below the watermark, and labels restored transitions after a real archival export and import into a second history-enabled store. Both run under pnpm test:examples.

Writing the examples surfaced five facts the guides did not state, now added: CompositionExistenceError.code is constant across situations so callers branch on details.situation; reparent writes a new realizing edge and so restates required edge props; one retraction on a class of three or more members can record more than one retract transition; an archival import that carries a live assertion records one native transition on the target beside the restored rows, on an empty target too; and restored rows keep the source graph's revision, so "oldest first" can list them before or after native rows regardless of when they happened.

…eate postcondition passages

The equivalence changeset told readers to drop includeSubClasses to stop expansion; omission now defaults to subclass expansion, so it names expansion: "exact". The identity guide's first transitionsOf example read as complete while discarding nextFrom; it now says a page and shows the loop first. The source guide annotated the widened alias kind as a literal union; the comment now separates runtime values from the static type. The get-or-create postcondition moves out of the required-existence refusals into its own subsection with an outcome table, since it applies to optional parts too and most outcomes succeed.
The receipt guide gains a worked example of a whole's delete reporting its parts on the onOperationEnd context, on the transaction receipt, and on a tx.measure scope's receipt, and states that cascaded parts are refs beside the write-intent counters, never folded into them. The displayed OperationHookContext definition now carries cascadedParts.
…roughs

Example 28 declares a required composition pair with a realizing edge that carries a required property, refuses a bare create, attaches through getOrCreateByConstraint's postcondition, reparents between wholes, exports the complete owned unit, and reads the cascade from an onOperationEnd hook and a transactionWithReceipt receipt. Example 29 pages transitionsOf and replay on nextFrom, prunes with pruneIdentityTransitions, and labels restored transitions after a real archival export and import round trip. Guides gain the notes writing them surfaced: the composition error's code is constant so callers branch on situation, reparent restates required edge props, one retraction can record more than one transition, an import's live assertion records one native transition, and restored rows keep the source's revision in the listing order.
@pdlug
pdlug merged commit f58fa92 into integration/ontology-semantics Sep 11, 2026
44 of 46 checks passed
@pdlug
pdlug deleted the docs/review4-pass branch September 11, 2026 04:31
pdlug added a commit that referenced this pull request Sep 23, 2026
Fourth whole-branch review of #637: the lint failure on the integration
head and the documentation findings.

## Lint

The reparent refusal test bound a filter directly to an awaited read,
which the lint rule against await-expression members refuses; the read
is bound first now. That was the only CI failure; the Build job was the
aggregate gate reporting it.

## Documentation

The equivalence-is-subsumption changeset told readers to drop
`includeSubClasses` to stop expansion. Omission now defaults to subclass
expansion, so it names `expansion: "exact"` and points at the
typed-subsumption changeset for the migration.

`cascadedParts` is documented where receipts and hooks are introduced,
not only on the limitations page: the receipt guide gains a worked
example of a whole's delete reporting its parts on the `onOperationEnd`
context, on the `transactionWithReceipt` receipt, and on a `tx.measure`
scope's receipt, and states that cascaded parts are refs beside the
write-intent counters and never folded into them. The displayed
`OperationHookContext` definition carries the field.

The identity guide's first `transitionsOf` example read as complete
while discarding `nextFrom`; it now says a page and shows the paging
loop first, with a single call described as the first page. The source
guide annotated the widened alias kind as a literal union; the comment
separates the runtime values from the static type.

The get-or-create `partOf` postcondition moves out of the
required-existence refusals into its own subsection with an outcome
table, since it applies to optional parts too and most of its outcomes
are successes; the required-existence list is now two refusals with a
pointer to it.

Two runnable examples cover the workflows the review found untaught.
`28-composition-lifecycle.ts` declares a required pair whose realizing
edge carries a required property, refuses a bare create, attaches
through `getOrCreateByConstraint`'s postcondition (created, found,
refused for a different whole), reparents between wholes and to the
current whole as a no-op, exports the complete owned unit with
`subgraph({ composition: true })`, and reads the cascade from an
`onOperationEnd` hook and a receipt. `29-identity-history.ts` pages
`transitionsOf` and `replay` on `nextFrom` with a limit small enough to
produce several pages, prunes with `pruneIdentityTransitions` and shows
the no-op below the watermark, and labels restored transitions after a
real archival export and import into a second history-enabled store.
Both run under `pnpm test:examples`.

Writing the examples surfaced five facts the guides did not state, now
added: `CompositionExistenceError.code` is constant across situations so
callers branch on `details.situation`; `reparent` writes a new realizing
edge and so restates required edge props; one retraction on a class of
three or more members can record more than one `retract` transition; an
archival import that carries a live assertion records one native
transition on the target beside the restored rows, on an empty target
too; and restored rows keep the source graph's revision, so "oldest
first" can list them before or after native rows regardless of when they
happened.
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