Repository navigation
feat(workers): prior-console-errors analyzer — correlate earlier console errors with a later failure - #81
Merged
Conversation
…ole errors with a later failure (#60) Non-excluded console errors that precede a failing assertion now emit a prior_console_errors finding (first error inlined with source location, count, and a pointer to show --console/--timeline). Job-wide no_console_errors exclude patterns are threaded into the evidence bundle so user-excluded errors never resurface; console_error failures skip the analyzer since the errors are already the headline. stale_session ranks first when both fire.
… third-party detection - prior_console_errors only fires for selector/text/url/timeout failures — a network_failure already names its own cause. - New shared isThirdPartySource(): ports ignored, loopback hosts are one local stack, sibling subdomains are first-party — an app's own API on another port (localhost:3000 page, localhost:3611 API) must never be labeled a third-party script. Also fixes the pre-existing origin-equality bug in no_console_errors' third_party flag. - All-third-party correlations get de-ranked language; mixed sources inline the first first-party error.
Closed
7 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #60. Second analyzer on the #58 pipeline — closes the second half of the field feedback behind #63:
prior_console_errorsfinding: count, first error inlined with source location, and a pointer toshow --console/--timeline.no_console_errorsexcludepatterns (global + every flow's) are threaded into the evidence bundle — user-excluded errors never resurface; invalid patterns are skipped safely.console_errorfailures skip the analyzer (the errors are already the headline); warnings never count.stale_sessionranks above it when both fire, so the more specific root cause wins the fix_hint.Tests: five new cases in
analyzers.test.ts(correlation + inlining, excludes honored, console_error skip, silent path, ranking). Verified e2e with a fixture page that logs the exact error from the field report plus a failing selector — the finding appears infailures[].findingsand the renderedfix_hint, stdout stays pure JSON. Full workers suite green.