Skip to content

feat: run comparison - graph diff view - #2602

Open
camielvs wants to merge 1 commit into
cmp-06-structured-diff-viewfrom
cmp-07-graph-diff-view
Open

feat: run comparison - graph diff view#2602
camielvs wants to merge 1 commit into
cmp-06-structured-diff-viewfrom
cmp-07-graph-diff-view

Conversation

@camielvs

@camielvs camielvs commented Jul 30, 2026

Copy link
Copy Markdown
Collaborator

Description

Seventh PR in the Compare Runs stack. Adds the Graph view — a visual, side-by-side-in-one-canvas take on the comparison.

It renders the merged graph (from #2597) with colour-coded nodes and edges: green for added, red for removed, amber for changed, grey for unchanged, plus a legend. Nodes show each task's status, digest and a short change summary; clicking one opens a detail popover reusing the same task/IO diff detail from the Structured view. A Highlight A / B / Both control dims everything not present in the chosen run and switches nodes to show that run's actual values.

Also refactors the run view's status indicator to extract a reusable StatusTab so the merged task nodes can show per-run (A/B) status tabs.

Related Issue and Pull requests

Part of the Compare Runs stack. Builds on #2601; the final PR (#2603) builds on this branch.

Type of Change

  • New feature
  • Cleanup/Refactor

Checklist

  • I have tested this does not break current pipelines / runs functionality
  • I have tested the changes on staging

Screenshots (if applicable)

Test Instructions

Reachable once the stack is wired up (#2603).

  • Check out the top of the stack, enable the Compare runs beta flag, and compare two runs.
  • On the Graph tab, confirm:
    • The merged graph lays out and node/edge colours match the legend (added / removed / changed / unchanged).
    • Clicking a node opens its detail popover; clicking the background closes it.
    • Highlight A / B / Both dims the other run and shows the highlighted run's values.
  • Regression check the refactor: open a normal run's graph and confirm task status indicators (including the cache-disabled state) still render as before.

Additional Comments

@github-actions

github-actions Bot commented Jul 30, 2026

Copy link
Copy Markdown

🎩 Preview

A preview build has been created at: cmp-07-graph-diff-view/05c821c

camielvs commented Jul 30, 2026

Copy link
Copy Markdown
Collaborator Author

@camielvs
camielvs force-pushed the cmp-07-graph-diff-view branch from e34d81d to 22f985a Compare July 30, 2026 23:22
@camielvs
camielvs force-pushed the cmp-06-structured-diff-view branch 2 times, most recently from f58787e to 6d8d1a9 Compare July 31, 2026 00:24
@camielvs
camielvs force-pushed the cmp-07-graph-diff-view branch 2 times, most recently from a1c4ec9 to 69226d7 Compare July 31, 2026 01:05
@camielvs
camielvs force-pushed the cmp-06-structured-diff-view branch from 6d8d1a9 to 15d5b88 Compare July 31, 2026 01:05
@camielvs
camielvs force-pushed the cmp-07-graph-diff-view branch from 69226d7 to cf080ba Compare July 31, 2026 01:36
@camielvs
camielvs force-pushed the cmp-06-structured-diff-view branch from 15d5b88 to 16384ae Compare July 31, 2026 01:36
@camielvs
camielvs force-pushed the cmp-07-graph-diff-view branch 2 times, most recently from e6b562b to 659f92c Compare August 14, 2026 19:07
@camielvs
camielvs force-pushed the cmp-06-structured-diff-view branch 2 times, most recently from 1c31e0a to 63ee9b6 Compare August 14, 2026 21:01
@camielvs
camielvs force-pushed the cmp-07-graph-diff-view branch from 659f92c to 3605a8d Compare August 14, 2026 21:01
@camielvs
camielvs force-pushed the cmp-07-graph-diff-view branch from 3605a8d to eefad45 Compare August 14, 2026 23:47
@camielvs
camielvs force-pushed the cmp-06-structured-diff-view branch from 63ee9b6 to e57e483 Compare August 14, 2026 23:47
Comment thread src/routes/v2/pages/CompareView/components/GraphDiffView.tsx
<div
title={label ? `${label} · ${text}` : text}
className={cn(
"h-8.75 overflow-hidden rounded-t-md px-2.5 py-1 text-[10px]",

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

🤖 This is an AI-generated code review comment.

The extraction changes how the existing indicator renders (Medium)

StatusTab is a clean extraction, but it adds overflow-hidden here plus whitespace-nowrap and truncate on the inner row — none of which the original markup had — and StatusIndicator below now renders through it. So editor and run-graph task nodes start truncating status text instead of wrapping it, which is outside this PR's stated scope.

If the truncation is only needed for the two side-by-side tabs in the compare graph, pass it in via className from MergedTaskNode and leave the shared path rendering as it did.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

🤖 AI-generated reply.

Checked this one and I do not think it changes the existing indicator — leaving the extraction as is.

  • On the StatusIndicator path the new classes are inert: the wrapper is absolute … flex items-start with no width cap, so the tab is shrink-to-fit and there is nothing for min-w-0 / truncate / overflow-hidden to act on.
  • They are load-bearing in MergedTaskNode, which passes min-w-0 flex-1 into a w-64 node — that is what the extraction was for.

One real change I will own: the shared tab adds a native title tooltip, so the editor and run graph now get a hover tooltip on the status label where they previously had none. Happy to gate that behind a prop if it is unwanted.

@camielvs
camielvs force-pushed the cmp-06-structured-diff-view branch from e57e483 to 53c193a Compare August 17, 2026 20:01
@camielvs
camielvs force-pushed the cmp-07-graph-diff-view branch from eefad45 to 1ac3709 Compare August 17, 2026 20:01
@camielvs
camielvs force-pushed the cmp-07-graph-diff-view branch from 1ac3709 to 7b1a733 Compare August 17, 2026 23:03
@camielvs
camielvs force-pushed the cmp-06-structured-diff-view branch from 53c193a to 3886fe5 Compare August 17, 2026 23:03
@camielvs
camielvs force-pushed the cmp-07-graph-diff-view branch from 7b1a733 to 38a92d3 Compare August 18, 2026 00:44
@camielvs
camielvs force-pushed the cmp-06-structured-diff-view branch from 3886fe5 to 6294327 Compare August 18, 2026 00:44
@camielvs
camielvs force-pushed the cmp-06-structured-diff-view branch from 6294327 to de2ad56 Compare August 18, 2026 00:56
@camielvs
camielvs force-pushed the cmp-07-graph-diff-view branch from 38a92d3 to 05c821c Compare August 18, 2026 00:56
@camielvs
camielvs marked this pull request as ready for review August 18, 2026 01:20
@camielvs
camielvs requested a review from a team as a code owner August 18, 2026 01:20
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