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: save tabs when saving the query bug #12607

Merged
merged 3 commits into from Jan 19, 2021
Merged

Conversation

hughhhh
Copy link
Member

@hughhhh hughhhh commented Jan 19, 2021

SUMMARY

Fix small bug with updating the query tab name on query save. This bug only appears specifically when SQLLAB_BACKEND_PERSISTENCE is True.

Reference for #12561

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

saved_tabs

TEST PLAN

  1. Make sure SQLLAB_BACKEND_PERSISTENCE is True in superset_config.py
  2. Goto sqllab
  3. Create a new tab
  4. Write a query and save
  5. Refresh the page

ADDITIONAL INFORMATION

  • Has associated issue:
  • Changes UI
  • Requires DB Migration.
  • Confirm DB Migration upgrade and downgrade tested.
  • Introduces new feature or API
  • Removes existing feature or API

@hughhhh hughhhh changed the title save tabs when saving the query fix: save tabs when saving the query bug Jan 19, 2021
Copy link
Member

@betodealmeida betodealmeida left a comment

Choose a reason for hiding this comment

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

LGTM

})
.then(() => {
dispatch(addSuccessToast(t('Your query was updated')));
dispatch(queryEditorSetTitle(query, query.title));
Copy link
Member

Choose a reason for hiding this comment

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

This line is the only difference, right?

Copy link
Member Author

Choose a reason for hiding this comment

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

yup, but moved it to the bottom of the page

@codecov-io
Copy link

codecov-io commented Jan 19, 2021

Codecov Report

Merging #12607 (4ffdc19) into master (3f3a2ad) will decrease coverage by 3.66%.
The diff coverage is 43.75%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #12607      +/-   ##
==========================================
- Coverage   66.72%   63.06%   -3.67%     
==========================================
  Files        1014     1015       +1     
  Lines       49612    50929    +1317     
  Branches     4839     4839              
==========================================
- Hits        33106    32117     -989     
- Misses      16383    18614    +2231     
- Partials      123      198      +75     
Flag Coverage Δ
cypress ?
javascript 60.74% <43.75%> (+0.01%) ⬆️
python 64.51% <ø> (+0.59%) ⬆️

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

Impacted Files Coverage Δ
superset-frontend/src/SqlLab/actions/sqlLab.js 57.53% <43.75%> (-4.43%) ⬇️
superset-frontend/src/SqlLab/App.jsx 0.00% <0.00%> (-100.00%) ⬇️
superset-frontend/src/explore/App.jsx 0.00% <0.00%> (-100.00%) ⬇️
superset-frontend/src/dashboard/App.jsx 0.00% <0.00%> (-100.00%) ⬇️
superset-frontend/src/chart/ChartContainer.jsx 0.00% <0.00%> (-100.00%) ⬇️
superset-frontend/src/explore/reducers/index.js 0.00% <0.00%> (-100.00%) ⬇️
...et-frontend/src/dashboard/containers/Dashboard.jsx 0.00% <0.00%> (-100.00%) ⬇️
...et-frontend/src/filters/components/Select/types.ts 0.00% <0.00%> (-100.00%) ⬇️
...t-frontend/src/dashboard/containers/SliceAdder.jsx 0.00% <0.00%> (-100.00%) ⬇️
...t-frontend/src/explore/reducers/getInitialState.js 0.00% <0.00%> (-100.00%) ⬇️
... and 213 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3f3a2ad...4ffdc19. Read the comment docs.

@hughhhh hughhhh merged commit 68fe220 into master Jan 19, 2021
@hughhhh hughhhh deleted the hugh/sql-lab-saved-tabs branch January 19, 2021 19:27
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 1.2.0 labels Mar 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels size/L 🚢 1.2.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants