Ujjwaljain16 commented on code in PR #38229:
URL: https://github.com/apache/superset/pull/38229#discussion_r3440671308


##########
superset/initialization/__init__.py:
##########
@@ -811,7 +812,12 @@ def check_and_warn_database_connection(self) -> None:
                 db.engine.execute("SELECT 1")
         except Exception:
             db_uri = self.database_uri
-            safe_uri = make_url_safe(db_uri) if db_uri else "Not configured"
+            safe_uri = (
+                make_url_safe(db_uri).render_as_string(hide_password=True)
+                if db_uri
+                else "Not configured"
+            )

Review Comment:
   Good catch on the malformed URI path the goal of 
check_and_warn_database_connection() is to warn rather than raise so i'll add a 
safe fallback for parse failures



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to