Skip to content

fix(dashboards): disable timeseries explain when AI is disabled - #9646

Merged
nishantmonu51 merged 1 commit into
mainfrom
explain_disable
Jul 6, 2026
Merged

fix(dashboards): disable timeseries explain when AI is disabled#9646
nishantmonu51 merged 1 commit into
mainfrom
explain_disable

Conversation

@nishantmonu51

Copy link
Copy Markdown
Collaborator
  • Gates the explore timeseries Explain feature on the ai feature flag: when AI is disabled, both the on-chart "Explain (E)" button and the E keyboard shortcut are hidden.
  • Adds ai to measureSelection.getEnabledStore() and wires that store into ExplainButton (MeasureChartBody.svelte) and the key handler (ChartInteractions.svelte). The store was purpose-built to gate explain but had become unused after an earlier MeasureChart refactor, so explain was rendering ungated.
  • Restoring the store's existing dashboardChat && exploreName conditions only hides explain where it is already non-functional (embeds and the explore editor); normal cloud dashboards are unaffected since dashboard_chat defaults to true there.

Checklist:

  • Covered by tests
  • Ran it and it works as intended
  • Reviewed the diff before requesting a review
  • Checked for unhandled edge cases
  • Linked the issues it closes
  • Checked if the docs need to be updated. If so, create a separate Linear DOCS issue
  • Intend to cherry-pick into the release branch
  • I'm proud of this work!

Developed in collaboration with Claude Code

The explain anomaly feature opens the dashboard AI chat, so it should be
hidden when the `ai` feature flag is off. Add `ai` to the explain
enablement store and wire it into the ExplainButton render and the `E`
keyboard shortcut, which were previously ungated after the store's
wiring was dropped in an earlier refactor.
@nishantmonu51

Copy link
Copy Markdown
Collaborator Author

@codex: review

@nishantmonu51
nishantmonu51 requested a review from AdityaHegde July 3, 2026 18:40
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Another round soon, please!

Reviewed commit: c28f95cd5d

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@nishantmonu51
nishantmonu51 merged commit b902c3a into main Jul 6, 2026
16 checks passed
@nishantmonu51
nishantmonu51 deleted the explain_disable branch July 6, 2026 07:51
@nishantmonu51 nishantmonu51 added Type:Bug Something isn't working Area:Dashboard Size:S Small change: under 100 lines labels Jul 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area:Dashboard Size:S Small change: under 100 lines Type:Bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants