Skip to content

Commit

Permalink
[hotfix on dist_bar] bringing back overwritten handling of ints and t…
Browse files Browse the repository at this point in the history
…uples
  • Loading branch information
mistercrunch committed Mar 16, 2017
1 parent 1b330a8 commit 5ca55a5
Showing 1 changed file with 11 additions and 4 deletions.
15 changes: 11 additions & 4 deletions superset/viz.py
Original file line number Diff line number Diff line change
Expand Up @@ -1168,12 +1168,19 @@ def get_data(self, df):
l = [str(s) for s in name[1:]]
series_title = ", ".join(l)
values = []
for i, v in ys.iteritems():
x = i
if isinstance(x, (tuple, list)):
x = ', '.join([str(s) for s in x])
else:
x = str(x)
values.append({
'x': x,
'y': v,
})
d = {
"key": series_title,
"values": [
{'x': i, 'y': v}
for i, v in ys.iteritems()
]
"values": values,
}
chart_data.append(d)
return chart_data
Expand Down

0 comments on commit 5ca55a5

Please sign in to comment.