Skip to content

fix: resolve all four audit hardening residuals (#567-#570)#572

Merged
HomenShum merged 4 commits into
mainfrom
fix/audit-residuals-deep
Jul 17, 2026
Merged

fix: resolve all four audit hardening residuals (#567-#570)#572
HomenShum merged 4 commits into
mainfrom
fix/audit-residuals-deep

Conversation

@HomenShum

Copy link
Copy Markdown
Owner

Summary

Resolves every open residual from the 2026-07-16 production audit cycle in one branch, four commits:

  1. ScratchnodeEventsSurface.test.tsx is red on main and CI can't see it #567 — red tests CI could not see: the ScratchnodeEventsSurface api mock predated ImportRecapButton's domains.product.scratchnodeImport query (TypeError on clean main) and the runtime-smoke allowlist never ran the file. Proxy-based api mock degrades unknown refs to unresolved queries, useMutation mock added, two new gate scenarios, file added to the CI allowlist.
  2. Cancel arming is a 400ms timer, not a spatially distinct control #568 — timer-only cancel guard: Stop and submit are now both always rendered — Stop in a reserved hidden slot, submit staying at identical coordinates while streaming (disabled). The double-click's second click lands on an inert control at any user double-click interval; the 400ms arming remains as defense in depth.
  3. detectRequestedResponseShape covers only title-only and bullets #569 — shape detector gap: "in one sentence", "a single paragraph", "under N words" are detected, instructed via an exhaustive responseShapeSystemInstructions switch, and deterministically enforced with honesty preserved (Source needed: within the requested shape). JSON/table deliberately stay model-side.
  4. No 390px computed-geometry regression test for the chat workspace #570 — no computed-geometry regression capture: one-flow-regression (Tier B, per-PR) gains a 390x844 test asserting .rd-shell__main resolves to one grid track and main#main-content >300px.

Verification

Closes #567, closes #568, closes #569, closes #570

🤖 Generated with Claude Code

HShuM and others added 4 commits July 17, 2026 12:34
Three ScratchnodeEventsSurface tests failed on clean main with a TypeError
because the api mock predated ImportRecapButton's
domains.product.scratchnodeImport query, and CI never saw the red because
the runtime-smoke job runs an explicit allowlist that omitted the file.

The api mock is now a Proxy that degrades unknown function references to
unresolved queries (the surface's honest gates render nothing) instead of
crashing at property access, the convex/react mock gains the useMutation
the component already imports, two scenarios cover the import affordance's
published/unresolved gates, and the file joins the runtime-smoke allowlist
so future drift turns CI red.

Closes #567

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The submit->Stop same-slot swap meant a double-click slower than the
400ms arming window (Windows accessibility settings allow ~900ms) could
still cancel the run it just created. Stop and submit are now both always
rendered: Stop holds a reserved slot (visibility:hidden while idle) and
submit stays at identical coordinates while streaming, merely disabled —
so the second click of a double-click lands on an inert control at every
interval. The arming delay remains as defense in depth.

Closes #568

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
detectRequestedResponseShape recognized only title-only and bullets, so
"in one sentence", "a single paragraph", and "under 50 words" silently
rendered the five-section memo despite the user's explicit constraint.

Three new shapes are detected, instructed (via an exhaustive
responseShapeSystemInstructions switch replacing the ternary chain), and
deterministically enforced in applyDeterministicResponsePolicy: first
sentence extraction, prose collapse, and sentence-accumulating word
budgets. Honesty survives compaction — unsupported runs carry a
"Source needed" prefix or inline limitation instead of busting the
user's limit. JSON/table shapes stay model-side deliberately: the memo
render path is markdown prose, and a deterministic policy cannot
reconstruct valid structured output from parsed memo fields.

Closes #569

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The audit's mobile collapse (grid 70px 320px, chat clipped to a 70px
strip) was invisible to both the CSS-source string guard and the
document-overflow boolean. one-flow-regression (Tier B, per-PR) now
asserts the computed grid-template-columns of .rd-shell__main resolves
to one track and main#main-content stays >300px at 390x844. Reversion-
proved by reinjecting a higher-specificity two-column rule: computed
geometry returns exactly the audited 70px/320px shape, which the new
assertions reject.

Also seals the audit-residual work in the redesign-chat changelog lane
and backfills the #565/#571 entries' pending merge markers.

Closes #570

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@HomenShum
HomenShum enabled auto-merge (squash) July 17, 2026 19:44
@vercel

vercel Bot commented Jul 17, 2026

Copy link
Copy Markdown

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

Project Deployment Actions Updated (UTC)
nodebench-ai Ready Ready Preview, Comment Jul 17, 2026 7:45pm

Request Review

@github-actions

Copy link
Copy Markdown

PR size advisory

This PR adds 512 lines of substantive change. CONTRIBUTING.md defines a soft limit of ~400 LOC.

If the PR is genuinely cohesive (e.g. an architecture map, a generated migration, a deletion of a dead module), no action is needed. Otherwise consider:

  • splitting into 2-3 PRs along independent concerns
  • pre-discussing the architecture change in a GitHub Discussion before merge

This is advisory — it does not block the merge.

@github-actions

Copy link
Copy Markdown

✅ Dogfood Visual QA Gate: PASSED

Check Status
Screenshots 7 captured (pass)
Walkthrough 9 chapters (pass)
Key Frames 9 extracted (pass)
Scribe Steps 8 how-to steps (pass)
Build success
Artifacts

Download the dogfood-evidence-39903a3 artifact from the Actions tab for full screenshots, frames, and walkthrough video.


Generated by Dogfood QA Gate

@HomenShum
HomenShum merged commit bc0ab1c into main Jul 17, 2026
17 checks passed
@HomenShum
HomenShum deleted the fix/audit-residuals-deep branch July 17, 2026 19:50
@github-actions

Copy link
Copy Markdown

Demo: walkthrough of the surfaces this PR changed is available as a workflow artifact (pr-demo-572) at https://github.com/HomenShum/NodeBenchAI/actions/runs/29609040624

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

Labels

None yet

Projects

None yet

2 participants