Skip to content

fix: remove prefilter_by_guard eval_item fallback (F8)#575

Merged
Muizzkolapo merged 1 commit into
integration/batch-online-unificationfrom
fix/f8-prefilter-fallback
May 19, 2026
Merged

fix: remove prefilter_by_guard eval_item fallback (F8)#575
Muizzkolapo merged 1 commit into
integration/batch-online-unificationfrom
fix/f8-prefilter-fallback

Conversation

@Muizzkolapo
Copy link
Copy Markdown
Owner

Summary

  • Removed the dormant has_pipeline_context check and context = eval_item fallback in prefilter_by_guard — now always uses build_guard_context unconditionally
  • All production callers already pass full pipeline kwargs, so the fallback was dead code that could silently reintroduce online/batch guard divergence
  • Deleted 8 tests that asserted the old fallback behavior (context==eval_item identity, fallback warning emission)
  • Updated paired_execution conftest fixture mock to handle the richer context shape from build_guard_context

Verification

  • pytest — 7024 passed, 2 skipped
  • ruff format --check + ruff check — clean
  • Grepped all prefilter_by_guard callers — both production callers (_guard_filter, _guard_filter_file_mode) pass full pipeline context

The has_pipeline_context check in prefilter_by_guard silently fell back
to context=eval_item when no pipeline kwargs were passed. All production
callers already pass full context, making this a dormant anti-pattern
that could reintroduce online/batch guard divergence if a future caller
omitted the kwargs.

Now prefilter_by_guard always calls build_guard_context unconditionally.
Deleted 8 tests that asserted the old fallback behavior (context==eval_item,
fallback warning). Updated the paired_execution conftest fixture to handle
the richer context shape from build_guard_context.
@Muizzkolapo Muizzkolapo force-pushed the fix/f8-prefilter-fallback branch from 4743ef8 to cc41223 Compare May 19, 2026 18:18
@Muizzkolapo Muizzkolapo merged commit 6cbe3d6 into integration/batch-online-unification May 19, 2026
1 check passed
@github-actions github-actions Bot locked and limited conversation to collaborators May 19, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant