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(explore): drag & drop column select component triggering onChange unnecessarily #16073

Merged
merged 2 commits into from
Aug 5, 2021

Conversation

suddjian
Copy link
Member

@suddjian suddjian commented Aug 4, 2021

SUMMARY

Fixes #16016

The example had a value for the granularity_sqla field that was not found in the dataset. When that happens, the mechanism that is meant to detect changes in dataset thinks that there has been a change. The fix for this is to only begin checking for dataset changes after the first render.

AFTER

Chart appears as normal rather than requiring user to click Run.

Screen Shot 2021-08-04 at 1 48 46 PM

TESTING INSTRUCTIONS

Open the Calendar Heatmap example chart.

ADDITIONAL INFORMATION

@codecov
Copy link

codecov bot commented Aug 4, 2021

Codecov Report

Merging #16073 (ee81921) into master (4cb79e5) will decrease coverage by 0.12%.
The diff coverage is 54.05%.

❗ Current head ee81921 differs from pull request most recent head 3d8cfa7. Consider uploading reports for the commit 3d8cfa7 to get more accurate results
Impacted file tree graph

@@            Coverage Diff             @@
##           master   #16073      +/-   ##
==========================================
- Coverage   76.90%   76.77%   -0.13%     
==========================================
  Files         995      995              
  Lines       52842    52878      +36     
  Branches     6709     6720      +11     
==========================================
- Hits        40640    40599      -41     
- Misses      11976    12053      +77     
  Partials      226      226              
Flag Coverage Δ
hive 81.34% <67.44%> (+0.01%) ⬆️
javascript 71.23% <35.48%> (-0.09%) ⬇️
mysql 81.55% <67.44%> (-0.07%) ⬇️
postgres 81.58% <67.44%> (-0.07%) ⬇️
presto ?
python 81.99% <67.44%> (-0.18%) ⬇️
sqlite 81.26% <67.44%> (-0.03%) ⬇️

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

Impacted Files Coverage Δ
...ters/FiltersConfigModal/FiltersConfigForm/utils.ts 90.47% <ø> (ø)
...FormattingControl/ConditionalFormattingControl.tsx 21.66% <0.00%> (-0.75%) ⬇️
...onalFormattingControl/FormattingPopoverContent.tsx 29.26% <0.00%> (-4.07%) ⬇️
superset-frontend/src/reports/actions/reports.js 10.86% <0.00%> (ø)
...c/views/CRUD/data/database/DatabaseModal/index.tsx 44.53% <0.00%> (-0.36%) ⬇️
...set-frontend/src/views/CRUD/data/database/types.ts 100.00% <ø> (ø)
superset/examples/random_time_series.py 19.44% <ø> (ø)
superset/viz.py 56.57% <ø> (ø)
superset/commands/importers/v1/examples.py 35.44% <10.00%> (-2.59%) ⬇️
.../ReportModal/HeaderReportActionsDropdown/index.tsx 24.32% <25.00%> (-1.39%) ⬇️
... and 17 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 4cb79e5...3d8cfa7. Read the comment docs.

@kgabryje
Copy link
Member

kgabryje commented Aug 5, 2021

/testenv up FEATURE_ENABLE_EXPLORE_DRAG_AND_DROP=true

@github-actions
Copy link
Contributor

github-actions bot commented Aug 5, 2021

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

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.

1 small nit, other than that LGTM

Copy link
Member

@geido geido left a comment

Choose a reason for hiding this comment

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

LGTM!

@junlincc
Copy link
Member

junlincc commented Aug 5, 2021

seeing a missing chart in the slack dashboard. i dont think it's related, but it's probably a good idea to double check?

Screen Shot 2021-08-05 at 10 50 02 AM

@suddjian
Copy link
Member Author

suddjian commented Aug 5, 2021

missing image is unrelated, that's cdn.brandfolder.com's problem

@suddjian suddjian merged commit e6292a8 into master Aug 5, 2021
@github-actions
Copy link
Contributor

github-actions bot commented Aug 5, 2021

Ephemeral environment shutdown and build artifacts deleted.

@rosemarie-chiu
Copy link
Contributor

🏷 2021.31

@villebro villebro added the v1.3 label Aug 10, 2021
villebro pushed a commit that referenced this pull request Aug 10, 2021
… unnecessarily (#16073)

* fix(explore): avoid sync until after first render

* fix example

(cherry picked from commit e6292a8)
stevenuray pushed a commit to preset-io/superset that referenced this pull request Aug 11, 2021
… unnecessarily (apache#16073)

* fix(explore): avoid sync until after first render

* fix example

(cherry picked from commit e6292a8)
opus-42 pushed a commit to opus-42/incubator-superset that referenced this pull request Nov 14, 2021
… unnecessarily (apache#16073)

* fix(explore): avoid sync until after first render

* fix example
cccs-RyanS pushed a commit to CybercentreCanada/superset that referenced this pull request Dec 17, 2021
… unnecessarily (apache#16073)

* fix(explore): avoid sync until after first render

* fix example

(cherry picked from commit e6292a8)
QAlexBall pushed a commit to QAlexBall/superset that referenced this pull request Dec 28, 2021
… unnecessarily (apache#16073)

* fix(explore): avoid sync until after first render

* fix example
QAlexBall pushed a commit to QAlexBall/superset that referenced this pull request Dec 29, 2021
… unnecessarily (apache#16073)

* fix(explore): avoid sync until after first render

* fix example

(cherry picked from commit e6292a8)
cccs-rc pushed a commit to CybercentreCanada/superset that referenced this pull request Mar 6, 2024
… unnecessarily (apache#16073)

* fix(explore): avoid sync until after first render

* fix example

(cherry picked from commit 0a21b6a)
@mistercrunch mistercrunch added 🍒 1.3.2 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 1.4.0 labels Mar 13, 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 preset:2021.31 preset-io size/S v1.3 🍒 1.3.0 🍒 1.3.1 🍒 1.3.2 🚢 1.4.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[drag & drop][Calendar Heatmap]Example chart 'Calendar Heatmap' is not shown automatically with d&d on
7 participants