elukey opened a new issue #9855: URL: https://github.com/apache/incubator-superset/issues/9855
I am testing 0.36 with two backported patches of mine: - https://github.com/apache/incubator-superset/commit/a52b9ee8fffb123d98e111c26ca82714deae49de - https://github.com/apache/incubator-superset/commit/5ab5457522a141139958a52c88e021c3e5a50ad7 I noticed that when using FilterBox with Druid datasources (so not via SqlAlchemy) if the time range returns an empty result then I see: ``` An error occurred while rendering the visualization: TypeError: Cannot read property 'map' of undefined ``` That expands to: ``` in q in n in div in me in Se in je in div in div in C in Re in Connect(Re) in div in r in div in t in div in t in Uncontrolled(t) in ForwardRef in div in bn in div in div in div in nr in Connect(nr) in div in i in ir ``` ### Expected results A nice "no results" message that is less confusing. ### Actual results What written above, that is not super easy to decrypt for users. We are currently migrating to SQLAlchemy-based Druid tables, but the migration will be long so it would be great to get a patch for this in the meantime :) #### Screenshots  #### How to reproduce the bug 1. Select a FilterBox with a Druid Datasource (not one defined via SQLAlchemy, but via the "old" way) 2. Select one filter that you want. 3. Run a query with a time range that is not available in Druid segments. 4. See error ``` ### Environment (please complete the following information): - superset version: `0.36` (plus two commits mentioned above) - python version: `3.7` - node.js version: `10.19` - npm version: `5.8` ### Checklist Make sure these boxes are checked before submitting your issue - thank you! - [x] I have checked the superset logs for python stacktraces and included it here as text if there are any. - [x] I have reproduced the issue with at least the latest released version of superset. - [x] I have checked the issue tracker for the same issue and I haven't found one similar. ### Additional context On Superset 0.35.2 the same workflow leads to another error: ``` Traceback (most recent call last) File "/srv/deployment/analytics/superset/venv/lib/python3.7/site-packages/superset/views/base.py", line 120, in wraps return f(self, *args, **kwargs) File "/srv/deployment/analytics/superset/venv/lib/python3.7/site-packages/superset/utils/decorators.py", line 69, in wrapper return f(*args, **kwargs) File "/srv/deployment/analytics/superset/venv/lib/python3.7/site-packages/superset/views/core.py", line 1092, in explore_json viz_obj, csv=csv, query=query, results=results, samples=samples File "/srv/deployment/analytics/superset/venv/lib/python3.7/site-packages/superset/views/core.py", line 1013, in generate_json payload = viz_obj.get_payload() File "/srv/deployment/analytics/superset/venv/lib/python3.7/site-packages/superset/viz.py", line 381, in get_payload payload["data"] = self.get_data(df) File "/srv/deployment/analytics/superset/venv/lib/python3.7/site-packages/superset/viz.py", line 1832, in get_data utils.get_metric_name(metric), ascending=flt.get("asc") File "/srv/deployment/analytics/superset/venv/lib/python3.7/site-packages/pandas/core/frame.py", line 4719, in sort_values k = self._get_label_or_level_values(by, axis=axis) File "/srv/deployment/analytics/superset/venv/lib/python3.7/site-packages/pandas/core/generic.py", line 1706, in _get_label_or_level_values raise KeyError(key) KeyError ``` So in the current Superset, the error seems to be in JS, meanwhile before was in viz.py. ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
