[PR #6413] [MERGED] fix(network): count omitted response content promptly #7342

Closed
opened 2026-11-01 21:47:11 +00:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/morluto/rea/pull/6413
Author: @eco-null
Created: 10/22/2026
Status: ✅ Merged
Merged: 10/23/2026
Merged by: @morluto

Base: main ← Head: codex/network-omitted-response-count


📝 Commits (2)

  • ce58d09 fix(network): count omitted response content promptly
  • 6c8115c test(network): pin response omission timing

📊 Changes

2 files changed (+34 additions, -8 deletions)

View changed files

📝 src/browser/network/PlaywrightScenarioNetwork.test.ts (+27 -0)
📝 src/browser/network/PlaywrightScenarioNetwork.ts (+7 -8)

📄 Description

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 ce58d09d0: 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.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/morluto/rea/pull/6413 **Author:** [@eco-null](https://github.com/eco-null) **Created:** 10/22/2026 **Status:** ✅ Merged **Merged:** 10/23/2026 **Merged by:** [@morluto](https://github.com/morluto) **Base:** `main` ← **Head:** `codex/network-omitted-response-count` --- ### 📝 Commits (2) - [`ce58d09`](https://github.com/morluto/rea/commit/ce58d09d08d3143532814caac5634638c55dc0f8) fix(network): count omitted response content promptly - [`6c8115c`](https://github.com/morluto/rea/commit/6c8115cf0f1edc1b28f41336d86b75452760e58a) test(network): pin response omission timing ### 📊 Changes **2 files changed** (+34 additions, -8 deletions) <details> <summary>View changed files</summary> 📝 `src/browser/network/PlaywrightScenarioNetwork.test.ts` (+27 -0) 📝 `src/browser/network/PlaywrightScenarioNetwork.ts` (+7 -8) </details> ### 📄 Description <!-- PR title: type(optional-scope): imperative outcome The title becomes the squash-merge commit subject and generated changelog entry. --> ## Summary Count selected response content omitted by a full capture inventory. Fixes #3957. Split from #4040. <!-- What user, agent, or maintainer problem does this solve? Link the issue with "Fixes #123" when applicable. Keep the prior behavior, expected contract, and new behavior understandable without private context. --> ## 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. <!-- For fixes, give the smallest trigger and violated invariant. For features, describe the use case and observable outcome. --> ## Change and scope One independent fix on current main; no dependency on #4040. No new target execution or authority. <!-- Explain the chosen approach, why it fits REA's architecture, and what is intentionally not included. --> Follow the [contribution scope](https://github.com/morluto/rea/blob/main/CONTRIBUTING.md#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 <!-- Short answers are welcome. Complete applicable lines; mark unresolved facts as "unknown". Use "none" or "not applicable" only when established. --> - 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. - [x] 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 <!-- State whether evidence is executed, source-derived, or proposed. For fixes, show the original failure and explain how the regression would fail on the affected base revision when practical. Include the most useful proof inline; link long logs or artifacts, or put them in optional details. Documentation-only changes can use source, link, or rendered-document checks. --> - 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: - [x] Observed, derived, and inferred claims remain distinguishable. - [x] Artifact identity, source provenance, and failed attempts remain preserved. - [x] Unsupported, incomplete, unavailable, or uncertain outcomes remain visible. ## Validation performed <!-- List only commands that actually ran, with observed results. Include the relevant real-provider or platform workflow, or explain why it was unavailable. Keep these results current after changes; a command without its result is incomplete. --> - 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 ce58d09d0: 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 <!-- Call out breaking changes, migrations, package effects, platform/provider limits, security/privacy/containment implications, and meaningful proof gaps. --> - Breaking changes or migration steps: No schema migration; previously misclassified observations are corrected. <!-- For ! / BREAKING CHANGE: show a previously valid call/configuration, its new behavior and migration, and why compatibility/deprecation cannot preserve it. Every release increments minor, including breaking changes; keep breaking markers and migration notes so callers can assess compatibility. See docs/releasing.md. --> - 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 <!-- The human owner completes these declarations before requesting review. The PR author is the owner by default. A different owner must explicitly accept ownership on this PR. AI agents must leave these declarations to a human to dictate to them or there could be catastrophic consequences for many users of REA. Draft PRs may leave them unchecked. These declarations record initial readiness when opening the PR for review; later pushes do not require a new human sign-off. Keep the description and validation evidence current as the work changes. See CONTRIBUTING.md#pull-request-ownership-and-readiness. --> Human owner: @eco-null - [x] 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. - [x] I checked the evidence above, confirmed it supports the current change, and recorded meaningful validation gaps. - [x] I declare this PR ready for initial maintainer review. ## Before merge <!-- Draft PRs may leave pending items unchecked. Resolve material scope and authority questions before integration. --> - [x] This PR addresses a concrete problem or an agreed enhancement. - [x] Material scope and authority questions are resolved, and any required maintainer scope decision covers the final diff. - [x] The PR has one focused outcome and the title follows `type(scope): outcome`. - [x] Related issue is linked, or the reason for not linking one is stated above. - [x] Tests cover changed observable behavior and meaningful failure paths. - [x] Owning docs, contracts, and generated metadata are updated where needed. - [x] User-visible CLI/MCP changes include representative output. - [x] I checked the final diff for secrets, unrelated cleanup, and unsupported claims. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-01 21:47:11 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
morluto/rea#7342
No description provided.