Repository navigation
fix(native)!: preserve value-flow absence semantics - #8785
Conversation
[Medium impact] The PR appears safe to merge; no actionable correctness or security issues remain. SummaryKuna now records native value flow as explicitly unavailable. Traces distinguish an unrecorded observation from a provider’s stated reason.
Reviews (4) · Last reviewed commit: "Merge remote-tracking branch 'origin/mai..." · Reviewed by Greptile |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Keep the fixed-adapter trace refusal as capability_unavailable when source Evidence cannot be retained, and keep the recorded-absence reason for traces that do run.
|
Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits. |
Stop freezing the unrecorded and Kuna unavailable sentences. Assert the procedure-scoped unknown and that an explicit provider reason is preserved.
|
Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits. |
|
Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits. |
Problem and change
analyze_functionrepresented Kuna value flow as unrecorded, whiletrace_native_valuesturned any unrecorded facet into a provider-wide claim that the provider has no model. Record the actual REA Kuna integration's unavailability at the provider boundary and propagate that reason through the existing dossier, retained view and trace. For an unrecorded facet from any provider, the trace now says the observation was not recorded for that procedure. Fixes #8783.This does not claim that upstream Kuna lacks all def-use capabilities, change target execution, or add a provider operation.
Snapshot impact
The Kuna analysis profile changes, so older Kuna snapshots are refused regardless of which operations they contain. Open without the old snapshot and save a fresh one. Native-value-trace workflow profiles also change for all providers, so older trace entries are not replayed as new results. The semantic marker is independent of the value-trace revision in #8384 so both commitments can coexist. Historical Evidence remains importable. This is a profile-wide breaking change, not an automatic migration.
Validation
value_flow_parametersview and trace all returned the same explicit REA-provider reason. Target SHA-256c244f7d7d9fa9b7f4cfcb1f69d69cc1f83ad98fe38b0293b223b3ca7d9076363was unchanged.check:ci:fast,docs:check, andgit diff --checkpassed. Other providers and real cleanup failure were not exercised.Source-retention integration control
In an isolated, uncommitted combination of this head
465e8b1e0and #8384a20c186eb, one fixed-adapter test conflict was resolved to preserve #8384's refusal when source Evidence cannot be retained. The focused trace, snapshot, MCP and Kuna provider files passed (119 tests). Real Kuna 1.989 and Ghidra 12.1.4 stdio MCP in compact and full profiles returned resolvable linked trace sources in exported bundles; Kuna's trace kept its provider-specific unavailability, and Ghidra returned nine nodes for the tested function. The unexecuted target digest stayedc244f7d7d9fa9b7f4cfcb1f69d69cc1f83ad98fe38b0293b223b3ca7d9076363.A compiled profile control checked four distinct digests for the old workflow, either individual semantic change, and their combination. The combined profile contained both #8384's revision 2 and this PR's absence marker. This is a combined-checkout control, not standalone PR CI or proof of cleanup/failure behavior.
Offline and fresh-snapshot controls
Real Kuna 1.989 MCP sessions in compact and full profiles exported the dossier and trace, then fresh target-free servers imported the bundles. Both records round-tripped exactly, and the bounded parameter view returned the same explicit unavailability reason as the dossier and trace. Fresh Kuna snapshots reopened successfully and a subsequent trace returned the same reason; those snapshots had no cached workflow entry and no replay limitation, so this is a live re-analysis control, not evidence of Kuna replay.
With real Ghidra 12.1.4 on the same target and both profiles, fresh snapshots included a workflow entry; reopening and tracing retained the same node count and reported a snapshot-loaded function observation. This does not establish whole-workflow replay or source-closure correctness (covered separately by #8384). The snapshots and unexecuted target remained unchanged during the second sessions.
Function-specific Ghidra unavailability
With real Ghidra 12.1.4 MCP on a separate unexecuted arm64 Mach-O,
analyze_function(EXTERNAL:0x1)reported that the selected procedure had no HighFunction p-code model. In both compact and full profiles, the retainedvalue_flow_parametersview andtrace_native_valuespreserved that exact function-specific reason. The target SHA-256 remainedaeed1f352785fd14c9cfcc0e9cf9958354e22ca5c8b979d2f6047585c45ed4d8. This is one external-function control, not a provider-wide Ghidra capability claim.Retained-Evidence summary control
Fresh target-free MCP sessions imported the earlier extracted Kuna Evidence bundle and the new live-session bundle separately.
get_evidence_bundle(detail: summary, filters: {operation: "analyze_function"})reportednot-recordedfor both old dossiers andunavailablewith the REA Kuna reason for the new dossier, in both schema profiles. This verifies that historical nulls are not rewritten into the newer provider claim at the retained-record boundary.Author readiness
Human owner: