justinpark opened a new pull request, #40101: URL: https://github.com/apache/superset/pull/40101
### SUMMARY Fixes a bug where the Estimate Query Cost button was missing in SQL Lab. Two issues were causing the button to not appear: 1. Backend: allows_cost_estimate was missing from DATABASE_KEYS in superset/sqllab/utils.py. This key is used when serializing database metadata to the frontend, so its absence meant the frontend never received the flag indicating a database supports cost estimation — causing the button to be hidden. 2. Frontend: The EstimateQueryCostButton was using color="primary" with variant="text", which rendered the button as same as other sibling buttons. ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF Before: <img width="1127" height="686" alt="Screenshot 2026-05-13 at 5 36 29 PM" src="https://github.com/user-attachments/assets/4cd2ccd9-6370-436e-9c3b-e34d882b363b" /> After: <img width="861" height="501" alt="Screenshot 2026-05-13 at 5 42 57 PM" src="https://github.com/user-attachments/assets/0f8d3bb0-c89c-4555-905c-366b89715b7a" /> ### TESTING INSTRUCTIONS 1. Connect to a database that supports cost estimation (e.g., BigQuery, Presto/Trino) 2. Open SQL Lab and write a query 3. Verify the Estimate button appears in the toolbar 4. Click it and confirm the cost estimate modal opens correctly ### ADDITIONAL INFORMATION <!--- Check any relevant boxes with "x" --> <!--- HINT: Include "Fixes #nnn" if you are fixing an existing issue --> - [ ] Has associated issue: - [ ] Required feature flags: - [ ] Changes UI - [ ] Includes DB Migration (follow approval process in [SIP-59](https://github.com/apache/superset/issues/13351)) - [ ] Migration is atomic, supports rollback & is backwards-compatible - [ ] Confirm DB migration upgrade and downgrade tested - [ ] Runtime estimates and downtime expectations provided - [ ] Introduces new feature or API - [ ] Removes existing feature or API -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
