From 388615001d2115f507bd157bddc760055bd751dc Mon Sep 17 00:00:00 2001 From: CodeingBoy Date: Thu, 28 Oct 2021 10:12:21 +0800 Subject: [PATCH 1/2] Bugfix for tracking url transformation --- superset/db_engine_specs/hive.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/superset/db_engine_specs/hive.py b/superset/db_engine_specs/hive.py index a695b11b62be1..cf01684ddea89 100644 --- a/superset/db_engine_specs/hive.py +++ b/superset/db_engine_specs/hive.py @@ -363,7 +363,7 @@ def handle_cursor( # pylint: disable=too-many-locals str(query_id), tracking_url, ) - tracking_url = current_app.config["TRACKING_URL_TRANSFORMER"] + tracking_url = current_app.config["TRACKING_URL_TRANSFORMER"](tracking_url) logger.info( "Query %s: Transformation applied: %s", str(query_id), From e6ab6f2a4995f63dd0aa150194a345c4bd8d092c Mon Sep 17 00:00:00 2001 From: CodeingBoy Date: Sat, 30 Oct 2021 14:03:10 +0800 Subject: [PATCH 2/2] Fix linting --- superset/db_engine_specs/hive.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/superset/db_engine_specs/hive.py b/superset/db_engine_specs/hive.py index cf01684ddea89..bbfcbd1bb39f1 100644 --- a/superset/db_engine_specs/hive.py +++ b/superset/db_engine_specs/hive.py @@ -363,7 +363,8 @@ def handle_cursor( # pylint: disable=too-many-locals str(query_id), tracking_url, ) - tracking_url = current_app.config["TRACKING_URL_TRANSFORMER"](tracking_url) + transformer = current_app.config["TRACKING_URL_TRANSFORMER"] + tracking_url = transformer(tracking_url) logger.info( "Query %s: Transformation applied: %s", str(query_id),