From 21c341ef2a3e62d58922fbf1196ad8418e1efb17 Mon Sep 17 00:00:00 2001 From: Daniel Gaspar Date: Mon, 21 Mar 2022 10:17:46 +0000 Subject: [PATCH] chore: remove PUBLIC_ROLE_LIKE_GAMMA deprecated config key --- UPDATING.md | 1 + superset/security/manager.py | 6 ------ superset/views/core.py | 2 +- 3 files changed, 2 insertions(+), 7 deletions(-) diff --git a/UPDATING.md b/UPDATING.md index 953d2c34c400c..8ae155ccc9e41 100644 --- a/UPDATING.md +++ b/UPDATING.md @@ -29,6 +29,7 @@ assists people when migrating to a new version. ### Breaking Changes +- [19234](https://github.com/apache/superset/pull/19234): The `PUBLIC_ROLE_LIKE_GAMMA` config key has been removed, set `PUBLIC_ROLE_LIKE` = "Gamma" to have the same functionality. - [19231](https://github.com/apache/superset/pull/19231): The `ENABLE_REACT_CRUD_VIEWS` feature flag has been removed (permanently enabled). Any deployments which had set this flag to false will need to verify that the React views support their use case. - [17556](https://github.com/apache/superset/pull/17556): Bumps mysqlclient from v1 to v2 - [19113](https://github.com/apache/superset/pull/19113): The `ENABLE_JAVASCRIPT_CONTROLS` setting has moved from app config to a feature flag. Any deployments who overrode this setting will now need to override the feature flag from here onward. diff --git a/superset/security/manager.py b/superset/security/manager.py index eb068c81fbb11..275c77a41cd20 100644 --- a/superset/security/manager.py +++ b/superset/security/manager.py @@ -726,12 +726,6 @@ def sync_role_definitions(self) -> None: self.auth_role_public, merge=True, ) - if current_app.config.get("PUBLIC_ROLE_LIKE_GAMMA", False): - logger.warning( - "The config `PUBLIC_ROLE_LIKE_GAMMA` is deprecated and will be removed " - "in Superset 1.0. Please use `PUBLIC_ROLE_LIKE` instead." - ) - self.copy_role("Gamma", self.auth_role_public, merge=True) self.create_missing_perms() diff --git a/superset/views/core.py b/superset/views/core.py index 50a56569c547c..5959584f1c2d3 100755 --- a/superset/views/core.py +++ b/superset/views/core.py @@ -2792,7 +2792,7 @@ def show_traceback(self) -> FlaskResponse: # pylint: disable=no-self-use def welcome(self) -> FlaskResponse: """Personalized welcome page""" if not g.user or not g.user.get_id(): - if conf.get("PUBLIC_ROLE_LIKE_GAMMA", False) or conf["PUBLIC_ROLE_LIKE"]: + if conf["PUBLIC_ROLE_LIKE"]: return self.render_template("superset/public_welcome.html") return redirect(appbuilder.get_url_for_login)