fix: dashboard cache invalid join query#11369
Merged
Merged
Conversation
Codecov Report
@@ Coverage Diff @@
## master #11369 +/- ##
==========================================
- Coverage 65.77% 58.58% -7.19%
==========================================
Files 838 800 -38
Lines 39841 38513 -1328
Branches 3655 3443 -212
==========================================
- Hits 26206 22564 -3642
- Misses 13534 15779 +2245
- Partials 101 170 +69
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
villebro
reviewed
Oct 21, 2020
Comment on lines
+317
to
+318
| (Slice.id == dashboard_slices.c.slice_id) | ||
| & (Slice.datasource_id == datasource_id), |
Member
There was a problem hiding this comment.
nit: I think this could be expressed as and_(Slice.id == dashboard_slices.c.slice_id, Slice.datasource_id == datasource_id)
Member
Author
There was a problem hiding this comment.
I don't know, I kind of like the bit operator better..
auxten
pushed a commit
to auxten/incubator-superset
that referenced
this pull request
Nov 20, 2020
* bugfix: dashboard cache invalid join query * Use engine instead of session
qfcwell
pushed a commit
to qfcwell/superset
that referenced
this pull request
May 12, 2026
* bugfix: dashboard cache invalid join query * Use engine instead of session
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
SUMMARY
This fixes a bug where when
DASHBOARD_CACHEfeature flag is enabled, saving datasource will become too slow and sometimes generate the following error:This is because of a wrong join condition where I thought multiple join conditions can be passed to SQLAlchemy's join as consecutive positional arguments, when it's actually expecting only one positional argument for the join conditions.
Also fixes a typo that has made editing datasource unable to update the dashboard cache.
cc @graceguo-supercat @serenajiang
BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
N/A
TEST PLAN
DASHBOARD_CACHEADDITIONAL INFORMATION