uranusjr commented on code in PR #68506:
URL: https://github.com/apache/airflow/pull/68506#discussion_r3424943355


##########
task-sdk/src/airflow/sdk/log.py:
##########
@@ -264,6 +264,28 @@ def mask_secret(secret: JsonValue, name: str | None = 
None) -> None:
             comms.send(MaskSecret(value=secret, name=name))
 
 
+async def amask_secret(secret: JsonValue, name: str | None = None) -> None:
+    """
+    Async version of mask_secret for use in async contexts.
+
+    Uses asend() instead of send() to avoid deadlock when called from within
+    an async task that already has an asend() in flight.
+    """
+    from contextlib import suppress
+
+    from airflow.sdk._shared.secrets_masker import _secrets_masker
+

Review Comment:
   These should probably be moved to the top of the file and unified with other 
local imports?



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