omkar-foss commented on code in PR #65423:
URL: https://github.com/apache/airflow/pull/65423#discussion_r3170146264


##########
airflow-core/src/airflow/models/connection.py:
##########
@@ -527,7 +527,9 @@ def get_connection_from_secrets(cls, conn_id: str, 
team_name: str | None = None)
                 return conn
             except AirflowRuntimeError as e:
                 if e.error.error == ErrorType.CONNECTION_NOT_FOUND:
-                    raise AirflowNotFoundException(f"The conn_id `{conn_id}` 
isn't defined") from None
+                    raise AirflowNotFoundException(
+                        f"The conn_id `{conn_id}` isn't defined", 
error_code="AERR002"

Review Comment:
   Still do you feel folks will totally miss using error_code if its 
non-mandatory? In that case I suppose we can make it mandatory/embedded.



-- 
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]

Reply via email to