Repository navigation
test(rust): model the blocking OCR hook as a guardrail so its raise propagates - #42775
Merged
Merged
Conversation
…ropagates Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
Contributor
Author
|
I'll fix CI failures and address comments from users with write access. I'll skip comments containing "(aside)".
|
4 of 6 tasks
Contributor
|
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
yujonglee-berri
enabled auto-merge (squash)
September 23, 2026 19:17
yujonglee-berri
approved these changes
Sep 23, 2026
4 of 6 tasks
This was referenced Sep 26, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
TLDR
Problem this solves:
rust-wheelCI is red on main since fix(utils): isolate callback errors in async_post_call_success_deployment_hook #42535test_native_aocr_state_stashed_before_a_blocking_hook_raises_reaches_failure_callbacksexpects a raise that is now swallowedCustomGuardrailhooks abort a completed requestHow it solves it:
Blockcallback now subclassesCustomGuardrailUser Flow
Test-only change, no proxy behavior changes
Relevant issues
Follow-up to #42535. Unblocks the
rust-wheeljob on #42769 and every other PRAffected release
Linear ticket
Pre-Submission checklist
Please complete all items before asking a LiteLLM maintainer to review your PR
uv run pytest tests/test_litellm/<your_test_file>.py -v. Leave the suites (make test-unit-*,make test-unit) to CI: it finishes in ~15 minutes where a laptop takes an hour or more@greptileaito re-request a review after pushing changes)Screenshots / Proof of Fix
Test-only change. Before:
rust-wheelon main run https://github.com/BerriAI/litellm/actions/runs/35881390552 fails withDID NOT RAISE Blocked. After:tests/test_litellm_rust/ocr/test_callbacks.pypasses locally, 29 passedType
✅ Test
Caveats (if any)
Low
Final Attestation
Link to Devin session: https://app.devin.ai/sessions/6663034c50e246e686b624c794a71fdb
Open in Devin Desktop: https://app.devin.ai/desktop/session/6663034c50e246e686b624c794a71fdb?variant=devin
Requested by: @yujonglee-berri