Skip to content

Conversation

@indietyp
Copy link
Member

@indietyp indietyp commented Jan 30, 2026

Modernize the HashQL Compiletest UI

🌟 What is the purpose of this PR?

This PR modernizes the HashQL compiletest UI by replacing the indicatif-based progress reporting with a more robust and feature-rich TUI (Text User Interface) using ratatui. It also improves the overall architecture of the test harness by separating concerns and providing multiple output formats.

🔍 What does this change?

  • Replaces indicatif and tracing-indicatif with ratatui for a more interactive terminal UI
  • Adds three output modes: interactive TUI, human-readable text, and JSON
  • Restructures the codebase with a cleaner architecture separating test discovery, execution, and reporting
  • Improves error reporting and diagnostic verification
  • Adds detailed statistics for test runs including timing breakdowns, I/O operations, and slowest tests
  • Enhances the CLI interface with better documentation and more options

Pre-Merge Checklist 🚀

🚢 Has this modified a publishable library?

This PR:

  • does not modify any publishable blocks or libraries, or modifications do not need publishing

📜 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

🛡 What tests cover this?

The changes are to the test harness itself, which is used to run tests for HashQL.

❓ How to test this?

  1. Run the compiletest CLI with different output formats:
    • cargo run -p hashql-compiletest -- run (interactive TUI)
    • cargo run -p hashql-compiletest -- run --format human
    • cargo run -p hashql-compiletest -- run --format json
  2. Try listing tests: cargo run -p hashql-compiletest -- list
  3. Try listing suites: cargo run -p hashql-compiletest -- suites

screenshot.2026-01-31T00-21-13.mp4 (uploaded via Graphite)

@cursor
Copy link

cursor bot commented Jan 30, 2026

PR Summary

Medium Risk
Large refactor of the internal test harness execution/reporting path and CLI behavior, with new terminal UI/event-loop code and many dependency shifts; risk is mainly regressions in test discovery, output formatting, and nextest integration rather than production runtime.

Overview
Modernizes the hashql-compiletest execution and UI pipeline by replacing the old executor/reporter (Indicatif + tracing-indicatif) flow with a new runner + harness architecture.

Adds a ratatui-powered interactive TUI (with inline progress, live running list, and aggregated timing/I/O stats), plus refreshed human and newline-delimited JSON outputs; the CLI is moved to runner::cli and nextest_bridge now executes via the new runner.

Refactors test discovery/trial execution into new harness::test and harness::trial modules, including per-trial timing/I/O statistics and a new annotation verification API that returns structured AnnotationErrors; dependencies are updated accordingly (adds ratatui/ansi-to-tui, removes indicatif/tracing-indicatif/radix_trie, and updates generated dependency diagrams).

Written by Cursor Bugbot for commit f56bb1d. This will update automatically on new commits. Configure here.

Copy link
Member Author

indietyp commented Jan 30, 2026

Warning

This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more

This stack of pull requests is managed by Graphite. Learn more about stacking.

@codecov
Copy link

codecov bot commented Jan 30, 2026

Codecov Report

❌ Patch coverage is 3.43688% with 1461 lines in your changes missing coverage. Please review.
✅ Project coverage is 61.43%. Comparing base (0af7773) to head (f56bb1d).

Files with missing lines Patch % Lines
...ibs/@local/hashql/compiletest/src/runner/ui/tui.rs 0.00% 360 Missing ⚠️
...s/@local/hashql/compiletest/src/runner/ui/human.rs 0.00% 216 Missing ⚠️
...bs/@local/hashql/compiletest/src/runner/ui/json.rs 0.00% 160 Missing ⚠️
...@local/hashql/compiletest/src/harness/trial/mod.rs 0.00% 137 Missing ⚠️
libs/@local/hashql/compiletest/src/runner/mod.rs 0.00% 108 Missing ⚠️
...local/hashql/compiletest/src/harness/trial/list.rs 0.00% 99 Missing ⚠️
...ocal/hashql/compiletest/src/harness/trial/stats.rs 0.00% 72 Missing ⚠️
.../@local/hashql/compiletest/src/runner/ui/common.rs 20.98% 64 Missing ⚠️
libs/@local/hashql/compiletest/src/runner/cli.rs 0.00% 43 Missing ⚠️
...ocal/hashql/compiletest/src/harness/trial/group.rs 0.00% 42 Missing ⚠️
... and 9 more
Additional details and impacted files
@@                                      Coverage Diff                                      @@
##           bm/be-302-hashql-statement-coloring-based-on-capabilities    #8340      +/-   ##
=============================================================================================
+ Coverage                                                      60.49%   61.43%   +0.94%     
=============================================================================================
  Files                                                            292     1129     +837     
  Lines                                                          48113   115540   +67427     
  Branches                                                         953     4710    +3757     
=============================================================================================
+ Hits                                                           29106    70984   +41878     
- Misses                                                         18678    43745   +25067     
- Partials                                                         329      811     +482     
Flag Coverage Δ
apps.hash-ai-worker-ts 1.41% <ø> (?)
apps.hash-api 0.00% <ø> (?)
blockprotocol.type-system 40.84% <ø> (?)
local.claude-hooks 0.00% <ø> (?)
local.harpc-client 51.24% <ø> (?)
local.hash-graph-sdk 10.88% <ø> (?)
local.hash-isomorphic-utils 0.00% <ø> (?)
rust.harpc-net 96.14% <ø> (?)
rust.harpc-tower 66.80% <ø> (ø)
rust.harpc-wire-protocol 92.23% <ø> (?)
rust.hash-codec 72.76% <ø> (?)
rust.hash-graph-api 2.88% <ø> (?)
rust.hash-graph-authorization 62.47% <ø> (?)
rust.hash-graph-postgres-store 25.61% <ø> (ø)
rust.hash-graph-store 30.54% <ø> (?)
rust.hash-graph-temporal-versioning 47.95% <ø> (ø)
rust.hash-graph-types 0.00% <ø> (?)
rust.hash-graph-validation 83.45% <ø> (?)
rust.hashql-ast 87.25% <ø> (?)
rust.hashql-compiletest 29.58% <3.43%> (-17.08%) ⬇️
rust.hashql-core 81.33% <ø> (ø)
rust.hashql-eval 68.54% <ø> (?)
rust.hashql-hir 89.10% <ø> (ø)
rust.hashql-mir 90.08% <ø> (?)
rust.hashql-syntax-jexpr 94.05% <ø> (?)

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.

@vercel
Copy link

vercel bot commented Jan 30, 2026

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

2 Skipped Deployments
Project Deployment Actions Updated (UTC)
hashdotdesign Ignored Ignored Preview Jan 30, 2026 11:36pm
hashdotdesign-tokens Ignored Ignored Preview Jan 30, 2026 11:36pm

@augmentcode
Copy link

augmentcode bot commented Jan 30, 2026

🤖 Augment PR Summary

Summary: Modernizes the HashQL compiletest harness by replacing indicatif-based progress reporting with a ratatui-powered TUI and introducing a cleaner runner/harness split.

Changes:

  • Introduced a new runner module with a clap-based CLI supporting interactive, human, and json formats.
  • Reworked test discovery and execution into a new harness (test corpus → trial corpus → trial set) with per-trial timing/I/O statistics.
  • Replaced indicatif/tracing-indicatif with a ratatui TUI (plus ansi-to-tui) and added structured JSON output for machine consumption.
  • Improved diagnostic/annotation verification by isolating annotation errors and rendering diagnostics consistently.
  • Adjusted suite code to use the new trial error types and suppressed noisy subprocess stderr where appropriate.

Technical Notes: Uses rayon for parallel execution, reports aggregated phase breakdowns, and routes tracing output differently depending on UI mode (plain/human vs JSON vs TUI).

🤖 Was this summary useful? React with 👍 or 👎

Copy link

@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. 4 suggestions posted.

Fix All in Augment

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

}

pub(crate) fn read_file_to_string(&mut self, path: impl AsRef<Path>) -> io::Result<String> {
let content = fs::read_to_string(path)?;

Check failure

Code scanning / Semgrep PRO

Semgrep Finding: rust.actix.path-traversal.tainted-path.tainted-path Error

The application builds a file path from potentially untrusted data, which can lead to a path traversal vulnerability. An attacker can manipulate the path which the application uses to access files. If the application does not validate user input and sanitize file paths, sensitive files such as configuration or user data can be accessed, potentially creating or overwriting files. To prevent this vulnerability, validate and sanitize any input that is used to create references to file paths. Also, enforce strict file access controls. For example, choose privileges allowing public-facing applications to access only the required files.
@codspeed-hq
Copy link

codspeed-hq bot commented Jan 30, 2026

CodSpeed Performance Report

Merging this PR will not alter performance

Comparing bm/be-360-hashql-rework-compiletest (f56bb1d) with bm/be-302-hashql-statement-coloring-based-on-capabilities (0af7773)

Summary

✅ 21 untouched benchmarks
🗄️ 12 archived benchmarks run1

Footnotes

  1. 12 benchmarks were run, but are now archived. If they were deleted in another branch, consider rebasing to remove them from the report. Instead if they were added back, click here to restore them.

Copy link

@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 2 potential issues.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.


tracing::error!(message, location, %backtrace, "encountered panic");
PANICKED.store(true, Ordering::SeqCst);
}
Copy link

Choose a reason for hiding this comment

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

Panic flag set but never checked for exit code

Medium Severity

The PANICKED static flag is set to true in the panic hook but is never read when determining the exit code. The old code checked PANICKED.load() and called exit(1) if any panic occurred. The new report_errors function only checks if reports.is_empty(), ignoring the flag. This means panics occurring outside of run_catch (e.g., in UI code or harness logic) could result in a success exit code despite a panic being logged.

Additional Locations (1)

Fix in Cursor Fix in Web

@github-actions
Copy link
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 $$27.8 \mathrm{ms} \pm 603 \mathrm{μs}\left({\color{lightgreen}-20.440 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: low, policies: 1 $$3.41 \mathrm{ms} \pm 23.6 \mathrm{μs}\left({\color{gray}3.37 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: medium, policies: 1001 $$12.2 \mathrm{ms} \pm 77.0 \mathrm{μs}\left({\color{gray}-0.009 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: high, policies: 3314 $$42.7 \mathrm{ms} \pm 310 \mathrm{μs}\left({\color{gray}1.07 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: low, policies: 1 $$14.5 \mathrm{ms} \pm 104 \mathrm{μs}\left({\color{gray}1.03 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: medium, policies: 1526 $$23.7 \mathrm{ms} \pm 134 \mathrm{μs}\left({\color{gray}-0.089 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: high, policies: 2078 $$48.1 \mathrm{ms} \pm 273 \mathrm{μs}\left({\color{red}17.6 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: low, policies: 1 $$20.6 \mathrm{ms} \pm 155 \mathrm{μs}\left({\color{red}9.10 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: medium, policies: 1033 $$31.1 \mathrm{ms} \pm 221 \mathrm{μs}\left({\color{red}16.8 \mathrm{\%}}\right) $$ Flame Graph

policy_resolution_medium

Function Value Mean Flame graphs
resolve_policies_for_actor user: empty, selectivity: high, policies: 102 $$3.64 \mathrm{ms} \pm 17.0 \mathrm{μs}\left({\color{gray}0.984 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: low, policies: 1 $$2.88 \mathrm{ms} \pm 12.0 \mathrm{μs}\left({\color{gray}0.172 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: medium, policies: 51 $$3.26 \mathrm{ms} \pm 16.8 \mathrm{μs}\left({\color{gray}0.889 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: high, policies: 269 $$5.00 \mathrm{ms} \pm 30.1 \mathrm{μs}\left({\color{gray}0.136 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: low, policies: 1 $$3.57 \mathrm{ms} \pm 26.0 \mathrm{μs}\left({\color{gray}3.71 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: medium, policies: 107 $$4.01 \mathrm{ms} \pm 24.0 \mathrm{μs}\left({\color{gray}0.629 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: high, policies: 133 $$4.23 \mathrm{ms} \pm 29.6 \mathrm{μs}\left({\color{gray}-0.989 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: low, policies: 1 $$3.35 \mathrm{ms} \pm 16.0 \mathrm{μs}\left({\color{gray}1.40 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: medium, policies: 63 $$3.90 \mathrm{ms} \pm 18.2 \mathrm{μs}\left({\color{gray}-0.452 \mathrm{\%}}\right) $$ Flame Graph

policy_resolution_none

Function Value Mean Flame graphs
resolve_policies_for_actor user: empty, selectivity: high, policies: 2 $$2.49 \mathrm{ms} \pm 14.6 \mathrm{μs}\left({\color{gray}0.443 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: low, policies: 1 $$2.45 \mathrm{ms} \pm 14.4 \mathrm{μs}\left({\color{gray}0.802 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: medium, policies: 1 $$2.52 \mathrm{ms} \pm 11.1 \mathrm{μs}\left({\color{gray}0.462 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: high, policies: 8 $$2.75 \mathrm{ms} \pm 13.5 \mathrm{μs}\left({\color{gray}2.28 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: low, policies: 1 $$2.65 \mathrm{ms} \pm 14.6 \mathrm{μs}\left({\color{gray}2.93 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: medium, policies: 3 $$2.76 \mathrm{ms} \pm 10.7 \mathrm{μs}\left({\color{gray}-2.175 \mathrm{\%}}\right) $$ Flame Graph

policy_resolution_small

Function Value Mean Flame graphs
resolve_policies_for_actor user: empty, selectivity: high, policies: 52 $$2.81 \mathrm{ms} \pm 12.4 \mathrm{μs}\left({\color{gray}-0.842 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: low, policies: 1 $$2.45 \mathrm{ms} \pm 9.29 \mathrm{μs}\left({\color{gray}-1.632 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: medium, policies: 25 $$2.66 \mathrm{ms} \pm 10.7 \mathrm{μs}\left({\color{gray}0.187 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: high, policies: 94 $$3.11 \mathrm{ms} \pm 11.0 \mathrm{μs}\left({\color{gray}-0.721 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: low, policies: 1 $$2.71 \mathrm{ms} \pm 9.66 \mathrm{μs}\left({\color{gray}-0.894 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: medium, policies: 26 $$2.95 \mathrm{ms} \pm 12.2 \mathrm{μs}\left({\color{gray}-0.379 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: high, policies: 66 $$3.17 \mathrm{ms} \pm 21.4 \mathrm{μs}\left({\color{gray}4.39 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: low, policies: 1 $$2.70 \mathrm{ms} \pm 9.49 \mathrm{μs}\left({\color{gray}-0.252 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: medium, policies: 29 $$2.90 \mathrm{ms} \pm 9.74 \mathrm{μs}\left({\color{gray}-0.492 \mathrm{\%}}\right) $$ Flame Graph

read_scaling_complete

Function Value Mean Flame graphs
entity_by_id;one_depth 1 entities $$38.9 \mathrm{ms} \pm 137 \mathrm{μs}\left({\color{lightgreen}-6.463 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;one_depth 10 entities $$73.8 \mathrm{ms} \pm 335 \mathrm{μs}\left({\color{lightgreen}-5.350 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;one_depth 25 entities $$44.0 \mathrm{ms} \pm 194 \mathrm{μs}\left({\color{lightgreen}-6.943 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;one_depth 5 entities $$44.9 \mathrm{ms} \pm 227 \mathrm{μs}\left({\color{lightgreen}-5.780 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;one_depth 50 entities $$54.1 \mathrm{ms} \pm 309 \mathrm{μs}\left({\color{lightgreen}-8.476 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 1 entities $$39.9 \mathrm{ms} \pm 145 \mathrm{μs}\left({\color{lightgreen}-7.972 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 10 entities $$396 \mathrm{ms} \pm 1.01 \mathrm{ms}\left({\color{gray}-0.617 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 25 entities $$87.2 \mathrm{ms} \pm 342 \mathrm{μs}\left({\color{lightgreen}-13.286 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 5 entities $$76.5 \mathrm{ms} \pm 364 \mathrm{μs}\left({\color{lightgreen}-5.265 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 50 entities $$308 \mathrm{ms} \pm 681 \mathrm{μs}\left({\color{red}5.97 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 1 entities $$14.4 \mathrm{ms} \pm 63.8 \mathrm{μs}\left({\color{lightgreen}-8.957 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 10 entities $$14.7 \mathrm{ms} \pm 63.9 \mathrm{μs}\left({\color{lightgreen}-8.406 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 25 entities $$15.0 \mathrm{ms} \pm 58.9 \mathrm{μs}\left({\color{lightgreen}-7.329 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 5 entities $$14.7 \mathrm{ms} \pm 52.4 \mathrm{μs}\left({\color{lightgreen}-6.079 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 50 entities $$17.7 \mathrm{ms} \pm 75.2 \mathrm{μs}\left({\color{lightgreen}-8.476 \mathrm{\%}}\right) $$ Flame Graph

read_scaling_linkless

Function Value Mean Flame graphs
entity_by_id 1 entities $$14.6 \mathrm{ms} \pm 53.1 \mathrm{μs}\left({\color{lightgreen}-5.818 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id 10 entities $$14.6 \mathrm{ms} \pm 62.6 \mathrm{μs}\left({\color{lightgreen}-6.171 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id 100 entities $$14.6 \mathrm{ms} \pm 64.4 \mathrm{μs}\left({\color{lightgreen}-5.131 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id 1000 entities $$15.3 \mathrm{ms} \pm 80.9 \mathrm{μs}\left({\color{gray}-3.019 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id 10000 entities $$21.7 \mathrm{ms} \pm 111 \mathrm{μs}\left({\color{gray}-2.649 \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 $$28.7 \mathrm{ms} \pm 319 \mathrm{μs}\left({\color{gray}-3.844 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/book/v/1 $$29.0 \mathrm{ms} \pm 214 \mathrm{μs}\left({\color{gray}0.105 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/building/v/1 $$29.2 \mathrm{ms} \pm 247 \mathrm{μs}\left({\color{gray}1.34 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/organization/v/1 $$29.5 \mathrm{ms} \pm 239 \mathrm{μs}\left({\color{gray}1.19 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/page/v/2 $$28.2 \mathrm{ms} \pm 208 \mathrm{μs}\left({\color{lightgreen}-5.436 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/person/v/1 $$28.2 \mathrm{ms} \pm 219 \mathrm{μs}\left({\color{gray}-3.262 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/playlist/v/1 $$28.4 \mathrm{ms} \pm 206 \mathrm{μs}\left({\color{gray}-1.848 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/song/v/1 $$29.3 \mathrm{ms} \pm 269 \mathrm{μs}\left({\color{gray}-1.496 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/uk-address/v/1 $$29.4 \mathrm{ms} \pm 195 \mathrm{μs}\left({\color{gray}1.08 \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 $$7.96 \mathrm{ms} \pm 30.8 \mathrm{μs}\left({\color{gray}-0.857 \mathrm{\%}}\right) $$ Flame Graph

representative_read_multiple_entities

Function Value Mean Flame graphs
entity_by_property traversal_paths=0 0 $$43.0 \mathrm{ms} \pm 221 \mathrm{μs}\left({\color{gray}-3.025 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=255 1,resolve_depths=inherit:1;values:255;properties:255;links:127;link_dests:126;type:true $$91.3 \mathrm{ms} \pm 378 \mathrm{μs}\left({\color{gray}-1.302 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:0;links:0;link_dests:0;type:false $$49.0 \mathrm{ms} \pm 203 \mathrm{μs}\left({\color{gray}-2.846 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:0;links:1;link_dests:0;type:true $$57.6 \mathrm{ms} \pm 302 \mathrm{μs}\left({\color{gray}-1.372 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:2;links:1;link_dests:0;type:true $$66.2 \mathrm{ms} \pm 373 \mathrm{μs}\left({\color{gray}-0.552 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:2;properties:2;links:1;link_dests:0;type:true $$71.9 \mathrm{ms} \pm 355 \mathrm{μs}\left({\color{gray}-2.085 \mathrm{\%}}\right) $$
link_by_source_by_property traversal_paths=0 0 $$47.2 \mathrm{ms} \pm 256 \mathrm{μs}\left({\color{gray}-1.332 \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 $$74.8 \mathrm{ms} \pm 467 \mathrm{μs}\left({\color{gray}0.098 \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 $$54.0 \mathrm{ms} \pm 297 \mathrm{μs}\left({\color{gray}-1.310 \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 $$61.6 \mathrm{ms} \pm 323 \mathrm{μs}\left({\color{gray}-1.370 \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 $$63.9 \mathrm{ms} \pm 380 \mathrm{μs}\left({\color{gray}-1.458 \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 $$64.0 \mathrm{ms} \pm 426 \mathrm{μs}\left({\color{gray}-0.105 \mathrm{\%}}\right) $$

scenarios

Function Value Mean Flame graphs
full_test query-limited $$135 \mathrm{ms} \pm 409 \mathrm{μs}\left({\color{gray}-1.743 \mathrm{\%}}\right) $$ Flame Graph
full_test query-unlimited $$133 \mathrm{ms} \pm 448 \mathrm{μs}\left({\color{gray}-3.174 \mathrm{\%}}\right) $$ Flame Graph
linked_queries query-limited $$39.9 \mathrm{ms} \pm 272 \mathrm{μs}\left({\color{lightgreen}-62.976 \mathrm{\%}}\right) $$ Flame Graph
linked_queries query-unlimited $$563 \mathrm{ms} \pm 753 \mathrm{μs}\left({\color{lightgreen}-12.695 \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 > hash* Affects HASH (a `hash-*` app) area/apps > hash-graph area/apps area/deps Relates to third-party dependencies (area) area/libs Relates to first-party libraries/crates/packages (area) area/tests New or updated tests type/eng > backend Owned by the @backend team

Development

Successfully merging this pull request may close these issues.

2 participants