You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "hussein-awala (via GitHub)" <gi...@apache.org> on 2023/06/07 17:02:21 UTC
[GitHub] [airflow] hussein-awala commented on a diff in pull request #31465: fix connection uri parsing when the host includes a scheme
hussein-awala commented on code in PR #31465:
URL: https://github.com/apache/airflow/pull/31465#discussion_r1221923149
##########
airflow/models/connection.py:
##########
@@ -187,10 +187,22 @@ def _normalize_conn_type(conn_type):
return conn_type
def _parse_from_uri(self, uri: str):
+ schemes_count_in_uri = uri.count("://")
+ if schemes_count_in_uri > 2:
+ raise AirflowException(f"Invalid connection string: {uri}.")
+ scheme_in_uri = schemes_count_in_uri == 2
Review Comment:
can you check it now?
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org