flux-pr-1184
graphql-go-tools (Go) · W2 · GPT-5.1 Codex Mini
Tests passed. 1/1 commands passed. Strength: strong.
go test -C v2 ./... -count=1 -timeout=300sPartial score: 1/1
Trajectory
codex · partial order onlyprovider-native trajectory captured; validation and decision steps are appended with coarse ordering only
Quality
Equivalence Reasoning
behavioral
The patch fixes the interface-entity filter bug and adds union-fragment handling, but it appears to miss core intent details: it rewrites any selection containing union fragments unconditionally (instead of conditional cleanup logic), and it does not apply the parent-valid-types object-fragment cleanup at top-level union/interface rewrite-decision points the way the intended fix does. This can change planner behavior and leave edge cases incorrect.
Code Review
The patch likely fixes core nested-union planning failures and the entity-filter bug, but it does not fully match the intended change set; missing typename preservation and incomplete object-fragment cleanup integration make full correctness uncertain.
The new `flattenFragmentOnUnion` does not preserve `__typename` from the fragment selection set before rewriting, so queries that explicitly requested it inside nested union fragments can lose that field in rewritten plans.
The task requires object fragment cleanup to validate membership in parent valid types, but top-level rewrite decision paths still appear to rely on legacy object-fragment checks and do not clearly route through the new parent-aware cleanup helper.
Inside `flattenFragmentOnUnion`, object fragments are copied as-is instead of being recursively flattened; nested interface/union fragments under those objects may remain unnormalized and can reintroduce planning inconsistencies.