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(dashboard): check dashboard id before calling redux methods #15921

Merged
merged 2 commits into from Jul 28, 2021

Conversation

suddjian
Copy link
Member

@suddjian suddjian commented Jul 28, 2021

SUMMARY

Fixes an issue caused by dashboards using UNSAFE_componentWillReceiveProps to make changes in redux. When switching dashboards via SPA, this check doesn't work. Need to check the dashboard id.

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

TESTING INSTRUCTIONS

Go to the Birth Names dashboard, then navigate to the World Health dashboard. A warning toast should not pop up.

ADDITIONAL INFORMATION

  • Has associated issue:
  • Changes UI
  • Includes DB Migration (follow approval process in SIP-59)
    • Migration is atomic, supports rollback & is backwards-compatible
    • Confirm DB migration upgrade and downgrade tested
    • Runtime estimates and downtime expectations provided
  • Introduces new feature or API
  • Removes existing feature or API

@suddjian suddjian force-pushed the fix/dashboard-props-checking branch from e7b0ea1 to 8b92971 Compare July 28, 2021 01:04
@codecov
Copy link

codecov bot commented Jul 28, 2021

Codecov Report

Merging #15921 (8b92971) into master (2ce676d) will increase coverage by 0.07%.
The diff coverage is 50.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #15921      +/-   ##
==========================================
+ Coverage   76.91%   76.98%   +0.07%     
==========================================
  Files         986      986              
  Lines       51993    51995       +2     
  Branches     7090     7091       +1     
==========================================
+ Hits        39988    40030      +42     
+ Misses      11779    11739      -40     
  Partials      226      226              
Flag Coverage Δ
hive 81.14% <ø> (ø)
javascript 71.69% <50.00%> (-0.01%) ⬇️
mysql 81.39% <ø> (ø)
postgres 81.42% <ø> (ø)
presto 81.16% <ø> (?)
python 81.95% <ø> (+0.15%) ⬆️
sqlite 81.05% <ø> (ø)

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

Impacted Files Coverage Δ
...et-frontend/src/dashboard/components/Dashboard.jsx 78.84% <50.00%> (-0.57%) ⬇️
superset/models/core.py 89.87% <0.00%> (+0.25%) ⬆️
superset/connectors/sqla/models.py 89.95% <0.00%> (+1.40%) ⬆️
superset/db_engine_specs/presto.py 90.37% <0.00%> (+5.85%) ⬆️

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 2ce676d...8b92971. Read the comment docs.

@rusackas
Copy link
Member

Thanks for the quick diagnostic and fix!

@suddjian suddjian merged commit ac9c137 into master Jul 28, 2021
opus-42 pushed a commit to opus-42/incubator-superset that referenced this pull request Nov 14, 2021
…he#15921)

* check dashboard id before calling redux methods

* comment
cccs-RyanS pushed a commit to CybercentreCanada/superset that referenced this pull request Dec 17, 2021
…he#15921)

* check dashboard id before calling redux methods

* comment
QAlexBall pushed a commit to QAlexBall/superset that referenced this pull request Dec 29, 2021
…he#15921)

* check dashboard id before calling redux methods

* comment
cccs-rc pushed a commit to CybercentreCanada/superset that referenced this pull request Mar 6, 2024
…he#15921)

* check dashboard id before calling redux methods

* comment
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 1.3.0 labels Mar 13, 2024
@mistercrunch mistercrunch deleted the fix/dashboard-props-checking branch March 26, 2024 16:11
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 preset-io size/XS 🚢 1.3.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants