litellm/tests/test_litellm/enterprise/proxy
Sameer Kankute 9ddf0535b1
fix(proxy): skip double-wrapping unified batch output file ids on retrieve (#30011)
* fix(proxy): skip double-wrapping unified batch output file ids on retrieve

After ensure_batch_response_managed_file_ids normalizes output_file_id, the managed files post-call hook was re-encoding the unified id and storing the nested id as the provider mapping. Use the decoded llm_output_file_id for retrieve and model_mappings instead.

Co-authored-by: Cursor <cursoragent@cursor.com>

* fix(proxy): guard managed file id parsing for non-output unified formats

Only treat decoded unified ids as already-wrapped output files when they contain llm_output_file_id. Skip other litellm_proxy id shapes instead of IndexError on split.

Co-authored-by: Cursor <cursoragent@cursor.com>

* fix(proxy): rename loop variable to satisfy mypy unified file id typing

Co-authored-by: Cursor <cursoragent@cursor.com>

---------

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-11 22:00:43 -07:00
..
__init__.py [Bug Fix] - Fix litellm_enterprise ensure imported routes exist (#17337) 2025-12-01 19:14:12 -08:00
test_afile_retrieve_returns_unified_id.py fix: afile_retrieve returns unified ID for batch output files 2026-02-14 10:07:12 -05:00
test_batch_retrieve_input_file_id.py fix: batch retrieve returns unified input_file_id 2026-02-14 11:24:08 -05:00
test_batch_retrieve_returns_unified_input_file_id.py fix: batch retrieve returns unified input_file_id 2026-02-14 11:24:08 -05:00
test_batch_update_db_managed_output_file_id.py fix(proxy): normalize batch file IDs before ManagedObjectTable write (#28339) 2026-05-20 12:13:56 -07:00
test_deleted_file_returns_403_not_404.py Addressed greptile comments to extract common helpers and return 404 2026-02-16 07:58:04 -05:00
test_enterprise_routes.py [Bug Fix] - Fix litellm_enterprise ensure imported routes exist (#17337) 2025-12-01 19:14:12 -08:00
test_file_deletion_blocking.py Fixes based on greptile reviews 2026-02-18 12:19:11 +05:30
test_managed_files_access_check.py fix(managed_batches): convert raw output_file_id to managed ID in CheckBatchCost poller (#27984) 2026-05-15 04:41:38 -07:00
test_managed_files_hook.py fix(proxy): skip double-wrapping unified batch output file ids on retrieve (#30011) 2026-06-11 22:00:43 -07:00