potiuk commented on a change in pull request #16628:
URL: https://github.com/apache/airflow/pull/16628#discussion_r657845339



##########
File path: airflow/providers/microsoft/azure/hooks/wasb.py
##########
@@ -140,9 +140,13 @@ def get_conn(self) -> BlobServiceClient:  # pylint: 
disable=too-many-return-stat
             return 
BlobServiceClient(account_url=f"https://{conn.login}.blob.core.windows.net/"; + 
sas_token)
 
         # Fall back to old auth (password) or use managed identity if not 
provided.
+        credential = conn.password
+        if not credential:
+            credential = ManagedIdentityCredential()
+            self.log.info("Using managed identity as credential")
         return BlobServiceClient(
             account_url=f"https://{conn.login}.blob.core.windows.net/";,
-            credential=conn.password or ManagedIdentityCredential(),
+            credential=conn.password,

Review comment:
       Should it be
   
   ```suggestion
               credential=credential,
   ```
   
   But then it is just adding an extra log entry in case the MIC is used.




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

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


Reply via email to