Skip to content

fix(managed): share native verification input diagnostics - #2901

Merged
morluto merged 1 commit into
morluto:mainfrom
ShitK:fix/managed-native-verification-diagnostics
Oct 13, 2026
Merged

morluto merged 1 commit into
morluto:mainfrom
ShitK:fix/managed-native-verification-diagnostics

Conversation

@ShitK

@ShitK ShitK commented Oct 13, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Fixes #2621.

A single native observation that reuses the managed boundary's Evidence ID now reports only the role-distinctness error. Genuine duplicate native observations still report the uniqueness error.

Problem and expected behavior

The request validator seeded its native-ID set with the managed boundary ID, so one observation could incorrectly produce both diagnostics. The domain validator already distinguished these rules correctly.

Change and scope

Use managedNativeVerificationInputSchema directly in the tool contract, removing the duplicate validator and its superseded export. Move the existing native-observation field description to that canonical schema to preserve caller guidance. The domain owns validation for both the workflow and its advertised request contract.

Contract and boundary impact

  • Request fields, strictness, accepted inputs, and output contracts are unchanged; invalid-input diagnostics are corrected.
  • This is an ordinary validation fix within existing scope; a separate maintainer scope decision is not applicable.
  • Provider protocols, Evidence provenance, target authority, cleanup, packaging, and installation are unchanged. No generated outputs are committed.
  • This diagnostic correction introduces no target interaction.

Evidence and regression coverage

The updated contract test asserts exact messages and paths for one observation reusing the boundary, repeated native observations, repeated observations also reusing the boundary, and valid distinct observations. It exercises the domain schema, named tool contract, and metadata-wrapped Standard Schema validator.

On base 7e3a19863835215491b55fba7127a78bad6a7709, the updated test reproduced the bug: 2 failed, 4 passed. With the fix, the four selected files passed 35 tests, including existing managed verification and in-memory MCP SDK coverage.

Validation performed

macOS arm64, Node.js 24.18.0, npm 11.16.0:

  • Direct Vitest run of src/contracts/workflowInputContracts.test.ts, src/contracts/toolInputReferences.test.ts, tests/conformance/providers/managed/managedNativeVerification.test.ts, and tests/boundary/mcp/managedMcp.test.ts — 35 passed (6 + 16 + 11 + 2).
  • Touched-file lint/format, knip, module-boundary and architecture guards, test discovery (1,108 files exactly once), git diff --check, and the normal pre-commit hook — passed.
  • npm run test:focused and npm run docs:check — blocked by existing SupportedClients.ts TS2322 errors at lines 542, 744, and 809 (devin format).
  • npm run check — stopped on existing formatting failures in functionComparison.test.ts and IdaOperationRunner.ts.
  • Full TypeScript checking also reported existing TS2345 in clientProfileLifecycle.test.ts:297 and duplicate join imports (TS2300) in ghidraInventoryMcp.test.ts:4,17.

These blockers were independently reproduced on an exported pristine copy of the base revision with the same runtime. The standard checks remain blocked. The normal pre-push hook also failed on the unchanged duplicate join import; this branch was pushed with a one-command HUSKY=0 override.

Compatibility, safety, and release

No migration or release metadata change is needed. The executed MCP tests use an in-memory transport; compiled CLI, stdio transport, real engines, and CI results are not claimed. This fix was prepared with AI assistance.

Before merge

  • Focused fix linked to its issue, with regression coverage for observable diagnostics.
  • Canonical validation ownership and existing caller guidance are preserved.
  • Standard checks and CI pass; resolve or re-evaluate the documented base failures.

@ShitK
ShitK marked this pull request as ready for review October 13, 2026 16:26
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 13, 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 ✅ Completed 2026-10-13T16:28:43.210646Z 25478e8 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 13, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 5/5

[Medium impact] The diagnostic correction appears safe to merge; no actionable defects were found.

Summary

verify_managed_native_boundaries now uses the domain’s existing input schema instead of a duplicate validator.

  • Native verification reports the right message for each Evidence ID clash.

Reviews (1) · Last reviewed commit: "fix(managed): share native verification ..." · Reviewed by Greptile

@morluto
morluto merged commit 501c5d4 into morluto:main Oct 13, 2026
1 check passed
@morluto morluto mentioned this pull request Oct 13, 2026
3 tasks done
@morluto morluto added bug Something isn't working area: native Native analysis and decompilation, including Ghidra, IDA, and Hopper analysis behavior labels Oct 14, 2026
@morluto

morluto commented Oct 15, 2026

Copy link
Copy Markdown
Owner

Thank you for removing the duplicate managed/native input validator, @ShitK. Reusing the domain schema keeps the diagnostic for a reused Evidence ID consistent. Welcome to REA!

@morluto morluto added the area: tests Test suite and verification label Nov 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: native Native analysis and decompilation, including Ghidra, IDA, and Hopper analysis behavior area: tests Test suite and verification bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(managed): avoid a false duplicate-ID diagnostic for one native observation

2 participants