You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@superset.apache.org by gi...@git.apache.org on 2017/10/02 16:56:50 UTC

[GitHub] mistercrunch commented on a change in pull request #3504: Feature: Display the verbose name for metrics within Timeseries charts and legend.

mistercrunch commented on a change in pull request #3504: Feature: Display the verbose name for metrics within Timeseries charts and legend.
URL: https://github.com/apache/incubator-superset/pull/3504#discussion_r142195354
 
 

 ##########
 File path: superset/viz.py
 ##########
 @@ -840,16 +840,11 @@ def to_series(self, df, classed='', title_suffix=''):
             ys = series[name]
             if df[name].dtype.kind not in "biufc":
                 continue
-            if isinstance(name, string_types):
-                series_title = name
-            else:
-                name = ["{}".format(s) for s in name]
-                if len(self.form_data.get('metrics')) > 1:
 
 Review comment:
   Users reported an issue related to removing this logic. In the case where there's a single metric and a one or many dimension, the metric name would not be reported prior to this change, which is the desired behavior. Where before using metric `count` with `gender` dimension would give ['female', 'male', 'other'] in both the legend and tooltip, now it says  ['count, female', 'count, male', 'count, other'] 
   
 
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services