Skip to content

feat: Change Lens on real history, with docs - #411

Merged
byronwall merged 13 commits into
change-lens/mapfrom
change-lens/integrate
Nov 22, 2026
Merged

byronwall merged 13 commits into
change-lens/mapfrom
change-lens/integrate

Conversation

@byronwall

@byronwall byronwall commented Nov 21, 2026 •

Copy link
Copy Markdown
Owner

The Changes view now runs on real history. Open Srcly after a coding session, select Changes, and see which functions the branch or the last days edited, what happened to their complexity, and which to review first. Closes #397.

What you'll see

  • The real review panel beside the map: Already complex and changed, New hotspot, and All edits.
  • A selected chunk shows base → head for each metric, its touch marks, and churned against net lines. Open diff shows only that chunk's lines, under the map.
  • The commit rail under the map. Select a commit to dim the chunks it did not touch; Open diff then shows that commit's hunk.
  • In a long window, each file keeps its largest chunks open and pools the rest into an N more tile.
  • New hotspot now means the chunk crossed complexity 10 in the window. A function that goes 34 → 35 is only in the first list.
  • A new guide, Review changes, on the site, a tour step, and srcly changes in the README, the CLI page and the skill.

Proof

Only edits on this repo, last 7 days
This repo over 7 days: parseLocation selected, 47 → 52, in Already complex and changed.

The diff under the map
Open diff shows only the selected function's hunks, and the selected tile stays visible.

One commit selected
One commit selected in the rail: the chunks it did not touch are dimmed.

In repo
In repo keeps the selection and the inspector.

Touched Net
Touched on the fixture repo Net on the fixture repo

The acceptance repo: pickNext is reverted in Touched and absent in Net.

  • On the rebased top of the stack: scripts/check.sh server 606 passed, scripts/check.sh client 492 passed.
  • Before the rebase onto the engine fixes, the integration worker ran pnpm e2e (21 passed, 1 skipped, with the new changes.spec.ts) and the site build and tests (7 of 7). I did not run those two again after the rebase; CI's browser job runs the e2e suite.
  • These screenshots were taken before the engine fixes in feat(server): Change Lens engine, API and srcly changes #408 were rebased in. The fixture payload did not change in the rebase; the real-repo counts may differ a little.

Limits

  • In repo: the selected chunk's band is hard to find in a 1,184-file map.
  • Small maps can still leave narrow tiles with no label.
  • The pool size is a guess and has no unit test.
  • Folder labels count deleted files, so "N edited / M files" can be slightly off.
  • site/public/screenshots/changes.jpg was captured from this branch. Capture it again after the stack lands.
  • Not in this build: read/edit/ship attribution, parallel-branch compare, blast radius, and the "simplified but widely depended on" list.

Stack: Change Lens, layer 4 of 4

This slice: The join on the real API, the fixes it needed in each layer, one e2e test, and the docs.
Why it is its own layer: It is the first layer that changes what the app does with real data, and it removes the mock and the plan folder that the lower layers used.
Full story: #408

Survey moves: -1 partial trace in client and fewer stops (frontier: disconnected -22, frontier: budget-exhausted -4, boundary: unproven-handoff -3, frontier: untraced -3, frontier: external-code -3, boundary: framework-runtime -1). They come from deleting the mock sample.ts and slots.tsx and rewiring the view to the panel. No analysis code changed and no trace errored.

🤖 Generated with Claude Code

@byronwall
byronwall added this pull request to stack #412 November 21, 2026 23:58
@byronwall byronwall changed the title change lens/integrate feat: Change Lens on real history, with docs Nov 21, 2026
@byronwall
byronwall force-pushed the change-lens/integrate branch from 8ac9ce3 to 4cf2865 Compare November 22, 2026 00:15
byronwall and others added 13 commits November 21, 2026 22:00
A chunk that was already at 10 or more and rose landed in both buckets.
New hotspot now needs base below 10 or absent. Metric pairs come out in a
fixed order, so the fixture payloads are stable.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Changes view now uses the panel components and the server, with no
mock data. Paths follow selection.scope, so zoom, breadcrumbs and Open
code work when the scan root is a folder inside the repo. A new result
keeps the selected chunk and commit when they still exist, and the diff
waits for the new result. The file count leaves deleted files out of
the total. Long windows pool each file's smaller chunks into one tile,
the diff opens under the map instead of over it, and the inspector folds
unchanged metrics into one line.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… into the color menu (#397)

Open diff and the arrow keys show the selected commit's hunk when that
commit changed the chunk. Now and Delta sit in the color menu, so the
toolbar fits at 1440 px with the file tree open.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
#397)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The guide holds the window, touched/net, chunk and review bucket rules.
capture.mjs gains the changes shot over a fixed commit range.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Its lasting facts now live in the Review changes guide, the code map and
types.ts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ors (#397)

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@byronwall
byronwall force-pushed the change-lens/integrate branch from 4cf2865 to dfc56bf Compare November 22, 2026 03:03
@byronwall
byronwall marked this pull request as ready for review November 22, 2026 03:03
@byronwall
byronwall merged commit 4727bd5 into main Nov 22, 2026
14 of 15 checks passed
@byronwall
byronwall deleted the change-lens/integrate branch November 22, 2026 03:14
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.

Change Lens: filter the treemap to recently edited code chunks

1 participant