You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@superset.apache.org by GitBox <gi...@apache.org> on 2018/01/19 03:06:42 UTC

[GitHub] timifasubaa commented on a change in pull request #4243: [WIP] Use json for imports and exports, not pickle

timifasubaa commented on a change in pull request #4243: [WIP] Use json for imports and exports, not pickle
URL: https://github.com/apache/incubator-superset/pull/4243#discussion_r162525078
 
 

 ##########
 File path: superset/views/core.py
 ##########
 @@ -1919,7 +1945,7 @@ def dashboard(self, dashboard_id):
         else:
             qry = qry.filter_by(slug=dashboard_id)
 
-        dash = qry.one()
+        dash = qry.first()#one()
 
 Review comment:
   Importing a new dashboard from an existing dashboard leaves the slug value the same and when .one has more than one result, it errors out. 
   Would it be better to avoid importing dashboards with the same slug or to add a random new slug or just return the first slug?  

----------------------------------------------------------------
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