Skip to content

Commit 7738c7c

Browse files
authored
Fixed UnknownHostException on the specified KeyVault (#3102)
Fix #3090
1 parent 1ad3649 commit 7738c7c

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/databricks/labs/ucx/assessment/secrets.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
import re
44

55
from databricks.sdk import WorkspaceClient
6-
from databricks.sdk.errors import NotFound
6+
from databricks.sdk.errors import NotFound, InvalidState
77

88
logger = logging.getLogger(__name__)
99

@@ -24,6 +24,10 @@ def _get_secret_if_exists(self, secret_scope, secret_key) -> str | None:
2424
except NotFound:
2525
logger.warning(f'removed on the backend: {secret_scope}/{secret_key}')
2626
return None
27+
except InvalidState as e:
28+
# see https://github.com/databrickslabs/ucx/issues/3090
29+
logger.warning(f'Invalid Azure Key Vault for {secret_scope}/{secret_key}: {e}')
30+
return None
2731
except UnicodeDecodeError:
2832
logger.warning(
2933
f"Secret {secret_scope}/{secret_key} has Base64 bytes that cannot be decoded to utf-8 string."

0 commit comments

Comments
 (0)