Skip to content

fix(check): count possible impact on the first screen instead of listing it (UPT-97) - #215

Merged
lucasbraum merged 1 commit into
mainfrom
lucasbraum/upt-97-check-noise
Oct 17, 2026
Merged

lucasbraum merged 1 commit into
mainfrom
lucasbraum/upt-97-check-noise

Conversation

@lucasbraum

Copy link
Copy Markdown
Collaborator

Closes UPT-97 (default view part). The first screen of check lists breaking rules and only a count of possible impact; --details and --json are unchanged.

Measured (before this change)

One public ground-truth repo per pack, from the cache, one at a time, same stored --json report rendered before and after (formatCheck, no color, 120 columns).

vitest: votingworks/vxsuite@5cb3c7d (4.1.11 → 5.0.2) zod: vzdc-artcc/website@48a93f6 (3.25.76 → 4.6.5)
--json findings 31 breaking, 15,455 unverified, 80 additive, 3,228 info under 50% 7 breaking, 1,257 unverified, 14 deprecated, 251 additive
plan groups 4 breaking (31 sites), 11 possible impact (15,453 sites) 1 breaking (7 sites), 35 possible impact (781 sites), 4 deprecated (14 sites)
--details 31,053 lines 2,606 lines
default rows 1 package 1 package
default, before 18 lines = 51 terminal rows; 4 breaking lines, 4 possible-impact lines (header, 3 rules, "8 more") 21 lines = 29 terminal rows; 1 breaking line, 7 possible-impact lines (header, 6 rules, "29 more")
default, after 14 lines = 24 terminal rows; 4 breaking lines, 1 count line 14 lines = 15 terminal rows; 1 breaking line, 1 count line

Terminal rows = lines wrapped at 120 columns. --details output is byte-identical before and after on both repos.

The default view was already capped (8 rule lines per package), so the noise was not thousands of lines; it was (1) possible-impact rules sharing the screen with breaking ones, and on vxsuite (2) the coverage text printed twice, each about 1,500 characters, because every needs build of … chain is its own skipped reason.

What changed (CLI default view only)

  1. Possible impact is one count line: ? +781 possible impact in 48 files, not counted as breaking (--details lists them). The row verdict (✗ 7 breaking in 2 files, 781 possible) is unchanged.
  2. The heading does not repeat the coverage line: vitest 31 breaking · types partly verified, with the coverage line right under it. Only for partly-verified packages; the not-verified reason stays in the heading.
  3. Unbuilt workspace chains fold into one count on the coverage line: needs build of workspace packages (110), in place of seven reasons each naming up to 18 workspaces. Only when there is more than one such reason.

No change to findings, severities, the gate, ground truth, --json, --details, plan or HTML.

Snapshots

No stored snapshot changed: none of the snapshot fixtures has possible impact or partial coverage. Changed assertions, deliberately, in format-check.test.ts:

  • counts what nothing confirmed as possible impact… (renamed from lists…): the count line replaces the possible impact: N sites in M files header and the ? sharp.cache removed image.ts:4 rule line; asserts the unverified site's file is absent in the default view and present with --details.
  • prints how much of the code the compiler judged…: the heading is now zod 0 breaking · types partly verified without the repeated coverage; new case for folding two needs build of reasons into needs build of workspace packages (8).

Before / after, default check output (public repos)

vitest, before
vitest (2 packages)   4.1.11 → 5.0.2   major   verified   ✗ 31 breaking in 21 files, 15453 possible

vitest   31 breaking · types partly verified: compiled 168 of 1143 files in 52 workspaces with the repo's TypeScript 6.0.3; skipped: most files cannot resolve their imports at the installed version (864), needs build of libs/coverage-check, libs/basics, libs/cdf-schema-builder, libs/types, libs/fixtures (1), needs build of libs/coverage-check, libs/basics (3), outside the TypeScript project (1), needs build of libs/coverage-check, libs/basics, libs/cdf-schema-builder, libs/types (5), needs build of libs/coverage-check, libs/basics, libs/cdf-schema-builder, libs/types, libs/fixtures, libs/test-utils, libs/utils (7), needs build of libs/coverage-check, libs/basics, libs/cdf-schema-builder, libs/types, libs/fixtures, libs/test-utils, libs/utils, libs/logging, libs/db, libs/grout, libs/fs, libs/auth, libs/usb-drive, libs/backend (2), needs build of libs/coverage-check, libs/basics, libs/cdf-schema-builder, libs/types, libs/fixtures, libs/test-utils, libs/utils, libs/logging, libs/db, libs/grout, libs/fs, libs/auth, libs/usb-drive, libs/backend, libs/image-utils, libs/message-coder, libs/fujitsu-thermal-printer, libs/monorepo-utils (92)
  compiled 168 of 1143 files in 52 workspaces with the repo's TypeScript 6.0.3; skipped: most files cannot resolve their imports at the installed version (864), needs build of libs/coverage-check, libs/basics, libs/cdf-schema-builder, libs/types, libs/fixtures (1), needs build of libs/coverage-check, libs/basics (3), outside the TypeScript project (1), needs build of libs/coverage-check, libs/basics, libs/cdf-schema-builder, libs/types (5), needs build of libs/coverage-check, libs/basics, libs/cdf-schema-builder, libs/types, libs/fixtures, libs/test-utils, libs/utils (7), needs build of libs/coverage-check, libs/basics, libs/cdf-schema-builder, libs/types, libs/fixtures, libs/test-utils, libs/utils, libs/logging, libs/db, libs/grout, libs/fs, libs/auth, libs/usb-drive, libs/backend (2), needs build of libs/coverage-check, libs/basics, libs/cdf-schema-builder, libs/types, libs/fixtures, libs/test-utils, libs/utils, libs/logging, libs/db, libs/grout, libs/fs, libs/auth, libs/usb-drive, libs/backend, libs/image-utils, libs/message-coder, libs/fujitsu-thermal-printer, libs/monorepo-utils (92) · 5555 pre-existing type errors in these files (subtracted)
  ✗ coverage.include and coverage.exclude match the path relative to the project root, without picomatch contains; a bare directory such as src/config matches only what is inside it, so write src/config/** and check the reported file set   13 sites      manual
  ✗ import "@testing-library/jest-dom/vitest" registers matchers whose types no longer reach expect: register them with expect.extend and augment Matchers<R, T>                                                                                11 sites      manual
  ✗ custom matchers declared on the global jest.Matchers, or on a one-parameter Assertion<T> or Matchers<R>, no longer type: augment Matchers<R, T> of "vitest"                                                                                 5 sites       needs the agent (LLM) + manual
  ✗ bench is no longer exported from "vitest": it is a fixture of test(), run with await bench(name, fn).run()                                                                                                                                  2 sites       needs the agent (LLM)
  ? possible impact: 15453 sites in 772 files   the types changed where this code uses them; nothing confirmed that it breaks, so these are not counted as breaking
    ? ExpectStatic takes different arguments                                                                                                                                                                                                      14881 sites   needs the agent (LLM)
    ? VitestUtils#spyOn takes different arguments                                                                                                                                                                                                 196 sites     needs the agent (LLM)
    ? VitestUtils#useFakeTimers takes different arguments                                                                                                                                                                                         181 sites     needs the agent (LLM)
    … 8 more changes, 195 sites (--details)
  ↑ upgrades with @vitest/coverage-istanbul 4.1.11 → 5.0.2   @vitest/coverage-istanbul 5.0.2 is released with vitest 5.0.2 (pins 5.0.2)

Next
  npx uptide check vitest @vitest/coverage-istanbul --details    every site and reason
vitest, after
vitest (2 packages)   4.1.11 → 5.0.2   major   verified   ✗ 31 breaking in 21 files, 15453 possible

vitest   31 breaking · types partly verified
  compiled 168 of 1143 files in 52 workspaces with the repo's TypeScript 6.0.3; skipped: most files cannot resolve their imports at the installed version (864), outside the TypeScript project (1), needs build of workspace packages (110) · 5555 pre-existing type errors in these files (subtracted)
  ✗ coverage.include and coverage.exclude match the path relative to the project root, without picomatch contains; a bare directory such as src/config matches only what is inside it, so write src/config/** and check the reported file set   13 sites   manual
  ✗ import "@testing-library/jest-dom/vitest" registers matchers whose types no longer reach expect: register them with expect.extend and augment Matchers<R, T>                                                                                11 sites   manual
  ✗ custom matchers declared on the global jest.Matchers, or on a one-parameter Assertion<T> or Matchers<R>, no longer type: augment Matchers<R, T> of "vitest"                                                                                 5 sites    needs the agent (LLM) + manual
  ✗ bench is no longer exported from "vitest": it is a fixture of test(), run with await bench(name, fn).run()                                                                                                                                  2 sites    needs the agent (LLM)
  ? +15453 possible impact in 772 files, not counted as breaking   (--details lists them)
  ↑ upgrades with @vitest/coverage-istanbul 4.1.11 → 5.0.2   @vitest/coverage-istanbul 5.0.2 is released with vitest 5.0.2 (pins 5.0.2)

Next
  npx uptide check vitest @vitest/coverage-istanbul --details    every site and reason
zod, before
zod (2 packages)   3.25.76 → 4.6.5   major   verified   ✗ 7 breaking in 2 files, 781 possible

zod   7 breaking · types not verified: types not verified: run `prisma generate` (generated client missing)
  compiled 0 of 95 files in 1 workspace with the repo's TypeScript 5.9.3; skipped: types not verified: run `prisma generate` (generated client missing) (95) · 135 pre-existing type errors in these files (subtracted)
  ✗ names zod 3 exported from its root that only 'zod/v3' still exports: SafeParseReturnType, ZodTypeDef, ZodEffects   7 sites               needs the agent (LLM)
  ? possible impact: 781 sites in 48 files   the types changed where this code uses them; nothing confirmed that it breaks, so these are not counted as breaking
    ? ZodError#errors was an alias of issues and was removed: errors becomes issues                                      50 sites              auto-fixable
    ? ZodString takes different arguments                                                                                184 sites             needs the agent (LLM)
    ? ZodString#min takes different arguments                                                                            73 sites              needs the agent (LLM)
    ? Schema generics                                                                                                    47 fixes, 67 errors   needs the agent (LLM)
    ? ZodOptional takes different arguments                                                                              63 sites              needs the agent (LLM)
    ? ZodObject takes different arguments                                                                                57 sites              needs the agent (LLM)
    … 29 more changes, 287 sites (--details)
  ! 14 deprecated calls (.message, nativeEnum, .email, ...)   2 auto-fixable
  ↑ moves eslint 9.26.0 → 9.27.0   moved because eslint 9.26.0 depends on zod ^3.24.2, which rejects zod 4.6.5

⚠ 14 importing files not analyzed (memory cap); findings in them may be missed (--details lists them)

Next
  npx uptide check zod eslint --details    every site and reason
zod, after
zod (2 packages)   3.25.76 → 4.6.5   major   verified   ✗ 7 breaking in 2 files, 781 possible

zod   7 breaking · types not verified: types not verified: run `prisma generate` (generated client missing)
  compiled 0 of 95 files in 1 workspace with the repo's TypeScript 5.9.3; skipped: types not verified: run `prisma generate` (generated client missing) (95) · 135 pre-existing type errors in these files (subtracted)
  ✗ names zod 3 exported from its root that only 'zod/v3' still exports: SafeParseReturnType, ZodTypeDef, ZodEffects   7 sites   needs the agent (LLM)
  ? +781 possible impact in 48 files, not counted as breaking   (--details lists them)
  ! 14 deprecated calls (.message, nativeEnum, .email, ...)   2 auto-fixable
  ↑ moves eslint 9.26.0 → 9.27.0   moved because eslint 9.26.0 depends on zod ^3.24.2, which rejects zod 4.6.5

⚠ 14 importing files not analyzed (memory cap); findings in them may be missed (--details lists them)

Next
  npx uptide check zod eslint --details    every site and reason

Not in this PR

  • Cut at the source (item 3 of the issue): one shape is 96% of the vitest noise, ExpectStatic takes different arguments, 14,881 of 15,453 possible-impact sites on vxsuite. Tightening it changes --json and the pack FP counts, which this PR keeps fixed; proposed as a follow-up.
  • zod on vzdc says types not verified: types not verified: run \prisma generate`(the reason already carries the prefix). Left as is: it is core wording, and it also appears in--json`.

🤖 Generated with Claude Code

…ing it (UPT-97)

The default view listed possible-impact rules (types changed, nothing
confirmed a break) next to the breaking ones; on votingworks/vxsuite that
is 15,453 sites, on vzdc-artcc/website 781. It is now one count line per
package, and --details and --json still have every site.

A partly verified package no longer repeats its coverage line in the
heading, and a monorepo's unbuilt workspace chains fold into one count
on that line (seven reasons naming up to 18 workspaces each on vxsuite).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Lucas Braum <[email protected]>
@lucasbraum
lucasbraum merged commit abddcb3 into main Oct 17, 2026
12 checks passed
@lucasbraum
lucasbraum deleted the lucasbraum/upt-97-check-noise branch October 17, 2026 22:35
@uptide-release uptide-release Bot mentioned this pull request Oct 17, 2026
lucasbraum pushed a commit that referenced this pull request Oct 18, 2026
This PR was opened by the [Changesets
release](https://github.com/changesets/action) GitHub action. When
you're ready to do a release, you can merge this and publish to npm
yourself or [setup this action to publish
automatically](https://github.com/changesets/action#with-publishing). If
you're not ready to do a release yet, that's fine, whenever you add more
changesets to main, this PR will be updated.


# Releases
## [email protected]

### Patch Changes

- [#220](#220)
[`cf86d65`](cf86d65)
Thanks [@lucasbraum](https://github.com/lucasbraum)! - With an assisting
agent, a root pin Uptide cannot update safely (a nested override such as
`overrides > pkg > peerDependencies > react`) no longer stops `fix` with
exit 2: the run continues as an agent-led draft that leaves the pin as
written and names it, with its exact path and value, at the top of the
PR body. The agent-led peer reason now names each blocker's first
release that accepts the target, or says none does. An agent-led draft
must pass the repository's clean install (`npm ci` or the manager's
frozen install) before delivery; if it does not, the PR says so at the
top. Without an agent, with `--no-llm`, or on a safety refusal, `fix`
still exits 2.

- [#232](#232)
[`e4a2885`](e4a2885)
Thanks [@lucasbraum](https://github.com/lucasbraum)! - `uptide fix`
spends less wall time on test runs and dependency copies:
  
- The agent's own `run_tests` check runs only its runner's related tests
when the `test` script builds first and then runs a script that is just
the runner (`pnpm run build && pnpm run test:unit`). The gate after the
agent's edits and the final verification run exactly what they ran
before.
- The upgrade's install moves the installed `node_modules` out of its
temporary worktree instead of copying it.
- Each phase of the fix report lists the repository's commands it ran
(installs, generators, builds, type-checks, tests, lint, format) with
their count and summed wall time. An agent-led run's clean install has
its own phase.

- [#223](#223)
[`2dc2162`](2dc2162)
Thanks [@lucasbraum](https://github.com/lucasbraum)! - `fix` no longer
stops with "baseline tests modified the working tree" when the test run
only writes new untracked files, such as a junit `test-report.xml` that
is not gitignored. Those files are recorded as test artifacts
(`testArtifacts` in the report), kept out of every commit, the agent's
diff and the pending-changes check, and removed before each later test
run, `uptide verify` included. A change to a tracked file during
baseline tests still refuses the run.

- [#215](#215)
[`abddcb3`](abddcb3)
Thanks [@lucasbraum](https://github.com/lucasbraum)! - `check` no longer
lists possible impact (type changes nothing confirmed as breaking) on
its first screen: each package says it in one line, `+N possible impact
in M files, not counted as breaking`, and `--details` and `--json` still
have every site. A package whose types were partly verified no longer
repeats its coverage line in the heading, and a monorepo's unbuilt
workspace chains are one count on that line.

- [#213](#213)
[`2de3a18`](2de3a18)
Thanks [@lucasbraum](https://github.com/lucasbraum)! - A companion pack
that moves with the lead's fix (react beside next) now gets its own scan
context and inventory, and the PR body carries a section with its review
notes.

- [#212](#212)
[`733cfbe`](733cfbe)
Thanks [@lucasbraum](https://github.com/lucasbraum)! - `pack test
--write` records how many breaking sites a finding landed on at any
severity and as breaking, out of all breaking sites it scored, and the
pack tables show both ("Found, any severity", "Found as breaking") in
place of the single recall column. Packs recorded before it show `—`.

- [#224](#224)
[`09f68df`](09f68df)
Thanks [@lucasbraum](https://github.com/lucasbraum)! - `fix` on npm no
longer stops when the lock-only install hits ERESOLVE from the old
lockfile. It retries without the lockfile entries of the moved packages,
their companions and the packages whose peers they satisfy, and only
then with the whole lockfile re-resolved; the report says which step
worked, and the lockfile check reports the churn as usual. It never uses
`--legacy-peer-deps` or `--force`. When every step fails, `fix` ends
blocked, naming the conflicting packages from npm's ERESOLVE report.
`fix --json` now prints JSON on every exit, a failure included; when the
run already has its report (a PR body over GitHub's size limit), that
report comes with the error.

- [#221](#221)
[`ff8de8e`](ff8de8e)
Thanks [@lucasbraum](https://github.com/lucasbraum)! - `fix` no longer
rejects an agent patch for test files the parent commit already failed,
whichever test scope ran them: when the test script builds first and the
build failed on the error being fixed, the start had no test results to
compare with, so a correct patch was reverted every round. The patch's
tests also run with the pack's follow-ups in place (a test asserting the
old Stripe API version), which `fix` still applies and reports after the
agent. When a PR body cannot fit, the stored report.json the error
points to is now written first. `check` and `fix` now also analyze files
that reach a package's wrapper through a barrel (`import {
getStripeClient } from '../stripe'` with `export * from './client'`).
Edited files are formatted with oxfmt and dprint as well as biome and
prettier, from the workspace that holds them, with its own
configuration, else the root's. The stripe pack adds `request-options`:
request options passed in the params slot (`subscriptions.cancel(id, {
idempotencyKey })`), which SDK 22 rejects, move to the third argument.
It runs assisted until a ground-truth repository exercises it.

- [#226](#226)
[`448c3cb`](448c3cb)
Thanks [@lucasbraum](https://github.com/lucasbraum)! - `uptide fix`
judges consumed workspace builds on the final head, not on the tree
right after the bump. A build that failed after the bump and passes once
the edits land no longer starts a feedback round, adds an "Agent-led
draft" reason or shows "Build failed" in the PR body. The builds run
again only when the tree changed since their last result, and not at all
when the verification build already built those workspaces. The fix
report's `buildRuns` gives the number of builds the run executed and
their wall time.

- [#218](#218)
[`13e343b`](13e343b)
Thanks [@lucasbraum](https://github.com/lucasbraum)! - `check` folds a
compile error into the breaking site it comes from when the compiler
traces its value there (an `errors.map(e => e.message)` under a
`result.error.errors` that zod 4 no longer types, and the narrowing that
depended on it). The rule's line shows `+N downstream errors`,
`--details` lists them under their site, and `--json` carries them as
that finding's `downstream`. They are no longer separate breaking sites.
`fix` still verifies against every error.

- [#214](#214)
[`195ae10`](195ae10)
Thanks [@lucasbraum](https://github.com/lucasbraum)! - A rewrite rule
below 80% precision over at least 5 scored ground-truth sites now runs
as assisted in `fix` (react-router `dom-imports`); smaller samples (next
`middleware-proxy`) stay mechanical and are flagged in the compatibility
table. Pack status is unchanged.

- [#218](#218)
[`13e343b`](13e343b)
Thanks [@lucasbraum](https://github.com/lucasbraum)! - pack test runs a
ground-truth repository's code generators (prisma generate, local
graphql-codegen) after its install, as fix does. It fetches the Prisma
engines the locked version needs itself, so generators stay off the
network. A repository whose generator still fails is incomplete and
fails the pack, unless its ground truth declares `withoutGenerated`

- [#227](#227)
[`ae175a9`](ae175a9)
Thanks [@lucasbraum](https://github.com/lucasbraum)! - A migration whose
evidence is larger than GitHub's PR description limit no longer stops
`fix` with "Required migration evidence exceeds the PR body budget" and
loses the run. Long required lists get a compact form when they do not
fit. Lockfile churn shows counts per kind of change and the first
packages. Manual sites are grouped by rule, with counts and the first
locations. Remaining type errors show the first entries. Every full list
stays in report.json and, in the Uptide Action, in the job summary,
which the description links to. If even the compact form does not fit,
the description is a short summary that says so at the top: the verdict,
the checks, the counts and where the full report is. The branch and
report.json are always kept.
  
An agent's decisions under "Decisions for you" name the files the agent
changed, five at most, and count the rest, instead of every file in the
task's scope. A verification-feedback task scoped to the whole
repository made each of its decisions a list of hundreds of files.

- [#219](#219)
[`12dc612`](12dc612)
Thanks [@lucasbraum](https://github.com/lucasbraum)! - `fix zod`
rewrites `z.string().uuid()` to `z.guid()` by rule without
`--include-deprecated`: zod 4's `uuid()` also checks the RFC version and
variant, so ids zod 3 accepted stop validating, and `check` now counts
the site as breaking. `fix` no longer reports false pre-existing type
errors on a TypeScript 7 repository whose `lib` names a library newer
than its `target` (`lib: ["ES2023"]` under `ES2022`).

Co-authored-by: uptide-release[bot] <338861287+uptide-release[bot]@users.noreply.github.com>
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