Skip to content

fix(lightspeed): disable model selector during active chat session#3682

Closed
its-mitesh-kumar wants to merge 1 commit into
redhat-developer:mainfrom
its-mitesh-kumar:fix/lightspeed-RHDHBUGS-3313-disable-model-selector-active-chat
Closed

fix(lightspeed): disable model selector during active chat session#3682
its-mitesh-kumar wants to merge 1 commit into
redhat-developer:mainfrom
its-mitesh-kumar:fix/lightspeed-RHDHBUGS-3313-disable-model-selector-active-chat

Conversation

@its-mitesh-kumar

Copy link
Copy Markdown
Member

Description

Disables the model selector once a chat session is active (has messages) to prevent the user from inadvertently creating a new conversation by switching models mid-session. When disabled, hovering the selector shows a localized tooltip explaining: "Each chat session supports only one model. To switch models, open a new chat."

Root cause: The MessageBarModelSelector's disabled prop was only set to isSendButtonDisabled (true only during streaming). Once streaming completed, the selector became clickable again. The onSelect handler always called onNewChat(), which created a new conversation instead of keeping the user in the current session.

Fixed

  • RHDHBUGS-3313 — Lightspeed: Switching model in an active conversation incorrectly opens a new chat

Checklist

  • A changeset describing the change and affected packages. (more info)
  • Added or Updated documentation
  • Tests for new functionality and regression tests for bug fixes
  • Screenshots attached (for UI changes)

Made with Cursor

Once a chat session has started (messages exist), the model selector is
now disabled to prevent unintended new conversation creation. A tooltip
explains the restriction in all supported locales.

Fixes: https://redhat.atlassian.net/browse/RHDHBUGS-3313
Signed-off-by: its-mitesh-kumar <itsmiteshkumar98@gmail.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
@rhdh-gh-app

rhdh-gh-app Bot commented Jul 3, 2026

Copy link
Copy Markdown

Changed Packages

Package Name Package Path Changeset Bump Current Version
@red-hat-developer-hub/backstage-plugin-lightspeed workspaces/lightspeed/plugins/lightspeed patch v2.9.1

@sonarqubecloud

sonarqubecloud Bot commented Jul 3, 2026

Copy link
Copy Markdown

@its-mitesh-kumar its-mitesh-kumar deleted the fix/lightspeed-RHDHBUGS-3313-disable-model-selector-active-chat branch July 3, 2026 22:30
@its-mitesh-kumar

Copy link
Copy Markdown
Member Author

This is the test PR by bug-fix skill .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant