Skip to content

Commit

Permalink
Set ignore NaN as true for TableViz (apache#5371)
Browse files Browse the repository at this point in the history
* set ignore NaN as true for TableViz

* linting

(cherry picked from commit cd2414b)
  • Loading branch information
hughhhh authored and mistercrunch committed Aug 3, 2018
1 parent e90c081 commit f5a454e
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion superset/viz.py
Original file line number Diff line number Diff line change
Expand Up @@ -580,7 +580,10 @@ def get_data(self, df):
def json_dumps(self, obj, sort_keys=False):
if self.form_data.get('all_columns'):
return json.dumps(
obj, default=utils.json_iso_dttm_ser, sort_keys=sort_keys)
obj,
default=utils.json_iso_dttm_ser,
sort_keys=sort_keys,
ignore_nan=True)
else:
return super(TableViz, self).json_dumps(obj)

Expand Down

0 comments on commit f5a454e

Please sign in to comment.