litellm/tests/unit/integrations/newrelic
Mateo Wang 440cc9c608
refactor(types): parameterize the bare list and dict fields of StandardLoggingPayload (#55383)
* refactor(types): parameterize the bare list and dict fields of StandardLoggingPayload

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>

* fix(argilla): flatten response parsing to clear TRY002, add regression tests for non-mapping choices

The else branch in get_str_response added one TRY002 over the merge-base ceiling. Tests cover a first choice or message that is not a mapping in Argilla, Datadog LLM Obs, Literal AI and New Relic

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>

* refactor(custom_logger): build the truncated logging payload in one expression

Replaces the three in-place assignments on the copy with read-only partial TypedDicts spread into the returned payload

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>

* fix(argilla): report an empty choices list as an invalid response format

An empty list reached choices[0] and raised IndexError instead of the logger's own error

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>

* refactor(types): mark request_tags read-only and document the three logging fields that stay writable

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>

---------

Co-authored-by: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-12-01 02:58:22 +00:00
..
__init__.py
test_newrelic.py refactor(types): parameterize the bare list and dict fields of StandardLoggingPayload (#55383) 2026-12-01 02:58:22 +00:00
test_newrelic_metrics.py
test_newrelic_team_handler.py refactor: expose core private helpers under public names (#44871) 2026-10-07 00:05:27 +00:00