Skip to content

fix(audit-engine): smart audits carry forward rule timeout rows from older runs #1075

Closed

Description

@nc9

A smart (incremental) audit that re-audits only a few pages carries forward findings for the pages it did not re-crawl. Those carried findings include rule timeout rows (check name ending in -error, message "exceeded its N ms time budget"), so the report tells the reader that rules timed out under a budget that may no longer exist, on pages this run never checked.

Observed on a cloud audit that stopped on time after crawling 2 of 10 pages (999 known pages, 2,565 carried findings): 7 carried rows from an older run said exceeded its 1000 ms time budget (a11y/aria-command-name, perf/cls-hints, perf/font-loading, perf/inp-hints, perf/lcp-hints, perf/preconnect, perf/render-blocking, one page each), but the engine's default budget has been 2000 ms since v0.0.127. Every row had provenance carried, status fail; there were 0 fresh timeouts. The HTML page shows "timed out" / "time budget" 19 times.

Expected: a timeout or rule-error result is a statement about one run's execution, not about the page. It must not be carried forward as a finding. Either skip -error/timeout rows in the carry path (they are then absent until the page is re-audited) or carry them as "not checked in this run" skips that count as not-checked rather than as failures with the old budget text.

Context: rule timeout semantics (rule-timed-out skip, <rule>|* rule-wide key, #997/#1007), merge-core / carry logic in packages/audit-engine (merge-core.ts).

Acceptance Criteria

  • A smart audit never carries a timeout or rule-error row from a prior run as a failing finding on a page it did not re-audit
  • The affected rule/page is reported as not checked in this run (or absent), never with an old "exceeded its N ms" message
  • A fresh timeout in the current run still reports normally
  • Test in packages/audit-engine covers: prior run has a timeout row for page P, current run does not recrawl P, the merged report has no timeout row for P
  • CHANGELOG entry; no REPORT_HTML_VERSION change unless output changes

Activity

  1. added
    bug
    rules
    size: S
    on Oct 23, 2026
  2. WilliamK112 commented on Oct 23, 2026

    @WilliamK112
    Contributor

    I’d like to take this. I’ll treat prior <rule>-error findings as run-local diagnostics: retire them before the carry path while preserving a fresh error from the current run, apply the same exclusion to the complete-store untouched aggregate path, add focused sampled and complete-store regressions, and update the changelog.

  3. nc9 commented on Oct 26, 2026

    @nc9
    ContributorAuthor

    Fixed in #1081 (main 9d427d6, shipped in v0.0.134). Evidence against the criteria: a prior <rule>-error row is retired on an untouched page, not carried (isRunLocalRuleErrorFinding in merge-core.ts, test 'an untouched page does not carry an older timeout row'); the merged report holds no such row, so no old 'exceeded its N ms' text appears; a fresh timeout in the current run still reports ('a fresh error in the current run still reports normally'); the materialized complete-store path and the oversized-sample path are covered too (rule-error-no-resolve-999.test.ts); the CHANGELOG entry is in v0.0.134, and no REPORT_HTML_VERSION change was needed.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugrulessize: S

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions