Skip to content
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"type" : "bugfix",
"description" : "Q toolwindow potentially render chat UI when it's supposed to show auth UI and it makes users not able to complete setup"
}
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ class AmazonQToolWindowFactory : ToolWindowFactory, DumbAware {
override fun onProfileSelected(myProject: Project, profile: QRegionProfile?) {
if (project.isDisposed) return
AmazonQToolWindow.getInstance(project).disposeAndRecreate()
qPanel.setContent(AmazonQToolWindow.getInstance(project).component)
prepareChatContent(project, qPanel)
}
}
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,8 +69,9 @@ class QRegionProfileManager : PersistentStateComponent<QProfileState>, Disposabl
}

if (profiles == null || profiles.none { it.arn == selected.arn }) {
invalidateProfile(selected.arn)
// Note that order matters, should switch to null first then invalidateProfile
switchProfile(project, null, intent = QProfileSwitchIntent.Reload)
invalidateProfile(selected.arn)
Comment on lines +85 to +87
Copy link
Contributor Author

Choose a reason for hiding this comment

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

not ideal, will revisit later

Telemetry.amazonq.profileState.use { span ->
span.source(QProfileSwitchIntent.Reload.value)
.amazonQProfileRegion(selected.region)
Expand Down
Loading