Conversation
…private-network HTTP
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration: reviews:
auto_review:
drafts: trueThanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
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.
Found by the 0.60.4-0.69.0 port gap audit (gap G6, 0.64.0).
Summary
LiteLLM now reads the key-bound identity and budgets the way upstream 0.64.0 does, instead of
key/infoonly:GET /key/infosuppliesuser_id/team_id. If both are absent the fetch fails with "LiteLLM key info did not include a user_id or team_id."GET /user/info?user_id=; the returned user ID must equal the key's. Personal spend and budget are the primary row. The team whoseteam_idmatches the key (from theteamslist) is a separate "Team budget" row. Account display uses the key-bound identity:user_email, thenuser_alias, thenmetadata.preferred_username; organization is the matching team alias.GET /team/info?team_id=; the returned team ID must equal the key's. The team budget is the sole usage row.expiresare carried as reset / subscription expiry..local), no embedded credentials, no encoded host delimiters. The same validator backs the saved base-URL setting in Preferences.https://host/litellm/v1->https://host/litellm/key/info); the oldUrl::joinwould have dropped the last path segment.Upstream reference
Sources/CodexBarCore/Resources/Plugins/litellm.ts,docs/litellm.md.Ported / Deferred
Ported: everything above, with upstream's ID cross-checks, "missing team_id" / invalid-type parse failures, tolerant date parsing, and the
infoenvelope requirement on/key/info.Deferred or different:
is_blocked_hostinprovider_workspace.rs, which is the opposite policy and is still used by Zed). The LiteLLM policy lives inproviders/litellm/endpoint.rsso it stays provider-local; if Port upstream 0.66.0: llmman provider #650 lands first the two can be unified.key/info(as upstream's suffix) and replaced foruser/info/team/info.Validation
All with
cargo +1.98.0via the E-core wrapper:cargo fmt --all: cleancargo clippy --workspace --all-targets -- -D warnings: pass (both manifests)cargo test -p codexbar litellm: 18 passed (incl.settings::provider_workspaceLiteLLM policy test)cargo test -p codexbar(full): 2174 passed, 0 failed, 1 ignoredpnpm testnot run. The Tauri crate is unchanged.Affected areas
rust/src/providers/litellm/:mod.rs, newendpoint.rs,info.rs,tests.rs)rust/src/settings/provider_workspace.rs)LiteLlmBaseUrlHelptext (other locales unchanged)UI proof
Pending: coordinator will capture CUA proof on a fresh build.