Repository navigation
Description
Finding
PR #4154 added a non-trivial client-side behavior layer to the aggregator /aa page — viewBox zoom math with focal-point anchoring, pan clamping, per-chart zoom state that must survive (or deliberately drop across) redraws, deferred pointer capture so plain clicks still select points, and a 400 ms click-suppression window after a pan — but its tests never execute any of that behavior. The two tests the PR added (still the only coverage on current main) assert that the rendered HTML contains strings (function enhanceCharts(), data-zbound, setPointerCapture(drag.id), …) and that the emitted script parses. A regression that breaks the zoom math, the clamping, or the click suppression — while keeping those strings present — passes the suite unchanged.
Evidence
- PR: feat(aggregator): expand + zoom/pan controls on every /aa chart (#3298) #4154 feat(aggregator): expand + zoom/pan controls on every /aa chart (#3298) #4154 (MERGED, head
88920b4a06c600707672877366023b04805ca35e, mergefddd4ad68c21c1465fe7b86529dca6fa424f02f2, confirmed ancestor of main, compare behind=0) - Behavior under test, on main
ef16105eebb6d865960cde9f6bc1094b355000ee,pm-stack/aggregator/src/render.ts:clampChartView:4479,zoomChart:4484 (16× zoom floor, aspect-preserving resize, focal anchoring, zoom-out-to-base clearing state),panChart:4499,resetChart:4509, click suppression viadata-zsuppress:4587-4592. - Only coverage,
pm-stack/aggregator/test/aa.test.ts:867(describe("aa chart expand + zoom/pan (#3298)")): two tests, bothtoContainstring assertions overrenderAa(...)output plus anew Function(script)parse check. No DOM, no invocation ofzoomChart/panChart/clampChartView, no assertion on any resultingviewBox. - This is not a hypothetical style point: the PR's own history shows this layer needed three Codex-driven behavior fixes (deferred pointer capture, per-chart wrapper for band scatters, re-enhancement after recommendation-only redraws) — all behavior, all still guarded only by the presence of a string.
- Dedupe: all-state searches for
zoom/panandchart zoom testreturned only AA explorer: every chart gets an expand button + zoom/pan controls #3298 (the feature request, CLOSED by feat(aggregator): expand + zoom/pan controls on every /aa chart (#3298) #4154), feat(aggregator): expand + zoom/pan controls on every /aa chart (#3298) #4154 itself, and unrelated CI-failure issues — no test-coverage issue exists.
Why it matters
The /aa explorer is the AA comparison surface Drew reads; zoom/pan is now the primary way to inspect dense frontier charts. The zoom/pan state machine is exactly the kind of code that regresses silently (a redraw resetting applied, an aspect change on the scores chart, a clamp inversion when a view is taller than wide) — and the current tests would stay green through every one of those regressions, giving false confidence in the page's most interactive code.
Acceptance criteria
- Executable tests drive the enhancer's pure behavior: at minimum
zoomChartfocal anchoring and the 16× floor, zoom-out-to-base clearingcur,panChartclamping at the base viewBox edges, andresetChartrestoring the base viewBox — asserting the resultingviewBoxvalues, not string presence. - The click-suppression contract is pinned by a test: a click within the suppression window after a moved drag is swallowed; an ordinary click without a drag still reaches point selection.
- Tests run under the aggregator's existing
bun testsuite (a minimal DOM stub or extracting the pure viewBox helpers for direct import are both acceptable); the existing string-presence tests may stay but no longer count as the behavior coverage.
Filed by pr-diff-review-b (Lane B PR diff review, run 2026-11-13 09:18 CST) from review of PR #4154.
Activity
developing-today commentedon Nov 13, 2026
CODE-3178
dezren39 commentedon Nov 13, 2026
agent-note:v1
Agent: pr-diff-review-b
State: filed
Repo: developing-today/code
Source PR: #4154 (#4154, merged fddd4ad)
Finding: the /aa chart zoom/pan layer #4154 added (render.ts clampChartView :4479, zoomChart :4484, panChart :4499, click suppression :4587-4592 on main) has no executable tests — aa.test.ts:867's two tests only assert string presence in rendered HTML plus a script-parse check, so behavior regressions that keep the strings pass green.
Verified against main: ef16105 (contents reads of render.ts and aa.test.ts; PR merge confirmed ancestor, compare behind=0)
Evidence: hidden_files/pr-review-b-2026-11-13-0918/issue-chart-zoom-tests-body.md + diff-4154.patch
dezren39 commentedon Nov 13, 2026
agent-note:v1
Agent: repo-worker-code-a (lane code-a, task 16124)
State: picked up / triaged
Repo: developing-today/code
Issue: #9581
Task: task 16124 (triage packet)
Pickup: claimed task 16124, lane assignment direct (#8187) - this lane works it itself.
Revalidated fresh: issue #9581 OPEN, no hard-stop labels (held / user/owned / do-not-merge / do-not-auto-edit absent); PR #4154 MERGED fddd4ad; no open competing PR found.
Triage (inline, #8187):
Fix proceeding in this same claim.
Merge pull request #9582 from developing-today/queue/16124-9581-chart…
dezren39 commentedon Nov 13, 2026
agent-note:v1
Agent: repo-worker-code-a (lane code-a, task 16124)
State: done
Repo: developing-today/code
Issue: #9581
Task: task 16124 (triage packet, triaged inline and fixed in the same claim)
Outcome: fixed_merged. PR #9582 MERGED 100beb3; issue #9581 CLOSED by the PR.
What landed: the /aa chart zoom/pan viewBox math moved from the explorer inline script into the shared tested module src/assets/aa-explorer-computations.js (parseChartViewBox, effectiveChartView, clampChartView, zoomChartView, panChartView, resetChartView, chartClickSuppressed, with .d.ts declarations), following the #7562 pattern; render.ts enhancer handlers delegate to it with no inline copies and no behavior change. Executable tests in test/aa-explorer-computations.test.ts assert resulting viewBox values for focal anchoring, the 16x floor, zoom-out-to-base clearing state, pan clamping (incl. non-zero base origin and no-op cases), and reset, and pin the click-suppression contract (post-drag click within 400 ms swallowed; ordinary click with no stamp never swallowed). test/aa.test.ts pins that the shipped page imports these functions and carries no inline definitions.
Tests: bun test aa-explorer-computations 15/15 (also re-run 15/15 on merged main 100beb3); aa.test.ts 47/47 (with PM_AGG_FRESHNESS_PORT=4899 — default 4871 is held by the laptop production aggregator, pre-existing); render+a11y-1215+epic-graph 82/82; bunx tsc --noEmit error set identical to main (22 pre-existing, none in touched files).
Codex: review failed to run on PR #9582 (usage limits, fleet-wide since 2026-11-13T13:51Z) — no findings exist; disposition recorded on PR #9582 (comment 6857961702).
dezren39 commentedon Nov 13, 2026
agent-note:v1
Agent: repo-worker-code-a (lane code-a, task 16125)
State: done (already_done)
Repo: developing-today/code
Issue: #9581
Task: task 16125 (small_fix follow-on packet for the triage of task 16124)
This packet is the fix follow-on for the #9581 triage, but the fix already landed in the same claim as the triage (task 16124, this lane): PR #9582 MERGED 100beb3, issue #9581 CLOSED. Verified fresh at this claim: issue CLOSED, PR MERGED with that merge sha, and the extracted helpers (zoomChartView, panChartView, chartClickSuppressed) are present in src/assets/aa-explorer-computations.js on origin/main; the computations suite passed 15/15 on the merged main under task 16124. No duplicate work created.