Skip to content

Commit dcbdecc

Browse files
committed
clean
1 parent a7e734a commit dcbdecc

File tree

1 file changed

+2
-5
lines changed
  • airflow/providers/microsoft/azure/hooks

1 file changed

+2
-5
lines changed

airflow/providers/microsoft/azure/hooks/adx.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ def get_ui_field_behaviour() -> dict[str, Any]:
106106
"placeholders": {
107107
"login": "Varies with authentication method",
108108
"password": "Varies with authentication method",
109-
"auth_method": "AAD_APP/AAD_APP_CERT/AAD_CREDS/AAD_DEVICE",
109+
"auth_method": "AAD_APP/AAD_APP_CERT/AAD_CREDS/AAD_DEVICE/AZURE_TOKEN_CRED",
110110
"tenant": "Used with AAD_APP/AAD_APP_CERT/AAD_CREDS",
111111
"certificate": "Used with AAD_APP_CERT",
112112
"thumbprint": "Used with AAD_APP_CERT",
@@ -185,12 +185,9 @@ def get_required_param(name: str) -> str:
185185
elif auth_method == "AAD_DEVICE":
186186
kcsb = KustoConnectionStringBuilder.with_aad_device_authentication(cluster)
187187
elif auth_method == "AZURE_TOKEN_CRED":
188-
credential = conn.password
189-
if not credential:
190-
credential = DefaultAzureCredential()
191188
kcsb = KustoConnectionStringBuilder.with_azure_token_credential(
192189
connection_string=cluster,
193-
credential=credential,
190+
credential=DefaultAzureCredential(),
194191
)
195192
else:
196193
raise AirflowException(f"Unknown authentication method: {auth_method}")

0 commit comments

Comments
 (0)