Skip to content

fix(network): count omitted response content promptly - #6413

Merged
morluto merged 2 commits into
morluto:mainfrom
eco-null:codex/network-omitted-response-count
Oct 23, 2026
Merged

morluto merged 2 commits into
morluto:mainfrom
eco-null:codex/network-omitted-response-count

Conversation

@eco-null

@eco-null eco-null commented Oct 22, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Count selected response content omitted by a full capture inventory. Fixes #3957. Split from #4040.

Problem and expected behavior

When the transaction limit was full, selected response headers/body omissions were recorded only if a later finished event arrived. Account once at the response boundary, including failed and unfinished requests.

Change and scope

One independent fix on current main; no dependency on #4040. No new target execution or authority.

Follow the contribution scope.
Unresolved scope, authority, side effects, or required verification block
integration. Link the required maintainer scope decision for new providers or
capabilities involving target execution, injection, mutation, or protection
recovery; ordinary fixes within existing boundaries may state "not applicable".
Draft PRs may leave the scope decision pending and the readiness and merge checklists
unchecked. Maintainers can help resolve open questions.

Contract and boundary impact

  • Semantic owner and earliest changed stage: PlaywrightScenarioNetwork response admission.
  • Contribution scope fit and linked maintainer decision: Ordinary fix within existing boundaries; new maintainer scope decision not applicable.
  • CLI and MCP/tool-catalog contract: Existing interfaces and schemas retained; observable correction described above.
  • Provider, bridge, target-format, or platform compatibility: Response finished/failed/unfinished cases; duplicate response notification and no body reads.
  • Evidence, artifact, provenance, or reconstruction contract: Incomplete or rejected observations remain explicit; source evidence is retained.
  • Target selection, authority, upstream behavior, and cleanup details (if applicable): Existing selection and authority unchanged.
  • Generated metadata (docs/public/product-catalog.json), package, or installation impact (CI generates and validates ignored catalogs and skills/; edit authored instructions in .agents/skills/reverse-engineer-anything/ and never commit build outputs): No build outputs committed; catalogs regenerated by normal checks.

Expected effects (check known effects; use documentation-only on its own).
Unchecked items do not establish absence; leave uncertainties visible.

  • Read existing files or captured data.
  • Launch or attach to a process.
  • Inject instrumentation or run scripts/code.
  • Change process memory, registers, files, or configuration.
  • Contact network services.
  • Recover protected code or work around protections.
  • Documentation or usability only; no target interaction.
  • Not sure yet; investigation or maintainer guidance needed.

Evidence and regression coverage

  • Tests added or updated: Response finished/failed/unfinished cases; duplicate response notification and no body reads.
  • Base reproduction or other evidence: New targeted regressions were executed against unchanged main before the production fix; see validation.
  • User-visible CLI/MCP output (if applicable): Existing structured output now preserves the omitted/unknown state described above; no adapter change.
  • Remaining proof gaps: Synthetic Playwright request/response boundary tests; no real browser or full suite run.

For evidence-bearing changes:

  • Observed, derived, and inferred claims remain distinguishable.
  • Artifact identity, source provenance, and failed attempts remain preserved.
  • Unsupported, incomplete, unavailable, or uncertain outcomes remain visible.

Validation performed

  • Latest test-only change: npm run test:focused -- src/browser/network/PlaywrightScenarioNetwork.test.ts - 28/28 passed (1.04 s). Assertions pin first response, duplicate response, terminal notification and final finish count. Normal commit/pre-push typecheck and lint passed.
  • Timing mutant: deferring omission accounting with queueMicrotask still passed all 28 old tests; strengthened tests rejected it with 3 failed / 25 passed. Production restored byte-for-byte; only 3 test assertions changed.
  • Parent ce58d09: initial unchanged-main reproduction 2 failed / 26 passed, production fix 28 passed, full check/pre-push passed. Historical parent proof; no fresh full check or real browser/full suite/cross-platform proof for this test-only head. Windows, pinned Node 24.18.0/npm 11.16.0; no hosted CI claim.

Compatibility, safety, and release

  • Breaking changes or migration steps: No schema migration; previously misclassified observations are corrected.
  • Real Hopper/Ghidra, browser, or OS coverage: Synthetic Playwright request/response boundary tests; no real browser or full suite run.
  • Package or release metadata impact: No dependency or release version change.
  • Security, privacy, process, or containment review: No expanded target authority; no bypass of workflow approval.

Author readiness

Human owner: @eco-null

  • I reviewed the final diff and relevant existing code, understand the change and its edge cases, and take responsibility for the complete PR, including AI-assisted work.
  • I checked the evidence above, confirmed it supports the current change, and recorded meaningful validation gaps.
  • I declare this PR ready for initial maintainer review.

Before merge

  • This PR addresses a concrete problem or an agreed enhancement.
  • Material scope and authority questions are resolved, and any required maintainer scope decision covers the final diff.
  • The PR has one focused outcome and the title follows type(scope): outcome.
  • Related issue is linked, or the reason for not linking one is stated above.
  • Tests cover changed observable behavior and meaningful failure paths.
  • Owning docs, contracts, and generated metadata are updated where needed.
  • User-visible CLI/MCP changes include representative output.
  • I checked the final diff for secrets, unrelated cleanup, and unsupported claims.

@eco-null
eco-null marked this pull request as ready for review October 22, 2026 22:42
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 22, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ⚠️ Failed 2026-10-22T22:43:24.781290Z
We couldn’t complete this review. Comment @codex review to try again.
ce58d09 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@greptile-apps

greptile-apps Bot commented Oct 22, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] The PR appears safe to merge; the previous test coverage gap is fixed.

Summary

Counts selected response content omissions when the response arrives, rather than waiting for the request to finish.

  • Selected response content is counted when an omitted response arrives.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart LR
  A[Response arrives] --> B{Transaction admitted?}
  B -->|No| C[Count omitted response metadata]
  C --> D{Response content selected?}
  D -->|Yes| E[Count omitted content once]
  D -->|No| F[Return without reading body]
  E --> F
  B -->|Yes| G[Keep normal response capture]
Loading

Reviews (2) · Last reviewed commit: "test(network): pin response omission tim..." · Reviewed by Greptile

@morluto
morluto merged commit c8d58d2 into morluto:main Oct 23, 2026
43 checks passed
@morluto morluto added bug Something isn't working area: runtime Process capture and runtime observation labels Nov 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: runtime Process capture and runtime observation bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] Omitted failed or unfinished responses undercount selected response-content events

2 participants