Skip to content

FE-627: Update tsgo/vite/rolldown + better React hooks linting in Petrinaut#8708

Merged
kube merged 10 commits into
mainfrom
cf/fe-627-update-petrinaut-tech-stack-and-dev-tooling
May 11, 2026
Merged

FE-627: Update tsgo/vite/rolldown + better React hooks linting in Petrinaut#8708
kube merged 10 commits into
mainfrom
cf/fe-627-update-petrinaut-tech-stack-and-dev-tooling

Conversation

@kube
Copy link
Copy Markdown
Collaborator

@kube kube commented May 8, 2026

🌟 What is the purpose of this PR?

Update the Petrinaut frontend toolchain and linting after extracting the library.

This is just a temporary update to have React Hooks linting in Petrinaut and Refractive (the only packages using Oxlint at the moment), and is not meant to be the final config every package will have to use once we migrate all packages to Oxlint.

🔍 What does this change?

  • Upgrades Petrinaut, Refractive, and the Petrinaut website dev tooling around tsgo, Vite, Rolldown, Oxlint, and related packages.
  • Adds shared Oxlint config for React Hooks, React Compiler diagnostics, and React Refresh checks.
  • Fixes Petrinaut React Hooks exhaustive-deps issues surfaced by the new config.
  • Updates @apps/petrinaut-website main/app.tsx to keep one active document handle, persist localStorage metadata correctly, and hide the ephemeral default net from the Open menu.
  • Updates @hashintel/petrinaut sdcpn-view.tsx to use useEffectEvent so the load-time fit reads the latest minZoom without refitting on every minZoom change.

Pre-Merge Checklist 🚀

🚢 Has this modified a publishable library?

This PR:

  • modifies an npm-publishable library and I have added a changeset file(s)

📜 Does this require a change to the docs?

The changes in this PR:

  • are internal and do not require a docs change

🕸️ Does this require a change to the Turbo Graph?

The changes in this PR:

  • do not affect the execution graph

🐾 Next steps

  • Follow up on React Refresh only-export-components refactors in Petrinaut.

🛡 What tests cover this?

  • yarn fix:eslint
  • yarn lint:tsc

❓ How to test this?

  1. Check CI.
  2. Run the Petrinaut lint/typecheck scripts locally.

@vercel
Copy link
Copy Markdown

vercel Bot commented May 8, 2026

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

Project Deployment Actions Updated (UTC)
hash Ready Ready Preview, Comment May 11, 2026 3:41pm
hashdotdesign-tokens Ready Ready Preview, Comment May 11, 2026 3:41pm
petrinaut Ready Ready Preview, Comment May 11, 2026 3:41pm

@cursor
Copy link
Copy Markdown

cursor Bot commented May 8, 2026

PR Summary

Medium Risk
Medium risk due to behavioral refactors in Petrinaut’s demo app net/handle lifecycle and the simulation timeline’s uPlot update flow, which could affect persistence, undo history, or chart rendering despite being mostly hook/lint-driven changes.

Overview
Adds shared Oxlint React Compiler/React Hooks lint config via .config/oxlint/react-compiler.json, and updates Petrinaut/Refractive/website .oxlintrc.json to extend it (removing per-package react-hooks/* overrides).

Upgrades frontend tooling across the Petrinaut website, @hashintel/petrinaut, and @hashintel/refractive (notably oxlint, oxlint-tsgolint, @typescript/native-preview, vite, plus rolldown/rolldown-plugin-dts and storybook in Petrinaut), with corresponding yarn.lock updates.

Fixes hook/lifecycle issues surfaced by stricter linting: refactors apps/petrinaut-website DevApp to maintain a single active PetrinautDocHandle (instead of per-net cached handles), introduces a default ephemeral net for display, and tightens localStorage syncing/cleanup when switching or creating nets.

Adjusts Petrinaut UI behavior and effects to stabilize dependencies and updates: scroll shadow calculation in VerticalSubViewsContainer, keyboard shortcut listener effect setup, SimulationTimeline uPlot data/update flow (dropping explicit revision prop and updating data based on store length/data changes), adds tabIndex={-1} to list rows for focus management, and uses useEffectEvent in SDCPNView for load-time fitView without refitting on every minZoom change.

Reviewed by Cursor Bugbot for commit 6e9bd3a. Bugbot is set up for automated code reviews on this repo. Configure here.

@github-actions github-actions Bot added area/deps Relates to third-party dependencies (area) area/libs Relates to first-party libraries/crates/packages (area) type/eng > frontend Owned by the @frontend team area/apps labels May 8, 2026
@augmentcode
Copy link
Copy Markdown

augmentcode Bot commented May 8, 2026

🤖 Augment PR Summary

Summary: This PR updates Petrinaut’s frontend tooling stack and switches to more comprehensive React hooks linting via oxlint’s JS plugin integration.

Changes:

  • Introduced a shared oxlint configuration for React Compiler + hooks rules (.config/oxlint/react-compiler.json) and extended it from Petrinaut-related packages.
  • Upgraded oxlint, oxlint-tsgolint, and TypeScript’s native preview version in affected packages.
  • Upgraded build/dev dependencies in @hashintel/petrinaut (e.g. Rolldown, Storybook, Vite) to newer releases.
  • Adjusted multiple hooks/effects and callbacks across Petrinaut to satisfy stricter hooks linting and avoid unnecessary dependencies.
  • Refined Simulation Timeline’s uPlot lifecycle/data wiring (removing explicit revision prop and syncing via derived data changes).
  • Minor UI/a11y tweak: added tabIndex={-1} to list options in the filterable list subview.

Technical Notes: The new oxlint config disables the built-in React hooks rules and enables eslint-plugin-react-hooks via react-hooks-js, aiming for more precise dependency analysis while working with React 19 + React Compiler constraints.

🤖 Was this summary useful? React with 👍 or 👎

Copy link
Copy Markdown

@augmentcode augmentcode Bot left a comment

Choose a reason for hiding this comment

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

Review completed. No suggestions at this time.

Comment augment review to trigger a new review at any time.

Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit c23120f. Configure here.

Comment thread libs/@hashintel/petrinaut/src/ui/views/SDCPN/sdcpn-view.tsx Outdated
@codspeed-hq
Copy link
Copy Markdown

codspeed-hq Bot commented May 11, 2026

Merging this PR will not alter performance

✅ 80 untouched benchmarks


Comparing cf/fe-627-update-petrinaut-tech-stack-and-dev-tooling (6e9bd3a) with main (f8eae3a)1

Open in CodSpeed

Footnotes

  1. No successful run was found on main (926f9fa) during the generation of this report, so f8eae3a was used instead as the comparison base. There might be some changes unrelated to this pull request in this report.

@codecov
Copy link
Copy Markdown

codecov Bot commented May 11, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 62.29%. Comparing base (f8eae3a) to head (6e9bd3a).
⚠️ Report is 3 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #8708   +/-   ##
=======================================
  Coverage   62.29%   62.29%           
=======================================
  Files        1353     1353           
  Lines      136575   136575           
  Branches     5788     5788           
=======================================
+ Hits        85085    85086    +1     
+ Misses      50582    50581    -1     
  Partials      908      908           
Flag Coverage Δ
apps.hash-ai-worker-ts 1.41% <ø> (ø)
blockprotocol.type-system 40.84% <ø> (ø)
local.claude-hooks 0.00% <ø> (ø)
local.harpc-client 51.24% <ø> (ø)
local.hash-backend-utils 2.81% <ø> (ø)
local.hash-graph-sdk 9.63% <ø> (ø)
local.hash-isomorphic-utils 0.00% <ø> (ø)
rust.antsi 0.00% <ø> (ø)
rust.error-stack 90.87% <ø> (ø)
rust.harpc-codec 84.70% <ø> (ø)
rust.harpc-net 96.21% <ø> (+0.01%) ⬆️
rust.harpc-tower 67.03% <ø> (ø)
rust.harpc-types 0.00% <ø> (ø)
rust.harpc-wire-protocol 92.23% <ø> (ø)
rust.hash-codec 72.76% <ø> (ø)
rust.hash-graph-api 2.52% <ø> (ø)
rust.hash-graph-authorization 62.34% <ø> (ø)
rust.hash-graph-postgres-store 26.38% <ø> (ø)
rust.hash-graph-store 37.76% <ø> (ø)
rust.hash-graph-temporal-versioning 47.95% <ø> (ø)
rust.hash-graph-types 0.00% <ø> (ø)
rust.hash-graph-validation 83.45% <ø> (ø)
rust.hashql-ast 87.23% <ø> (ø)
rust.hashql-compiletest 29.63% <ø> (ø)
rust.hashql-core 82.38% <ø> (ø)
rust.hashql-diagnostics 72.43% <ø> (ø)
rust.hashql-eval 69.13% <ø> (ø)
rust.hashql-hir 89.06% <ø> (ø)
rust.hashql-mir 92.45% <ø> (ø)
rust.hashql-syntax-jexpr 94.06% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

alex-e-leon
alex-e-leon previously approved these changes May 11, 2026
Copy link
Copy Markdown
Contributor

@alex-e-leon alex-e-leon left a comment

Choose a reason for hiding this comment

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

Haven't run/tested the changes locally, but as far as I can tell from a quick skim it all looks good.

If you preferred not to include/write your own oxlint rule .json file for react-compiler though this project has all the eslint-recommended packs transformed for oxlint:
https://github.com/popup-plus/oxlint-config-presets

@kube
Copy link
Copy Markdown
Collaborator Author

kube commented May 11, 2026

Haven't run/tested the changes locally, but as far as I can tell from a quick skim it all looks good.

If you preferred not to include/write your own oxlint rule .json file for react-compiler though this project has all the eslint-recommended packs transformed for oxlint: https://github.com/popup-plus/oxlint-config-presets

@alex-e-leon Yeah would definitely be better to use existing configs.
I don't have the time to do these changes right now, as I know the choice of the preset will be subject to debate.

If you want to create a PR for this go ahead!

@alex-e-leon
Copy link
Copy Markdown
Contributor

@alex-e-leon Yeah would definitely be better to use existing configs. I don't have the time to do these changes right now, as I know the choice of the preset will be subject to debate.

If you want to create a PR for this go ahead!

For eslint-plugin-react-hooks there's only really one preset option to choose from which is react-hooks/recommended so I think that should prevent any debate : ) (technically there is also react-hooks/recommended-latest but I think we can all agree we don't want to be guinea pigs for rules that are still experiments)

Happy to do it some time later as well though - totally understand if you don't have time to action right now - neither do I! : )

Comment thread .config/oxlint/react-compiler.json Outdated
@kube kube added this pull request to the merge queue May 11, 2026
@github-merge-queue github-merge-queue Bot removed this pull request from the merge queue due to failed status checks May 11, 2026
@kube kube added this pull request to the merge queue May 11, 2026
Merged via the queue into main with commit 6ed87d7 May 11, 2026
176 checks passed
@kube kube deleted the cf/fe-627-update-petrinaut-tech-stack-and-dev-tooling branch May 11, 2026 16:39
@github-actions
Copy link
Copy Markdown
Contributor

Benchmark results

@rust/hash-graph-benches – Integrations

policy_resolution_large

Function Value Mean Flame graphs
resolve_policies_for_actor user: empty, selectivity: high, policies: 2002 $$19.9 \mathrm{ms} \pm 91.1 \mathrm{μs}\left({\color{gray}1.71 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: low, policies: 1 $$2.61 \mathrm{ms} \pm 14.3 \mathrm{μs}\left({\color{gray}-1.276 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: medium, policies: 1001 $$9.78 \mathrm{ms} \pm 68.5 \mathrm{μs}\left({\color{gray}0.240 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: high, policies: 3314 $$34.4 \mathrm{ms} \pm 260 \mathrm{μs}\left({\color{gray}2.92 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: low, policies: 1 $$11.1 \mathrm{ms} \pm 71.9 \mathrm{μs}\left({\color{gray}-0.965 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: medium, policies: 1526 $$18.8 \mathrm{ms} \pm 171 \mathrm{μs}\left({\color{gray}0.674 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: high, policies: 2078 $$20.6 \mathrm{ms} \pm 121 \mathrm{μs}\left({\color{gray}-1.957 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: low, policies: 1 $$2.85 \mathrm{ms} \pm 11.0 \mathrm{μs}\left({\color{gray}-1.352 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: medium, policies: 1033 $$10.4 \mathrm{ms} \pm 78.9 \mathrm{μs}\left({\color{gray}0.325 \mathrm{\%}}\right) $$ Flame Graph

policy_resolution_medium

Function Value Mean Flame graphs
resolve_policies_for_actor user: empty, selectivity: high, policies: 102 $$2.88 \mathrm{ms} \pm 14.7 \mathrm{μs}\left({\color{gray}-0.190 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: low, policies: 1 $$2.29 \mathrm{ms} \pm 7.72 \mathrm{μs}\left({\color{gray}-1.488 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: medium, policies: 51 $$2.57 \mathrm{ms} \pm 10.9 \mathrm{μs}\left({\color{gray}-0.318 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: high, policies: 269 $$3.95 \mathrm{ms} \pm 19.1 \mathrm{μs}\left({\color{gray}-0.736 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: low, policies: 1 $$2.73 \mathrm{ms} \pm 14.2 \mathrm{μs}\left({\color{gray}-1.211 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: medium, policies: 107 $$3.14 \mathrm{ms} \pm 16.5 \mathrm{μs}\left({\color{gray}-0.952 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: high, policies: 133 $$3.38 \mathrm{ms} \pm 25.4 \mathrm{μs}\left({\color{gray}1.20 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: low, policies: 1 $$2.67 \mathrm{ms} \pm 13.2 \mathrm{μs}\left({\color{gray}-0.268 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: medium, policies: 63 $$3.11 \mathrm{ms} \pm 16.8 \mathrm{μs}\left({\color{gray}-0.354 \mathrm{\%}}\right) $$ Flame Graph

policy_resolution_none

Function Value Mean Flame graphs
resolve_policies_for_actor user: empty, selectivity: high, policies: 2 $$2.07 \mathrm{ms} \pm 13.0 \mathrm{μs}\left({\color{lightgreen}-9.636 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: low, policies: 1 $$1.94 \mathrm{ms} \pm 8.72 \mathrm{μs}\left({\color{gray}-0.557 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: medium, policies: 1 $$2.04 \mathrm{ms} \pm 9.12 \mathrm{μs}\left({\color{gray}-0.526 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: high, policies: 8 $$2.25 \mathrm{ms} \pm 8.49 \mathrm{μs}\left({\color{gray}-1.167 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: low, policies: 1 $$2.11 \mathrm{ms} \pm 10.2 \mathrm{μs}\left({\color{gray}0.041 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: medium, policies: 3 $$2.26 \mathrm{ms} \pm 12.6 \mathrm{μs}\left({\color{gray}0.473 \mathrm{\%}}\right) $$ Flame Graph

policy_resolution_small

Function Value Mean Flame graphs
resolve_policies_for_actor user: empty, selectivity: high, policies: 52 $$2.32 \mathrm{ms} \pm 11.3 \mathrm{μs}\left({\color{gray}0.171 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: low, policies: 1 $$2.09 \mathrm{ms} \pm 8.92 \mathrm{μs}\left({\color{gray}-0.743 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: medium, policies: 25 $$2.28 \mathrm{ms} \pm 11.6 \mathrm{μs}\left({\color{gray}0.469 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: high, policies: 94 $$2.59 \mathrm{ms} \pm 10.4 \mathrm{μs}\left({\color{gray}-0.617 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: low, policies: 1 $$2.27 \mathrm{ms} \pm 11.7 \mathrm{μs}\left({\color{gray}-0.793 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: medium, policies: 26 $$2.51 \mathrm{ms} \pm 12.1 \mathrm{μs}\left({\color{gray}-0.460 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: high, policies: 66 $$2.54 \mathrm{ms} \pm 12.7 \mathrm{μs}\left({\color{gray}0.355 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: low, policies: 1 $$2.28 \mathrm{ms} \pm 11.2 \mathrm{μs}\left({\color{gray}-0.647 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: medium, policies: 29 $$2.51 \mathrm{ms} \pm 9.12 \mathrm{μs}\left({\color{gray}-0.513 \mathrm{\%}}\right) $$ Flame Graph

read_scaling_complete

Function Value Mean Flame graphs
entity_by_id;one_depth 1 entities $$42.1 \mathrm{ms} \pm 214 \mathrm{μs}\left({\color{gray}-0.944 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;one_depth 10 entities $$35.6 \mathrm{ms} \pm 125 \mathrm{μs}\left({\color{gray}-1.855 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;one_depth 25 entities $$39.7 \mathrm{ms} \pm 170 \mathrm{μs}\left({\color{gray}-1.276 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;one_depth 5 entities $$35.1 \mathrm{ms} \pm 348 \mathrm{μs}\left({\color{gray}1.82 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;one_depth 50 entities $$48.9 \mathrm{ms} \pm 216 \mathrm{μs}\left({\color{gray}-1.299 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 1 entities $$47.2 \mathrm{ms} \pm 153 \mathrm{μs}\left({\color{gray}-2.248 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 10 entities $$43.1 \mathrm{ms} \pm 145 \mathrm{μs}\left({\color{gray}-0.624 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 25 entities $$79.2 \mathrm{ms} \pm 338 \mathrm{μs}\left({\color{gray}-1.807 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 5 entities $$61.6 \mathrm{ms} \pm 4.48 \mathrm{ms}\left({\color{red}70.9 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 50 entities $$228 \mathrm{ms} \pm 648 \mathrm{μs}\left({\color{gray}0.588 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 1 entities $$14.9 \mathrm{ms} \pm 71.5 \mathrm{μs}\left({\color{gray}-2.013 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 10 entities $$15.5 \mathrm{ms} \pm 67.7 \mathrm{μs}\left({\color{gray}-0.147 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 25 entities $$15.6 \mathrm{ms} \pm 65.4 \mathrm{μs}\left({\color{gray}0.358 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 5 entities $$14.8 \mathrm{ms} \pm 60.8 \mathrm{μs}\left({\color{gray}-4.745 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 50 entities $$19.9 \mathrm{ms} \pm 97.3 \mathrm{μs}\left({\color{red}5.05 \mathrm{\%}}\right) $$ Flame Graph

read_scaling_linkless

Function Value Mean Flame graphs
entity_by_id 1 entities $$15.0 \mathrm{ms} \pm 58.7 \mathrm{μs}\left({\color{gray}-0.536 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id 10 entities $$14.9 \mathrm{ms} \pm 85.2 \mathrm{μs}\left({\color{gray}-1.837 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id 100 entities $$15.0 \mathrm{ms} \pm 86.3 \mathrm{μs}\left({\color{gray}-0.848 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id 1000 entities $$15.6 \mathrm{ms} \pm 75.8 \mathrm{μs}\left({\color{gray}-0.520 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id 10000 entities $$20.4 \mathrm{ms} \pm 130 \mathrm{μs}\left({\color{gray}-1.388 \mathrm{\%}}\right) $$ Flame Graph

representative_read_entity

Function Value Mean Flame graphs
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/block/v/1 $$25.9 \mathrm{ms} \pm 167 \mathrm{μs}\left({\color{gray}-4.514 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/book/v/1 $$26.3 \mathrm{ms} \pm 232 \mathrm{μs}\left({\color{gray}-0.599 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/building/v/1 $$26.1 \mathrm{ms} \pm 193 \mathrm{μs}\left({\color{gray}0.324 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/organization/v/1 $$27.0 \mathrm{ms} \pm 201 \mathrm{μs}\left({\color{gray}0.885 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/page/v/2 $$26.5 \mathrm{ms} \pm 201 \mathrm{μs}\left({\color{gray}-4.469 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/person/v/1 $$26.2 \mathrm{ms} \pm 200 \mathrm{μs}\left({\color{gray}-2.368 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/playlist/v/1 $$26.7 \mathrm{ms} \pm 231 \mathrm{μs}\left({\color{gray}-2.239 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/song/v/1 $$27.5 \mathrm{ms} \pm 181 \mathrm{μs}\left({\color{gray}2.90 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/uk-address/v/1 $$26.0 \mathrm{ms} \pm 201 \mathrm{μs}\left({\color{gray}-0.925 \mathrm{\%}}\right) $$ Flame Graph

representative_read_entity_type

Function Value Mean Flame graphs
get_entity_type_by_id Account ID: bf5a9ef5-dc3b-43cf-a291-6210c0321eba $$6.51 \mathrm{ms} \pm 36.7 \mathrm{μs}\left({\color{gray}-0.354 \mathrm{\%}}\right) $$ Flame Graph

representative_read_multiple_entities

Function Value Mean Flame graphs
entity_by_property traversal_paths=0 0 $$70.8 \mathrm{ms} \pm 315 \mathrm{μs}\left({\color{gray}-1.336 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=255 1,resolve_depths=inherit:1;values:255;properties:255;links:127;link_dests:126;type:true $$113 \mathrm{ms} \pm 429 \mathrm{μs}\left({\color{gray}-1.075 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:0;links:0;link_dests:0;type:false $$76.5 \mathrm{ms} \pm 397 \mathrm{μs}\left({\color{gray}-0.429 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:0;links:1;link_dests:0;type:true $$84.8 \mathrm{ms} \pm 385 \mathrm{μs}\left({\color{gray}-0.824 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:2;links:1;link_dests:0;type:true $$90.8 \mathrm{ms} \pm 391 \mathrm{μs}\left({\color{gray}0.360 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:2;properties:2;links:1;link_dests:0;type:true $$96.7 \mathrm{ms} \pm 366 \mathrm{μs}\left({\color{gray}-0.771 \mathrm{\%}}\right) $$
link_by_source_by_property traversal_paths=0 0 $$80.0 \mathrm{ms} \pm 356 \mathrm{μs}\left({\color{gray}-1.788 \mathrm{\%}}\right) $$
link_by_source_by_property traversal_paths=255 1,resolve_depths=inherit:1;values:255;properties:255;links:127;link_dests:126;type:true $$103 \mathrm{ms} \pm 429 \mathrm{μs}\left({\color{gray}-0.581 \mathrm{\%}}\right) $$
link_by_source_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:0;links:0;link_dests:0;type:false $$85.8 \mathrm{ms} \pm 364 \mathrm{μs}\left({\color{gray}0.480 \mathrm{\%}}\right) $$
link_by_source_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:0;links:1;link_dests:0;type:true $$92.7 \mathrm{ms} \pm 327 \mathrm{μs}\left({\color{gray}0.030 \mathrm{\%}}\right) $$
link_by_source_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:2;links:1;link_dests:0;type:true $$93.7 \mathrm{ms} \pm 400 \mathrm{μs}\left({\color{gray}-0.428 \mathrm{\%}}\right) $$
link_by_source_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:2;properties:2;links:1;link_dests:0;type:true $$93.5 \mathrm{ms} \pm 437 \mathrm{μs}\left({\color{gray}-0.504 \mathrm{\%}}\right) $$

scenarios

Function Value Mean Flame graphs
full_test query-limited $$147 \mathrm{ms} \pm 537 \mathrm{μs}\left({\color{gray}-4.547 \mathrm{\%}}\right) $$ Flame Graph
full_test query-unlimited $$145 \mathrm{ms} \pm 1.73 \mathrm{ms}\left({\color{lightgreen}-9.752 \mathrm{\%}}\right) $$ Flame Graph
linked_queries query-limited $$31.3 \mathrm{ms} \pm 147 \mathrm{μs}\left({\color{gray}-1.710 \mathrm{\%}}\right) $$ Flame Graph
linked_queries query-unlimited $$442 \mathrm{ms} \pm 602 \mathrm{μs}\left({\color{gray}1.21 \mathrm{\%}}\right) $$ Flame Graph

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/apps area/deps Relates to third-party dependencies (area) area/libs Relates to first-party libraries/crates/packages (area) type/eng > frontend Owned by the @frontend team

Development

Successfully merging this pull request may close these issues.

3 participants