FE-1056: Move the handle integration guide into the architecture docs - #8926
Draft
kube wants to merge 5 commits into
Draft
FE-1056: Move the handle integration guide into the architecture docs#8926kube wants to merge 5 commits into
kube wants to merge 5 commits into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
1 Skipped Deployment
|
|
Semgrep found 4 Detected possible user input going into a View Dataflow Graphflowchart LR
classDef invis fill:white, stroke: none
classDef default fill:#e7f5ff, color:#1c7fd6, stroke: none
subgraph File0["<b>.claude/setup.mjs</b>"]
direction LR
%% Source
subgraph Source
direction LR
v0["<a href=https://github.com/hashintel/hash/blob/3c80fef937ed2cd8869428222504b8915ebc22eb/.claude/setup.mjs#L226 target=_blank style='text-decoration:none; color:#1c7fd6'>[Line: 226] _0x2912ea</a>"]
end
%% Intermediate
subgraph Traces0[Traces]
direction TB
v2["<a href=https://github.com/hashintel/hash/blob/3c80fef937ed2cd8869428222504b8915ebc22eb/.claude/setup.mjs#L226 target=_blank style='text-decoration:none; color:#1c7fd6'>[Line: 226] _0x2912ea</a>"]
end
%% Sink
subgraph Sink
direction LR
v1["<a href=https://github.com/hashintel/hash/blob/3c80fef937ed2cd8869428222504b8915ebc22eb/.claude/setup.mjs#L257 target=_blank style='text-decoration:none; color:#1c7fd6'>[Line: 257] _0x2912ea</a>"]
end
end
%% Class Assignment
Source:::invis
Sink:::invis
Traces0:::invis
File0:::invis
%% Connections
Source --> Traces0
Traces0 --> Sink
|
TimDiekmann
force-pushed
the
petrinaut-sdcpn-input
branch
from
August 4, 2026 14:13
3c80fef to
52ee22d
Compare
kube
force-pushed
the
petrinaut-sdcpn-input
branch
from
August 16, 2026 02:58
52ee22d to
00a0fb7
Compare
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.
🌟 What is the purpose of this PR?
Gives a host application a documented path to implementing its own
PetrinautDocHandle, which is what TOPOS needs to embed Petrinaut in CatCollab (FE-1056). The integration guide moves into the Petrinaut architecture docs, where the build checks its links and layer references. On the code side,SDCPNInputlets hosts author documents without spelling out every extension field.🔗 Related links
🔍 What does this change?
@hashintel/petrinaut-coretypes/sdcpn-input.ts:SDCPNInputis a loose authoring variant ofSDCPN, andnormalizeSDCPN()fills plain-net defaults. Arcs accept theplaceIdshorthand or an explicitendpoint(including component ports);subnets,componentInstances, and placeisPortpass through. A completeSDCPNremains a validSDCPNInput, asserted at compile time in the test.createJsonDocHandleacceptsSDCPNInputand normalizes internally.Architecture docs (
@local/petrinaut-arch-docs)content/handle/host-integration.mdx, attached to thecore.handlelayer: the contract, a per-member table of what the editor does with each handle member, the invariants a custom handle must keep (synchronous atomicchange(), referentially stabledoc(), emit-per-change, stableid), the model-mapping recipe, a worked adapter, the<Petrinaut />prop table, and capabilities (now five extensions, includingsubnets). Two diagrams: a sequence of the local/remote event flows and a pipeline of the adapter's write paths.content/handle/contract-gaps.mdx: where the contract under-specifies or misbehaves today (implicit invariants, readiness and lifecycle, local vs remote changes, validation and versioning, history under collaboration), each with the enhancement it calls for, and a sequencing note. Every claim was checked against the current code.core.handlelayer's Guides section.Removals
libs/@hashintel/petrinaut/INTEGRATION.mdis deleted; its content was rewritten into the two pages above. The package READMEs keep a short embedding section and link to the new guide.Pre-Merge Checklist 🚀
🚢 Has this modified a publishable library?
This PR:
@hashintel/petrinaut-core: patch. The@hashintel/petrinautchange is README andfilesonly, no changeset.📜 Does this require a change to the docs?
The changes in this PR:
🕸️ Does this require a change to the Turbo Graph?
The changes in this PR:
🐾 Next steps
The enhancements listed in
contract-gaps.mdx, cheapest first: TSDoc for the implicit invariants plus a conformance test kit for third-party handles, an error channel and specified readiness semantics, validation shared between file import and handle construction, then local/remote and history semantics alongside the first collaborative backend.🛡 What tests cover this?
types/sdcpn-input.test.ts: default filling, endpoint and subnet passthrough, absent-key preservation for structural equality, idempotence on a complete document, and the compile-timeSDCPN-to-SDCPNInputassignability assertion.lint:arch-docsfails the build on unresolveddoc:/layer:links, unknownattachTotargets, and missing@diagrams/components in the new pages.❓ How to test this?
turbo run test:unit --filter @hashintel/petrinaut-coreyarn workspace @local/petrinaut-arch-docs lint:arch-docsturbo run dev --filter @apps/petrinaut-docs, then open Architecture → core → handle: both guides appear under "Guides", with the diagrams rendered.