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

fix(Scope): Correct issue where filters appear out of scope when sort is unchecked. #32115

Open
wants to merge 16 commits into
base: master
Choose a base branch
from

Conversation

LevisNgigi
Copy link
Contributor

@LevisNgigi LevisNgigi commented Feb 3, 2025

SUMMARY

This fixes a bug where updating a native filter will mark filters as out of scope even though they aren't.

Fixes #32014 and #32123

Fix(Scope): Correct issue where filters appear out of scope when sort is unchecked

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

TESTING INSTRUCTIONS

1.Go to the video games dashboard
2.Edit the Genre filter by saying sort value filters by count
3.Save the filter
4.Edit the filter again and uncheck filter values and save
5.When we weren't sorted all filters were in scope, after we sorted filters are still in scope, now when you uncheck, sort filters should still be in scope.

ADDITIONAL INFORMATION

@github-actions github-actions bot added the api Related to the REST API label Feb 3, 2025
@dosubot dosubot bot added the dashboard:native-filters Related to the native filters of the Dashboard label Feb 3, 2025
Copy link

@korbit-ai korbit-ai bot left a comment

Choose a reason for hiding this comment

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

Review by Korbit AI

Korbit automatically attempts to detect when you fix issues in new commits.
Category Issue Fix Detected
Functionality Incorrect Filter Scope Logic ▹ view
Security Removal of User-based Access Control Filter ▹ view

Need a new review? Comment /korbit-review on this PR and I'll review your latest changes.

Korbit Guide: Usage and Customization

Interacting with Korbit

  • You can manually ask Korbit to review your PR using the /korbit-review command in a comment at the root of your PR.
  • You can ask Korbit to generate a new PR description using the /korbit-generate-pr-description command in any comment on your PR.
  • Too many Korbit comments? I can resolve all my comment threads if you use the /korbit-resolve command in any comment on your PR.
  • Chat with Korbit on issues we post by tagging @korbit-ai in your reply.
  • Help train Korbit to improve your reviews by giving a 👍 or 👎 on the comments Korbit posts.

Customizing Korbit

  • Check out our docs on how you can make Korbit work best for you and your team.
  • Customize Korbit for your organization through the Korbit Console.

Feedback and Support

superset/queries/saved_queries/filters.py Outdated Show resolved Hide resolved
Copy link

codecov bot commented Feb 3, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 65.54%. Comparing base (76d897e) to head (a926e02).
Report is 1423 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master   #32115      +/-   ##
==========================================
+ Coverage   60.48%   65.54%   +5.05%     
==========================================
  Files        1931      545    -1386     
  Lines       76236    38919   -37317     
  Branches     8568        0    -8568     
==========================================
- Hits        46114    25510   -20604     
+ Misses      28017    13409   -14608     
+ Partials     2105        0    -2105     
Flag Coverage Δ
javascript ?

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

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

@pull-request-size pull-request-size bot added size/XS and removed size/S labels Feb 3, 2025
@github-actions github-actions bot removed the api Related to the REST API label Feb 3, 2025
@LevisNgigi LevisNgigi changed the title Fix(Scope): Correct issue where filters disappear when sort is unchecked. fix(Scope): Correct issue where filters disappear when sort is unchecked. Feb 3, 2025
@LevisNgigi LevisNgigi changed the title fix(Scope): Correct issue where filters disappear when sort is unchecked. fix(Scope): Correct issue where filters appear out of scope when sort is unchecked. Feb 3, 2025
@michael-s-molina michael-s-molina linked an issue Feb 3, 2025 that may be closed by this pull request
3 tasks
@geido geido added preset:bounty Issues that have been selected by Preset and have a bounty attached. hold! On hold labels Feb 5, 2025
@pull-request-size pull-request-size bot added size/L and removed size/S labels Feb 7, 2025
Copy link
Member

@Antonio-RiveroMartnez Antonio-RiveroMartnez left a comment

Choose a reason for hiding this comment

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

lgtm

@michael-s-molina
Copy link
Member

@geido Can we merge this?

Copy link
Contributor

@kgabryje Processing your ephemeral environment request here. Action: up.

Copy link
Contributor

@kgabryje Ephemeral environment spinning up at http://35.94.61.135:8080. Credentials are 'admin'/'admin'. Please allow several minutes for bootstrapping and startup.

@Antonio-RiveroMartnez Antonio-RiveroMartnez dismissed their stale review February 10, 2025 16:01

Failing on ephemeral

Copy link
Member

@kgabryje kgabryje left a comment

Choose a reason for hiding this comment

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

Screen.Recording.2025-02-10.at.17.02.20.mov

The scoping doesn't seem to work with tabs - the range filter always appears in scope, even though it should only be active when tab2 is active

@LevisNgigi
Copy link
Contributor Author

Screen.Recording.2025-02-10.at.17.02.20.mov
The scoping doesn't seem to work with tabs - the range filter always appears in scope, even though it should only be active when tab2 is active

Thanks for this,fixed it.

@LevisNgigi LevisNgigi requested a review from kgabryje February 10, 2025 21:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dashboard:native-filters Related to the native filters of the Dashboard hold! On hold preset:bounty Issues that have been selected by Preset and have a bounty attached. size/L testenv-up
Projects
None yet
5 participants