Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
1 Skipped Deployment
|
PR SummaryMedium Risk Overview Published examples gain a top-bar “Make a local copy” that clones the model into local storage and navigates to the new UUID; storage failures surface an inline alert without leaving the example. Document lifecycle changes: empty nets are no longer deleted when switching files; new records use UUIDs as ids; writes that must persist throw when Docs (website README, drawing guide) and a patch changeset document the behavior. Reviewed by Cursor Bugbot for commit 859581a. Bugbot is set up for automated code reviews on this repo. Configure here. |
There was a problem hiding this comment.
🟡 Changes recommended
The central editor-to-UUID navigation workflow lacks integration coverage.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
Adds persistent UUID routes for browser-local Petrinaut documents and enables editable copies of published examples.
Changes:
- Adds UUID migration, creation, routing, and navigation.
- Adds example copying and missing-document recovery.
- Updates tests, documentation, and release metadata.
File summaries
| File | Description |
|---|---|
.changeset/local-document-urls.md |
Adds the Petrinaut patch changeset. |
apps/petrinaut-website/README.md |
Documents local UUID routes and copies. |
apps/petrinaut-website/src/examples/full-example-page.tsx |
Adds the copy action and error alert. |
apps/petrinaut-website/src/main/app/local-storage-demo/local-storage-demo-app.tsx |
Connects document selection to routing. |
apps/petrinaut-website/src/main/app/local-storage-demo/resolve-crew-reservation-bundle.test.ts |
Adds UUID data to the fixture. |
apps/petrinaut-website/src/main/app/local-storage-demo/use-local-storage-sdcpns.test.ts |
Tests UUID migration and copies. |
apps/petrinaut-website/src/main/app/local-storage-demo/use-local-storage-sdcpns.ts |
Implements UUID persistence and migration. |
apps/petrinaut-website/src/routes/-local.test.tsx |
Tests local routes and history. |
apps/petrinaut-website/src/routes/-new.test.ts |
Tests distinct /new documents. |
apps/petrinaut-website/src/routes/-not-found-page.tsx |
Supports customized recovery messages. |
apps/petrinaut-website/src/routes/__root.tsx |
Adapts root not-found rendering. |
apps/petrinaut-website/src/routes/examples.$slug.tsx |
Saves and opens example copies. |
apps/petrinaut-website/src/routes/index.tsx |
Redirects home to the latest document. |
apps/petrinaut-website/src/routes/local.$uuid.tsx |
Adds the local-document route. |
apps/petrinaut-website/src/routes/new.tsx |
Redirects new documents to UUID URLs. |
libs/@hashintel/petrinaut/docs/drawing-a-net.md |
Documents local URLs and example copies. |
Review details
- Files reviewed: 16/16 changed files
- Comments generated: 1
- Review effort level: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
| if (onNetChange) onNetChange(newNet); | ||
| else clearSharedLocation(); |
| export const Route = createFileRoute("/")({ | ||
| beforeLoad: ({ search }) => { | ||
| readLocalStorageNets(window.localStorage); | ||
| if (isCrewReservationFixtureSelected(search)) return; |
There was a problem hiding this comment.
This is specific to Brunch fixture and should be flagged as something to remove soon.
We should not have (too much) spaghetti in the app.
1014585 to
c482f1f
Compare
c482f1f to
25f7a56
Compare
7851ef3 to
59624f5
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 59624f5. Configure here.
59624f5 to
859581a
Compare

Summary
Local demo documents open at
/local/<UUID>, so bookmarks, reloads, and browser history reopen the selected file. Documents stay in the browser's local storage.Published examples offer Make a local copy in the top bar. The copy opens at its own local URL with editing enabled.
Links
Blocked by
Changes
/to the most recently edited document and/newto a new document@hashintel/petrinautTest coverage
After the 14 September rebase, affected package builds, unit tests, types, lint and architecture checks passed on the integrated stack. Browser recordings and manual checks listed below predate this rebase.
How to test
/examples/sir-epidemic-modelon the website preview/local/<UUID>/local/550e8400-e29b-41d4-a716-446655440000in a browser without that file and confirm the recovery message