fix(ui): URL-encode team_id in teamInfoCall to handle special characters - #27466
Conversation
Greptile SummaryThis PR fixes a bug in
Confidence Score: 4/5Safe to merge — the change is a single-line fix to encode a query parameter value, and the new tests validate both the encoding and the null-team-ID path using proper mocks. The code change is correct and well-targeted. The PR description does not reference or link the issue being fixed, nor does it include a screenshot or repro trace as the template requires, making it harder to trace context after the fact. No files require special attention; both changed files are straightforward.
|
| Filename | Overview |
|---|---|
| ui/litellm-dashboard/src/components/networking.tsx | Correct minimal fix: encodeURIComponent applied to team_id query param value in teamInfoCall. |
| ui/litellm-dashboard/src/components/networking.test.ts | Two new mock-based tests added for teamInfoCall; use vi.fn() mocks with proper setup/teardown and no real network calls. |
Reviews (1): Last reviewed commit: "fix(ui): URL-encode team_id in teamInfoC..." | Re-trigger Greptile
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
144279e
into
BerriAI:litellm_internal_staging
Relevant issues
team_id with special characters in it fails with 404 error
Linear ticket
Pre-Submission checklist
Please complete all items before asking a LiteLLM maintainer to review your PR
tests/test_litellm/directory, Adding at least 1 test is a hard requirement - see detailsmake test-unit@greptileaiand received a Confidence Score of at least 4/5 before requesting a maintainer reviewDelays in PR merge?
If you're seeing a delay in your PR being merged, ping the LiteLLM Team on Slack (#pr-review).
UI Change for updating the FE API call
🐛 Bug Fix
Changes
malformed URLs from raw concatenation; team IDs with reserved chars produced wrong server-side lookups.