This is an automated email from the ASF dual-hosted git repository.
potiuk pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/airflow.git
The following commit(s) were added to refs/heads/main by this push:
new f4cdb6bcb0 Update best-practices.rst: fix Connection.get ->
Connection. get_connection_from_secrets (#39560)
f4cdb6bcb0 is described below
commit f4cdb6bcb0608f5928a57cbd9954b8ab8688f7c7
Author: iamtodor <[email protected]>
AuthorDate: Sun May 12 16:23:42 2024 +0200
Update best-practices.rst: fix Connection.get -> Connection.
get_connection_from_secrets (#39560)
---
docs/apache-airflow/best-practices.rst | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/apache-airflow/best-practices.rst
b/docs/apache-airflow/best-practices.rst
index ff888a093e..8022412499 100644
--- a/docs/apache-airflow/best-practices.rst
+++ b/docs/apache-airflow/best-practices.rst
@@ -824,7 +824,7 @@ For connection, use :envvar:`AIRFLOW_CONN_{CONN_ID}`.
)
conn_uri = conn.get_uri()
with mock.patch.dict("os.environ", AIRFLOW_CONN_MY_CONN=conn_uri):
- assert "cat" == Connection.get("my_conn").login
+ assert "cat" == Connection.get_connection_from_secrets("my_conn").login
Metadata DB maintenance
^^^^^^^^^^^^^^^^^^^^^^^