Skip to content

Conversation

@mrubens
Copy link
Collaborator

@mrubens mrubens commented Feb 11, 2025

For some reason we try to reload the models every 2 seconds, and that causes ApiOptions to re-render. There's probably something deeper to figure out here, but checking equality before updating state seems to alleviate this.

Before:

Screen_Recording_2025-02-10_at_10.37.58_PM.mov

After:

Screen.Recording.2025-02-10.at.11.19.06.PM.mov

Important

Fix flickering issue in ApiOptions.tsx by checking model data equality before updating state.

  • Behavior:
    • Fix flickering issue in ApiOptions.tsx by checking equality before updating state for ollamaModels, lmStudioModels, and vsCodeLmModels.
    • Prevents unnecessary state updates by comparing new and previous model data using JSON.stringify().
  • Misc:
    • Add changeset file funny-bananas-sneeze.md for patch release.

This description was created by Ellipsis for febf434. It will automatically update as commits are pushed.

@changeset-bot
Copy link

changeset-bot bot commented Feb 11, 2025

🦋 Changeset detected

Latest commit: febf434

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
roo-cline Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@mrubens mrubens force-pushed the fix_model_loading_flicker branch from 84d8d40 to febf434 Compare February 11, 2025 04:30
@mrubens mrubens merged commit 145819f into main Feb 11, 2025
5 of 6 checks passed
@mrubens mrubens deleted the fix_model_loading_flicker branch February 11, 2025 04:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants