-
Notifications
You must be signed in to change notification settings - Fork 13.9k
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
Download button, share button, and url shortener button stay not in sync with visualization while editing #1189
Labels
!deprecated-label:bug
Deprecated label - Use #bug instead
obsolete
No longer relevant issue or applicable code
Comments
prokh
changed the title
Download button, share button, and url shortener button are stay not in sync with visualization while editing
Download button, share button, and url shortener button stay not in sync with visualization while editing
Sep 24, 2016
thanks for this report @prokh , i'll look into. |
kristw
added
!deprecated-label:bug
Deprecated label - Use #bug instead
obsolete
No longer relevant issue or applicable code
labels
Jan 23, 2019
This was referenced Jul 17, 2020
Open
zhaoyongjie
pushed a commit
to zhaoyongjie/incubator-superset
that referenced
this issue
Nov 17, 2021
zhaoyongjie
pushed a commit
to zhaoyongjie/incubator-superset
that referenced
this issue
Nov 24, 2021
zhaoyongjie
pushed a commit
to zhaoyongjie/incubator-superset
that referenced
this issue
Nov 25, 2021
zhaoyongjie
pushed a commit
to zhaoyongjie/incubator-superset
that referenced
this issue
Nov 26, 2021
This was referenced Oct 19, 2022
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
!deprecated-label:bug
Deprecated label - Use #bug instead
obsolete
No longer relevant issue or applicable code
The json export button, the csv export button, the share button, and the url-shorter button are not updated when the user changes metrics, groupby, or other properties of the visualization. Thus, the user downloads or shares the wrong data. They are updated when the site is reloaded by clicking on refresh.
Steps to recreate it:
/caravel/explore/table/2/?slice_name=World's+Pop+Growth&row_limit=50000&metric=sum__SP_POP_TOTL&show_bubbles=y&entity=country_code&secondary_metric=sum__SP_POP_TOTL&viz_type=area&since=1960-01-01&json=false&until=now&datasource_id=1&metrics=sum__SP_POP_TOTL&datasource_name=birth_names&country_fieldtype=cca3&granularity=year&slice_id=11&datasource_type=table&compare_lag=10&limit=25&markup_type=markdown&compare_suffix=o10Y&where=&groupby=region .
Expected: The data uses the new "Count( )" metric.
Actual result: The data still uses the the old metric sum__SP_POP_TOTAL metric. All other values like json_endpoint, csv_endpoint, or metric in the json data still refer to the old metric. Inspecting the link in the csv/json download button reveals that the links use the old metric. Though, the SQL-Query from the query button is correct.
The same bug applies when chart parameters are changed.
Cause
The state of the page with all the parameters for metric, group by, etc. is saved in the global variable 'slice'. When the user changes params, they are updated in 'slice'. The buttons are React Components created with the property 'slice'. However, they do not listen to updates of 'slice' and keep the initial value.
The text was updated successfully, but these errors were encountered: