Skip to content

fix(explore): hide SQL Lab links for semantic views - #46336

Merged
mikebridge merged 1 commit into
apache:masterfrom
mikebridge:fix-semantic-explore-sqllab-links
Nov 19, 2026
Merged

mikebridge merged 1 commit into
apache:masterfrom
mikebridge:fix-semantic-explore-sqllab-links

Conversation

@mikebridge

Copy link
Copy Markdown
Member

Explore now hides the SQL Lab actions for semantic views, where those actions are not applicable. SQL datasets and query datasources keep their existing actions, including on unsaved charts.

SUMMARY

Hide “Run in SQL Lab” in the Explore actions menu and “View in SQL Lab” in the datasource menu when the datasource is a semantic view. Keep “View query” available. Add coverage for semantic views, tables and query datasources on saved and unsaved charts.

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

No browser check has been performed for this PR, and no screenshot is available yet. This is a draft pending that verification.

TESTING INSTRUCTIONS

Automated validation: both affected component suites pass (94 tests); changed-file pre-commit checks, including frontend type checking, pass.

Manual verification pending:

  1. Open a semantic-view chart in Explore, both saved and unsaved. Confirm “Run in SQL Lab” and “View in SQL Lab” are absent, while “View query” remains available.
  2. Repeat with a SQL dataset and a query datasource. Confirm the SQL Lab actions remain available when the user has the existing permissions.

ADDITIONAL INFORMATION

  • Has associated issue
  • Required feature flags
  • Changes UI
  • Includes DB Migration
  • Introduces new feature or API
  • Removes existing feature or API

@codecov

codecov Bot commented Nov 18, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 65.43%. Comparing base (987710c) to head (91dc71d).
⚠️ Report is 18 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master   #46336   +/-   ##
=======================================
  Coverage   65.43%   65.43%           
=======================================
  Files        3102     3102           
  Lines      213946   213951    +5     
  Branches    50537    50542    +5     
=======================================
+ Hits       139996   140000    +4     
- Misses      70731    70732    +1     
  Partials     3219     3219           
Flag Coverage Δ
javascript 82.00% <100.00%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@mikebridge
mikebridge marked this pull request as ready for review November 19, 2026 00:18
@codeant-ai-for-open-source

Copy link
Copy Markdown
Contributor

CodeAnt  CodeAnt PR Risk

🟢  Low Risk

  • The PR appears safe to merge; no actionable issues were identified in the review.

Assessed commit: 91dc71dea47f

@aminghadersohi aminghadersohi left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Both SQL Lab actions are hidden for semantic views, and each new semantic-view case fails if its gate is reverted.

Nit: DatasourceControl.test.tsx: the menu never reads form_data.slice_id, so its saved/unsaved cases run the same code.

@mikebridge
mikebridge merged commit 87bad35 into apache:master Nov 19, 2026
138 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants