Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Filter flag causes overlay for required "Number" filter with the default value set #16811

Closed
nemanjaglumac opened this issue Jun 29, 2021 · 1 comment · Fixed by #16850
Closed
Assignees
Labels
Priority:P2 Average run of the mill bug Querying/Native The SQL/native query editor Querying/Parameters & Variables Filter widgets, field filters, variables etc. .Regression Bugs that were previously fixed and/or bugs unintentionally shipped with new features. .Reproduced Issues reproduced in test (usually Cypress) Type:Bug Product defects
Milestone

Comments

@nemanjaglumac
Copy link
Member

nemanjaglumac commented Jun 29, 2021

Describe the bug
When feature flag is enabled, and when Number filter is marked as a required but only the default value has been set, it causes overlay to always be shown unless the editor is expanded.

Logs
N/A

To Reproduce
Requires filter feature flag enabled

  1. Ask a question > Native
  2. SELECT * FROM products WHERE products.rating = {{numberFilter}}
  3. Set filter type to be "Number"
  4. Make it required (toggle the switch)
  5. Enter the default value of 4.3
  6. Click "play" icon to run the query
  7. Notice it stays on, meaning the question is dirty
  8. If you collapse the editor, the overlay will be always present making it impossible to interact with the results
  9. Depending on the user permissions levels, some of them might not even have the option to expand the editor

Expected behavior
Running the query should not put question in a "dirty" state and the overlay should not interfere with the results when the editor is collapsed.

Screenshots

Information about your Metabase Installation:

You can get this information by going to Admin -> Troubleshooting.
local dev, x.40.0-snapshot, master, 2d890cb

Severity
P2?

@flamber flamber added .Regression Bugs that were previously fixed and/or bugs unintentionally shipped with new features. Priority:P2 Average run of the mill bug Querying/Native The SQL/native query editor Querying/Parameters & Variables Filter widgets, field filters, variables etc. and removed .Needs Triage labels Jun 29, 2021
@flamber
Copy link
Contributor

flamber commented Jun 29, 2021

Very related to #16739 - and historically to #15981.

nemanjaglumac added a commit that referenced this issue Jun 29, 2021
* Add initial set of e2e tests around sql basic filter types

- Reproduces #16811

* Add new `filters` e2e group to the CI
@nemanjaglumac nemanjaglumac added the .Reproduced Issues reproduced in test (usually Cypress) label Jun 29, 2021
kulyk added a commit that referenced this issue Jul 1, 2021
kulyk added a commit that referenced this issue Jul 1, 2021
)

* Enable #16739 repro

* Fix isResultDirty selector when filter is empty

* Enable repro for #16811
@flamber flamber added this to the 0.40 milestone Jul 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Priority:P2 Average run of the mill bug Querying/Native The SQL/native query editor Querying/Parameters & Variables Filter widgets, field filters, variables etc. .Regression Bugs that were previously fixed and/or bugs unintentionally shipped with new features. .Reproduced Issues reproduced in test (usually Cypress) Type:Bug Product defects
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants