You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2021/09/14 11:16:42 UTC
[GitHub] [superset] villebro opened a new pull request #16699: fix(explore): only refresh data panel on relevant changes
villebro opened a new pull request #16699:
URL: https://github.com/apache/superset/pull/16699
### SUMMARY
Every time control state is updated on the Explore view, the data panel requests new data, even when the changes are known not to affect the chart data (`renderTrigger` property set to true). This PR changes `ExploreChartPanel` to only refresh the `queryFormData` that's used by DataTablesPane` if the `triggerRender` is not true. This only happens when the chart needs to be rerendered without rerequesting data.
### AFTER
https://user-images.githubusercontent.com/33317356/133247836-fb2b540a-824e-4521-93a6-c5c70852ef4c.mp4
### BEFORE
https://user-images.githubusercontent.com/33317356/133246743-4139d0f7-40ac-47d1-84b0-bf3aa1139713.mp4
### TESTING INSTRUCTIONS
<!--- Required! What steps can be taken to manually verify the changes? -->
### ADDITIONAL INFORMATION
<!--- Check any relevant boxes with "x" -->
<!--- HINT: Include "Fixes #nnn" if you are fixing an existing issue -->
- [ ] Has associated issue:
- [ ] Required feature flags:
- [ ] Changes UI
- [ ] Includes DB Migration (follow approval process in [SIP-59](https://github.com/apache/superset/issues/13351))
- [ ] 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
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] kgabryje commented on a change in pull request #16699: fix(explore): only refresh data panel on relevant changes
Posted by GitBox <gi...@apache.org>.
kgabryje commented on a change in pull request #16699:
URL: https://github.com/apache/superset/pull/16699#discussion_r708197611
##########
File path: superset-frontend/src/explore/components/ExploreChartPanel.jsx
##########
@@ -257,6 +258,16 @@ const ExploreChartPanel = props => {
[chartPanelRef, renderChart],
);
+ const [queryFormData, setQueryFormData] = useState(
+ props.chart.latestQueryFormData,
+ );
+
+ useEffect(() => {
+ if (!props.triggerRender) {
+ setQueryFormData(props.chart.latestQueryFormData);
+ }
+ }, [props.chart.latestQueryFormData]);
Review comment:
Got it, thanks for explanation! In that case, can we add eslint suppress warning? I think it's time we started getting rid of those errors wherever possible π (though actually that's up for debate if we should suppress those warnings...)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] villebro commented on a change in pull request #16699: fix(explore): only refresh data panel on relevant changes
Posted by GitBox <gi...@apache.org>.
villebro commented on a change in pull request #16699:
URL: https://github.com/apache/superset/pull/16699#discussion_r708175082
##########
File path: superset-frontend/src/explore/components/ExploreChartPanel.jsx
##########
@@ -257,6 +258,16 @@ const ExploreChartPanel = props => {
[chartPanelRef, renderChart],
);
+ const [queryFormData, setQueryFormData] = useState(
+ props.chart.latestQueryFormData,
+ );
+
+ useEffect(() => {
+ if (!props.triggerRender) {
+ setQueryFormData(props.chart.latestQueryFormData);
+ }
+ }, [props.chart.latestQueryFormData]);
Review comment:
Actually, this causes a rerender when making changes to controls that don't have `renderTrigger` set to `true` (a rerendering should only trigger after running the query):
https://user-images.githubusercontent.com/33317356/133249851-49e9ceb3-0865-4172-b915-0c2c2b0c5bdc.mp4
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov[bot] edited a comment on pull request #16699: fix(explore): only refresh data panel on relevant changes
Posted by GitBox <gi...@apache.org>.
codecov[bot] edited a comment on pull request #16699:
URL: https://github.com/apache/superset/pull/16699#issuecomment-919072318
# [Codecov](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
> Merging [#16699](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (7a411fa) into [master](https://codecov.io/gh/apache/superset/commit/5ac8ac0e6c7939ddd42fbaefd63c64f4ec2ee045?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (5ac8ac0) will **decrease** coverage by `0.00%`.
> The diff coverage is `20.00%`.
> :exclamation: Current head 7a411fa differs from pull request most recent head ad73d31. Consider uploading reports for the commit ad73d31 to get more accurate results
[![Impacted file tree graph](https://codecov.io/gh/apache/superset/pull/16699/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
```diff
@@ Coverage Diff @@
## master #16699 +/- ##
==========================================
- Coverage 76.93% 76.93% -0.01%
==========================================
Files 1007 1007
Lines 54112 54117 +5
Branches 7346 7348 +2
==========================================
+ Hits 41633 41634 +1
- Misses 12239 12243 +4
Partials 240 240
```
| Flag | Coverage Ξ | |
|---|---|---|
| javascript | `71.24% <20.00%> (-0.01%)` | :arrow_down: |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Ξ | |
|---|---|---|
| [...ntend/src/explore/components/ExploreChartPanel.jsx](https://codecov.io/gh/apache/superset/pull/16699/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvY29tcG9uZW50cy9FeHBsb3JlQ2hhcnRQYW5lbC5qc3g=) | `14.28% <0.00%> (-0.72%)` | :arrow_down: |
| [...nd/src/explore/components/DataTablesPane/index.tsx](https://codecov.io/gh/apache/superset/pull/16699/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvY29tcG9uZW50cy9EYXRhVGFibGVzUGFuZS9pbmRleC50c3g=) | `75.49% <100.00%> (+0.24%)` | :arrow_up: |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
> `Ξ = absolute <relative> (impact)`, `ΓΈ = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Last update [5ac8ac0...ad73d31](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] villebro merged pull request #16699: fix(explore): only refresh data panel on relevant changes
Posted by GitBox <gi...@apache.org>.
villebro merged pull request #16699:
URL: https://github.com/apache/superset/pull/16699
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] villebro commented on a change in pull request #16699: fix(explore): only refresh data panel on relevant changes
Posted by GitBox <gi...@apache.org>.
villebro commented on a change in pull request #16699:
URL: https://github.com/apache/superset/pull/16699#discussion_r708170089
##########
File path: superset-frontend/src/explore/components/ExploreChartPanel.jsx
##########
@@ -257,6 +258,16 @@ const ExploreChartPanel = props => {
[chartPanelRef, renderChart],
);
+ const [queryFormData, setQueryFormData] = useState(
+ props.chart.latestQueryFormData,
+ );
+
+ useEffect(() => {
+ if (!props.triggerRender) {
+ setQueryFormData(props.chart.latestQueryFormData);
+ }
+ }, [props.chart.latestQueryFormData]);
Review comment:
Right you are - adding it!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] villebro commented on a change in pull request #16699: fix(explore): only refresh data panel on relevant changes
Posted by GitBox <gi...@apache.org>.
villebro commented on a change in pull request #16699:
URL: https://github.com/apache/superset/pull/16699#discussion_r708175082
##########
File path: superset-frontend/src/explore/components/ExploreChartPanel.jsx
##########
@@ -257,6 +258,16 @@ const ExploreChartPanel = props => {
[chartPanelRef, renderChart],
);
+ const [queryFormData, setQueryFormData] = useState(
+ props.chart.latestQueryFormData,
+ );
+
+ useEffect(() => {
+ if (!props.triggerRender) {
+ setQueryFormData(props.chart.latestQueryFormData);
+ }
+ }, [props.chart.latestQueryFormData]);
Review comment:
Actually, this causes a rerender when making changes to controls that don't have `renderTrigger` set to `true`:
https://user-images.githubusercontent.com/33317356/133249851-49e9ceb3-0865-4172-b915-0c2c2b0c5bdc.mp4
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] kgabryje commented on a change in pull request #16699: fix(explore): only refresh data panel on relevant changes
Posted by GitBox <gi...@apache.org>.
kgabryje commented on a change in pull request #16699:
URL: https://github.com/apache/superset/pull/16699#discussion_r708169130
##########
File path: superset-frontend/src/explore/components/ExploreChartPanel.jsx
##########
@@ -257,6 +258,16 @@ const ExploreChartPanel = props => {
[chartPanelRef, renderChart],
);
+ const [queryFormData, setQueryFormData] = useState(
+ props.chart.latestQueryFormData,
+ );
+
+ useEffect(() => {
+ if (!props.triggerRender) {
+ setQueryFormData(props.chart.latestQueryFormData);
+ }
+ }, [props.chart.latestQueryFormData]);
Review comment:
that would run `useEffect` function, but we'd exit at `if` check, right?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] villebro commented on a change in pull request #16699: fix(explore): only refresh data panel on relevant changes
Posted by GitBox <gi...@apache.org>.
villebro commented on a change in pull request #16699:
URL: https://github.com/apache/superset/pull/16699#discussion_r708204239
##########
File path: superset-frontend/src/explore/components/ExploreChartPanel.jsx
##########
@@ -257,6 +258,16 @@ const ExploreChartPanel = props => {
[chartPanelRef, renderChart],
);
+ const [queryFormData, setQueryFormData] = useState(
+ props.chart.latestQueryFormData,
+ );
+
+ useEffect(() => {
+ if (!props.triggerRender) {
+ setQueryFormData(props.chart.latestQueryFormData);
+ }
+ }, [props.chart.latestQueryFormData]);
Review comment:
I added a comment + supressed the warning π
##########
File path: superset-frontend/src/explore/components/ExploreChartPanel.jsx
##########
@@ -257,6 +258,16 @@ const ExploreChartPanel = props => {
[chartPanelRef, renderChart],
);
+ const [queryFormData, setQueryFormData] = useState(
+ props.chart.latestQueryFormData,
+ );
+
+ useEffect(() => {
+ if (!props.triggerRender) {
+ setQueryFormData(props.chart.latestQueryFormData);
+ }
+ }, [props.chart.latestQueryFormData]);
Review comment:
I added a comment + suppressed the warning π
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] villebro commented on a change in pull request #16699: fix(explore): only refresh data panel on relevant changes
Posted by GitBox <gi...@apache.org>.
villebro commented on a change in pull request #16699:
URL: https://github.com/apache/superset/pull/16699#discussion_r708167914
##########
File path: superset-frontend/src/explore/components/ExploreChartPanel.jsx
##########
@@ -257,6 +258,16 @@ const ExploreChartPanel = props => {
[chartPanelRef, renderChart],
);
+ const [queryFormData, setQueryFormData] = useState(
+ props.chart.latestQueryFormData,
+ );
+
+ useEffect(() => {
+ if (!props.triggerRender) {
+ setQueryFormData(props.chart.latestQueryFormData);
+ }
+ }, [props.chart.latestQueryFormData]);
Review comment:
No - that would cause it to trigger when we change controls whose `renderTrigger` prop is set to `true`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov[bot] edited a comment on pull request #16699: fix(explore): only refresh data panel on relevant changes
Posted by GitBox <gi...@apache.org>.
codecov[bot] edited a comment on pull request #16699:
URL: https://github.com/apache/superset/pull/16699#issuecomment-919072318
# [Codecov](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
> Merging [#16699](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (976653d) into [master](https://codecov.io/gh/apache/superset/commit/5ac8ac0e6c7939ddd42fbaefd63c64f4ec2ee045?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (5ac8ac0) will **decrease** coverage by `0.08%`.
> The diff coverage is `20.00%`.
> :exclamation: Current head 976653d differs from pull request most recent head ad73d31. Consider uploading reports for the commit ad73d31 to get more accurate results
[![Impacted file tree graph](https://codecov.io/gh/apache/superset/pull/16699/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
```diff
@@ Coverage Diff @@
## master #16699 +/- ##
==========================================
- Coverage 76.93% 76.85% -0.09%
==========================================
Files 1007 1007
Lines 54112 54117 +5
Branches 7346 7348 +2
==========================================
- Hits 41633 41593 -40
- Misses 12239 12284 +45
Partials 240 240
```
| Flag | Coverage Ξ | |
|---|---|---|
| javascript | `71.24% <20.00%> (-0.01%)` | :arrow_down: |
| presto | `?` | |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Ξ | |
|---|---|---|
| [...ntend/src/explore/components/ExploreChartPanel.jsx](https://codecov.io/gh/apache/superset/pull/16699/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvY29tcG9uZW50cy9FeHBsb3JlQ2hhcnRQYW5lbC5qc3g=) | `14.28% <0.00%> (-0.72%)` | :arrow_down: |
| [...nd/src/explore/components/DataTablesPane/index.tsx](https://codecov.io/gh/apache/superset/pull/16699/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvY29tcG9uZW50cy9EYXRhVGFibGVzUGFuZS9pbmRleC50c3g=) | `75.49% <100.00%> (+0.24%)` | :arrow_up: |
| [superset/db\_engine\_specs/presto.py](https://codecov.io/gh/apache/superset/pull/16699/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL3ByZXN0by5weQ==) | `84.51% <0.00%> (-5.86%)` | :arrow_down: |
| [superset/connectors/sqla/models.py](https://codecov.io/gh/apache/superset/pull/16699/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQvY29ubmVjdG9ycy9zcWxhL21vZGVscy5weQ==) | `88.28% <0.00%> (-1.43%)` | :arrow_down: |
| [superset/models/core.py](https://codecov.io/gh/apache/superset/pull/16699/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQvbW9kZWxzL2NvcmUucHk=) | `89.14% <0.00%> (-0.26%)` | :arrow_down: |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
> `Ξ = absolute <relative> (impact)`, `ΓΈ = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Last update [5ac8ac0...ad73d31](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov[bot] commented on pull request #16699: fix(explore): only refresh data panel on relevant changes
Posted by GitBox <gi...@apache.org>.
codecov[bot] commented on pull request #16699:
URL: https://github.com/apache/superset/pull/16699#issuecomment-919072318
# [Codecov](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
> Merging [#16699](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (976653d) into [master](https://codecov.io/gh/apache/superset/commit/5ac8ac0e6c7939ddd42fbaefd63c64f4ec2ee045?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (5ac8ac0) will **decrease** coverage by `0.00%`.
> The diff coverage is `20.00%`.
> :exclamation: Current head 976653d differs from pull request most recent head 2002f9e. Consider uploading reports for the commit 2002f9e to get more accurate results
[![Impacted file tree graph](https://codecov.io/gh/apache/superset/pull/16699/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
```diff
@@ Coverage Diff @@
## master #16699 +/- ##
==========================================
- Coverage 76.86% 76.85% -0.01%
==========================================
Files 1007 1007
Lines 54112 54117 +5
Branches 7346 7348 +2
==========================================
+ Hits 41592 41593 +1
- Misses 12280 12284 +4
Partials 240 240
```
| Flag | Coverage Ξ | |
|---|---|---|
| javascript | `71.24% <20.00%> (-0.01%)` | :arrow_down: |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Ξ | |
|---|---|---|
| [...ntend/src/explore/components/ExploreChartPanel.jsx](https://codecov.io/gh/apache/superset/pull/16699/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvY29tcG9uZW50cy9FeHBsb3JlQ2hhcnRQYW5lbC5qc3g=) | `14.28% <0.00%> (-0.72%)` | :arrow_down: |
| [...nd/src/explore/components/DataTablesPane/index.tsx](https://codecov.io/gh/apache/superset/pull/16699/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvY29tcG9uZW50cy9EYXRhVGFibGVzUGFuZS9pbmRleC50c3g=) | `75.49% <100.00%> (+0.24%)` | :arrow_up: |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
> `Ξ = absolute <relative> (impact)`, `ΓΈ = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Last update [5ac8ac0...2002f9e](https://codecov.io/gh/apache/superset/pull/16699?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] kgabryje commented on a change in pull request #16699: fix(explore): only refresh data panel on relevant changes
Posted by GitBox <gi...@apache.org>.
kgabryje commented on a change in pull request #16699:
URL: https://github.com/apache/superset/pull/16699#discussion_r708197611
##########
File path: superset-frontend/src/explore/components/ExploreChartPanel.jsx
##########
@@ -257,6 +258,16 @@ const ExploreChartPanel = props => {
[chartPanelRef, renderChart],
);
+ const [queryFormData, setQueryFormData] = useState(
+ props.chart.latestQueryFormData,
+ );
+
+ useEffect(() => {
+ if (!props.triggerRender) {
+ setQueryFormData(props.chart.latestQueryFormData);
+ }
+ }, [props.chart.latestQueryFormData]);
Review comment:
Got it, thanks for explanation! In that case, can we add eslint suppress warning? I think it's time we started getting rid of those errors wherever possible π
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] kgabryje commented on a change in pull request #16699: fix(explore): only refresh data panel on relevant changes
Posted by GitBox <gi...@apache.org>.
kgabryje commented on a change in pull request #16699:
URL: https://github.com/apache/superset/pull/16699#discussion_r708166951
##########
File path: superset-frontend/src/explore/components/ExploreChartPanel.jsx
##########
@@ -257,6 +258,16 @@ const ExploreChartPanel = props => {
[chartPanelRef, renderChart],
);
+ const [queryFormData, setQueryFormData] = useState(
+ props.chart.latestQueryFormData,
+ );
+
+ useEffect(() => {
+ if (!props.triggerRender) {
+ setQueryFormData(props.chart.latestQueryFormData);
+ }
+ }, [props.chart.latestQueryFormData]);
Review comment:
Should we include `triggerRender` in deps array?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org