mistercrunch closed pull request #4795: [cli] force update perms on superset 
init
URL: https://github.com/apache/incubator-superset/pull/4795
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/superset/utils.py b/superset/utils.py
index 8e99f699aa..01c0e0ffb9 100644
--- a/superset/utils.py
+++ b/superset/utils.py
@@ -771,6 +771,10 @@ def merge_request_params(form_data, params):
 
 
 def get_update_perms_flag():
+    # When running CLI command `superset init`, alway update perms
+    if len(sys.argv) > 1 and sys.argv[1] == 'init':
+        return True
+    # Otherwise, do it based on env var SUPERSET_UPDATE_PERMS
     val = os.environ.get('SUPERSET_UPDATE_PERMS')
     return val.lower() not in ('0', 'false', 'no') if val else True
 


 

----------------------------------------------------------------
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:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to