This is an automated email from the ASF dual-hosted git repository.
maximebeauchemin pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-superset.git
The following commit(s) were added to refs/heads/master by this push:
new 30cd0e3 Raise exception if long or lat not set in mapbox viz (#6867)
30cd0e3 is described below
commit 30cd0e3836baa4e837374b44e9856fc91294a526
Author: Ville Brofeldt <[email protected]>
AuthorDate: Mon Feb 18 19:20:59 2019 +0200
Raise exception if long or lat not set in mapbox viz (#6867)
---
superset/viz.py | 2 ++
1 file changed, 2 insertions(+)
diff --git a/superset/viz.py b/superset/viz.py
index a88860e..b2d9655 100644
--- a/superset/viz.py
+++ b/superset/viz.py
@@ -1982,6 +1982,8 @@ class MapboxViz(BaseViz):
label_col = fd.get('mapbox_label')
if not fd.get('groupby'):
+ if fd.get('all_columns_x') is None or fd.get('all_columns_y') is
None:
+ raise Exception(_('[Longitude] and [Latitude] must be set'))
d['columns'] = [fd.get('all_columns_x'), fd.get('all_columns_y')]
if label_col and len(label_col) >= 1: