-
Notifications
You must be signed in to change notification settings - Fork 13.8k
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: [sc-54864] Adds safety check to provide near term fix to save query #21034
fix: [sc-54864] Adds safety check to provide near term fix to save query #21034
Conversation
… saving There is an error when casting the columns array to String() for saving queries where the objects in the array are missing the toString method. This is a near term rapid patch to fix workflow in production which will have a follow up to identify root cause.
superset-frontend/packages/superset-ui-core/src/connection/callApi/callApi.ts
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, with one small console typo.
This fixes issue caught by unit test where the if statement was using a truthy check where it should be explicitly checking for value of undefined
/testenv up |
@jinghua-qa Ephemeral environment spinning up at http://54.214.187.229:8080. Credentials are |
Codecov Report
@@ Coverage Diff @@
## master #21034 +/- ##
==========================================
- Coverage 66.34% 66.26% -0.08%
==========================================
Files 1767 1769 +2
Lines 67358 67475 +117
Branches 7147 7171 +24
==========================================
+ Hits 44686 44711 +25
- Misses 20844 20933 +89
- Partials 1828 1831 +3
Flags with carried forward coverage won't be shown. Click here to find out more.
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
Ephemeral environment shutdown and build artifacts deleted. |
…ery (apache#21034) * [sc-54864] Adds safety check to provide near term fix for Queries not saving There is an error when casting the columns array to String() for saving queries where the objects in the array are missing the toString method. This is a near term rapid patch to fix workflow in production which will have a follow up to identify root cause. * fix typo Co-authored-by: Elizabeth Thompson <eschutho@gmail.com> * Adjusted chekc to be explicit for undefined instead of truthy This fixes issue caught by unit test where the if statement was using a truthy check where it should be explicitly checking for value of undefined * Adds new unit test to get 100% coverage for callApi Co-authored-by: Elizabeth Thompson <eschutho@gmail.com> (cherry picked from commit ab6ec89)
Adds safety check to provide near term fix to save query
SUMMARY
There is an error when casting the columns array to String() for saving queries where the objects in the array are missing the toString method. This is a near term rapid patch to fix workflow in production which will have a follow up to identify root cause.
BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
TESTING INSTRUCTIONS
Repro steps:
1, go to sql lab and run query (click "RUN")
2, save query using save split button
3, observe confirmation msg
4, go to saved query list and look for save query
Expect:
user can save query using save split button
Actual:
user saw query can not be saved msg and the query did not show in save query list
ADDITIONAL INFORMATION