[PR #7302] [MERGED] fix(wasm): name the compare_wasm_interfaces side of rejected Evidence #7810

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

📋 Pull Request Information

Original PR: https://github.com/morluto/rea/pull/7302
Author: @Adolanium
Created: 10/26/2026
Status: ✅ Merged
Merged: 11/4/2026
Merged by: @morluto

Base: main ← Head: fix/wasm-comparison-issue-side


📝 Commits (5)

  • 8a30065 fix(wasm): name the compare_wasm_interfaces side of rejected Evidence
  • 4c62771 Merge remote-tracking branch 'upstream/main' into fix/wasm-comparison-issue-side
  • 2b5229d test(wasm): cover both comparison sides through the MCP boundary
  • 1e441bb Merge remote-tracking branch 'upstream/main' into fix/wasm-comparison-issue-side
  • 5b0f78c Merge remote-tracking branch 'upstream/main' into fix/wasm-comparison-issue-side

📊 Changes

3 files changed (+96 additions, -5 deletions)

View changed files

📝 src/application/wasm/WasmInterfaceComparisonService.test.ts (+34 -0)
📝 src/application/wasm/WasmInterfaceComparisonService.ts (+11 -5)
📝 tests/process-global/derivedOperationFailures.test.ts (+51 -0)

📄 Description

Summary

Fixes #7303.

compare_wasm_interfaces rejects tampered or rebound inspect_wasm_artifact Evidence with an AnalysisInputError whose issue path is [], so the caller cannot tell whether left or right was rejected. The issue now names the argument: path: ["left"] or path: ["right"].

Problem and expected behavior

parseInspection reports every rejected side through inspectionInputFailure, which builds one issue at path: []. The side being parsed is known at the call site but is not passed down.

Expected: the issue path names the input argument whose Evidence was rejected.

Change and scope

  • src/application/wasm/WasmInterfaceComparisonService.ts: parseInspection(raw, side) passes the side to inspectionInputFailure, which reports the issue at path: [side] with the same reason and message. The two call sites pass "left" and "right".

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.

Contribution scope: not applicable. This is a fix inside the existing Wasm interface comparison.

Contract and boundary impact

  • Semantic owner and earliest changed stage: compareWasmInterfaces, where each side's Evidence is admitted.
  • Contribution scope fit and linked maintainer decision: not applicable.
  • CLI and MCP/tool-catalog contract: the rejected-Evidence issue path is ["left"] or ["right"] instead of []; reason and message are unchanged.
  • Provider, bridge, target-format, or platform compatibility: none.
  • Evidence, artifact, provenance, or reconstruction contract: none.
  • Target selection, authority, upstream behavior, and cleanup details (if applicable): none.
  • 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): none.

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:
    • src/application/wasm/WasmInterfaceComparisonService.test.ts, "names the %s argument whose Evidence is rejected", for left and right: both tampered Evidence and authentic Evidence (built with createEvidence) whose selection names another artifact report path: [side].
    • tests/process-global/derivedOperationFailures.test.ts, "names the %s argument whose authentic Evidence selects another artifact", for left and right: MCP compare_wasm_interfaces returns invalid_request with the issue at [side], and no Evidence is retained.
  • Base reproduction or other evidence: with WasmInterfaceComparisonService.ts from upstream/main a989c0e45, all four new tests fail (the issue path is []); the other 88 tests in both files pass.
  • User-visible CLI/MCP output (if applicable): the issue path in the input error.
  • Remaining proof gaps: the CLI path shares the same service and was not run separately.

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

On Linux (WSL Ubuntu, Node 24.22.1) at 5b0f78c1f (upstream/main a989c0e45 merged), after npm ci and npm run mcp-catalog:generate:

  • npx tsc -p . --noEmit passed.
  • npx oxfmt --check on the changed files: clean. node scripts/ci/static-check-report.mjs lint: 0 errors.
  • npx vitest run src/application/wasm/WasmInterfaceComparisonService.test.ts tests/process-global/derivedOperationFailures.test.ts: 92 passed, in two runs.
  • The negative check above failed only the four new tests.
  • CI failures outside this change reproduce on upstream/main a2e2c29b5 without it, run locally on Linux after npm ci and npm run build:cached: kimiClientConfiguration.test.ts (5 failed), WindowsNativeLoader.test.ts (8), appleApplication.test.ts (8), providerBinding.test.ts (1), processCleanupRetryOwnership.test.ts (2). In CI on this branch, WasmInterfaceComparisonService.test.ts passed all 13 tests.

Compatibility, safety, and release

  • Breaking changes or migration steps: none; only the issue path changes.
  • Real Hopper/Ghidra, browser, or OS coverage: Linux only.
  • Package or release metadata impact: none.
  • Security, privacy, process, or containment review: none.

Author readiness

Human owner: @Adolanium

  • 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/7302 **Author:** [@Adolanium](https://github.com/Adolanium) **Created:** 10/26/2026 **Status:** ✅ Merged **Merged:** 11/4/2026 **Merged by:** [@morluto](https://github.com/morluto) **Base:** `main` ← **Head:** `fix/wasm-comparison-issue-side` --- ### 📝 Commits (5) - [`8a30065`](https://github.com/morluto/rea/commit/8a300655e6d6c0c39c77f9946a7e078af99efc5e) fix(wasm): name the compare_wasm_interfaces side of rejected Evidence - [`4c62771`](https://github.com/morluto/rea/commit/4c6277156623f40f007e80a48c87c82e3c0ec67e) Merge remote-tracking branch 'upstream/main' into fix/wasm-comparison-issue-side - [`2b5229d`](https://github.com/morluto/rea/commit/2b5229dc77f767607053d9e52a06b6dd18ab6055) test(wasm): cover both comparison sides through the MCP boundary - [`1e441bb`](https://github.com/morluto/rea/commit/1e441bb31c99fe6e7926aa4a3285fbbb444275f8) Merge remote-tracking branch 'upstream/main' into fix/wasm-comparison-issue-side - [`5b0f78c`](https://github.com/morluto/rea/commit/5b0f78c1fdf705e8b83a1c1aa66f7faa6527207e) Merge remote-tracking branch 'upstream/main' into fix/wasm-comparison-issue-side ### 📊 Changes **3 files changed** (+96 additions, -5 deletions) <details> <summary>View changed files</summary> 📝 `src/application/wasm/WasmInterfaceComparisonService.test.ts` (+34 -0) 📝 `src/application/wasm/WasmInterfaceComparisonService.ts` (+11 -5) 📝 `tests/process-global/derivedOperationFailures.test.ts` (+51 -0) </details> ### 📄 Description ## Summary Fixes #7303. `compare_wasm_interfaces` rejects tampered or rebound `inspect_wasm_artifact` Evidence with an `AnalysisInputError` whose issue path is `[]`, so the caller cannot tell whether `left` or `right` was rejected. The issue now names the argument: `path: ["left"]` or `path: ["right"]`. ## Problem and expected behavior `parseInspection` reports every rejected side through `inspectionInputFailure`, which builds one issue at `path: []`. The side being parsed is known at the call site but is not passed down. Expected: the issue path names the input argument whose Evidence was rejected. ## Change and scope - `src/application/wasm/WasmInterfaceComparisonService.ts`: `parseInspection(raw, side)` passes the side to `inspectionInputFailure`, which reports the issue at `path: [side]` with the same reason and message. The two call sites pass `"left"` and `"right"`. 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. Contribution scope: not applicable. This is a fix inside the existing Wasm interface comparison. ## Contract and boundary impact - Semantic owner and earliest changed stage: `compareWasmInterfaces`, where each side's Evidence is admitted. - Contribution scope fit and linked maintainer decision: not applicable. - CLI and MCP/tool-catalog contract: the rejected-Evidence issue path is `["left"]` or `["right"]` instead of `[]`; reason and message are unchanged. - Provider, bridge, target-format, or platform compatibility: none. - Evidence, artifact, provenance, or reconstruction contract: none. - Target selection, authority, upstream behavior, and cleanup details (if applicable): none. - 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): none. 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 - Tests added or updated: - `src/application/wasm/WasmInterfaceComparisonService.test.ts`, "names the %s argument whose Evidence is rejected", for `left` and `right`: both tampered Evidence and authentic Evidence (built with `createEvidence`) whose selection names another artifact report `path: [side]`. - `tests/process-global/derivedOperationFailures.test.ts`, "names the %s argument whose authentic Evidence selects another artifact", for `left` and `right`: MCP `compare_wasm_interfaces` returns `invalid_request` with the issue at `[side]`, and no Evidence is retained. - Base reproduction or other evidence: with `WasmInterfaceComparisonService.ts` from upstream/main a989c0e45, all four new tests fail (the issue path is `[]`); the other 88 tests in both files pass. - User-visible CLI/MCP output (if applicable): the issue path in the input error. - Remaining proof gaps: the CLI path shares the same service and was not run separately. 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 On Linux (WSL Ubuntu, Node 24.22.1) at 5b0f78c1f (upstream/main a989c0e45 merged), after `npm ci` and `npm run mcp-catalog:generate`: - `npx tsc -p . --noEmit` passed. - `npx oxfmt --check` on the changed files: clean. `node scripts/ci/static-check-report.mjs lint`: 0 errors. - `npx vitest run src/application/wasm/WasmInterfaceComparisonService.test.ts tests/process-global/derivedOperationFailures.test.ts`: 92 passed, in two runs. - The negative check above failed only the four new tests. - CI failures outside this change reproduce on upstream/main a2e2c29b5 without it, run locally on Linux after `npm ci` and `npm run build:cached`: `kimiClientConfiguration.test.ts` (5 failed), `WindowsNativeLoader.test.ts` (8), `appleApplication.test.ts` (8), `providerBinding.test.ts` (1), `processCleanupRetryOwnership.test.ts` (2). In CI on this branch, `WasmInterfaceComparisonService.test.ts` passed all 13 tests. ## Compatibility, safety, and release - Breaking changes or migration steps: none; only the issue path changes. - Real Hopper/Ghidra, browser, or OS coverage: Linux only. - Package or release metadata impact: none. - Security, privacy, process, or containment review: none. ## 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: @Adolanium - [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. --> - [ ] 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. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-05 01:47:49 +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#7810
No description provided.