Skip to content

Conversation

@slytechnical
Copy link
Contributor

@slytechnical slytechnical commented May 28, 2025

Description

One-line fix to ensure litellm model list refreshes go through by first clearing the litellm model list cache

Test Procedure

Type of Change

  • 🐛 Bug Fix: Non-breaking change that fixes an issue.
  • New Feature: Non-breaking change that adds functionality.
  • 💥 Breaking Change: Fix or feature that would cause existing functionality to not work as expected.
  • ♻️ Refactor: Code change that neither fixes a bug nor adds a feature.
  • 💅 Style: Changes that do not affect the meaning of the code (white-space, formatting, etc.).
  • 📚 Documentation: Updates to documentation files.
  • ⚙️ Build/CI: Changes to the build process or CI configuration.
  • 🧹 Chore: Other changes that don't modify src or test files.

Pre-Submission Checklist

  • Issue Linked: This PR is linked to an approved GitHub Issue (see "Related GitHub Issue" above).
  • Scope: My changes are focused on the linked issue (one major feature/fix per PR).
  • Self-Review: I have performed a thorough self-review of my code.
  • Code Quality:
    • My code adheres to the project's style guidelines.
    • There are no new linting errors or warnings (npm run lint).
    • All debug code (e.g., console.log) has been removed.
  • Testing:
    • New and/or updated tests have been added to cover my changes.
    • All tests pass locally (npm test).
    • The application builds successfully with my changes.
  • Branch Hygiene: My branch is up-to-date (rebased) with the main branch.
  • Documentation Impact: I have considered if my changes require documentation updates (see "Documentation Updates" section below).
  • Changeset: A changeset has been created using npm run changeset if this PR includes user-facing changes or dependency updates.
  • Contribution Guidelines: I have read and agree to the Contributor Guidelines.

Screenshots / Videos

Documentation Updates

Additional Notes

Get in Touch


Important

Fixes cache issue in LiteLLM.tsx by flushing models before refetching.

  • Behavior:
    • In LiteLLM.tsx, added a call to vscode.postMessage with type flushRouterModels before requestRouterModels to clear the cache.
  • Functions:
    • Modified handleRefreshModels in LiteLLM.tsx to include cache flushing step.

This description was created by Ellipsis for 32d9247. You can customize this summary. It will automatically update as commits are pushed.

@slytechnical slytechnical requested review from cte and mrubens as code owners May 28, 2025 15:43
@dosubot dosubot bot added size:XS This PR changes 0-9 lines, ignoring generated files. bug Something isn't working labels May 28, 2025
setRefreshError(t("settings:providers.refreshModels.missingConfig"))
return
}
vscode.postMessage({ type: "flushRouterModels", text: "litellm" })
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it guaranteed that this will finish before we request the models in the next line? Is there a world where we add some sort of flush: true to the requestRouterModels instead?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The order isn't guaranteed, but I'm addressing that in the refactor. This was just intended to be a hacky one-line mitigation for now. Ok to close this PR if we'd rather hold off for a proper fix

@hannesrudolph hannesrudolph added the Issue/PR - Triage New issue. Needs quick review to confirm validity and assign labels. label May 28, 2025
@hannesrudolph hannesrudolph moved this from Triage to PR [Needs Review] in Roo Code Roadmap May 28, 2025
@hannesrudolph hannesrudolph added PR - Needs Review and removed Issue/PR - Triage New issue. Needs quick review to confirm validity and assign labels. labels May 28, 2025
@mrubens mrubens closed this May 31, 2025
@github-project-automation github-project-automation bot moved this from PR [Needs Review] to Done in Roo Code Roadmap May 31, 2025
@github-project-automation github-project-automation bot moved this from New to Done in Roo Code Roadmap May 31, 2025
SmartManoj pushed a commit to SmartManoj/Raa-Code that referenced this pull request Jun 16, 2025
* feat: Added a configurable default terminal profile setting

* chore: format

* refactor: migrate terminal profiles to gRPC and remove legacy message handling

- rename AvailableTerminalProfilesResponse to TerminalProfiles in proto
- remove duplicate TerminalProfile type from terminal_types.ts
- update all imports to use TerminalProfile from proto/state
- remove legacy availableTerminalProfiles message handling from ExtensionStateContext
- clean up ExtensionMessage type by removing unused availableTerminalProfiles
- translate Spanish comment to English in TerminalSettingsSection
- update server-side getAvailableTerminalProfiles to use new proto type

* chore: lint

* fix: merge main

* fix: resolve errors

* chore: notify terminal profile settings

* chore: merge main

* feat: improve default terminal profile changes

* fix: update changes on save
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working PR - Needs Review size:XS This PR changes 0-9 lines, ignoring generated files.

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

4 participants