diff --git a/src/azure-cli/azure/cli/command_modules/batchai/custom.py b/src/azure-cli/azure/cli/command_modules/batchai/custom.py index 9d93c6dc99a..340fff735e8 100644 --- a/src/azure-cli/azure/cli/command_modules/batchai/custom.py +++ b/src/azure-cli/azure/cli/command_modules/batchai/custom.py @@ -764,8 +764,9 @@ def _get_files_from_bfs(cli_ctx, bfs, path, expiry): :param str path: path to list files from. :param int expiry: SAS expiration time in minutes. """ - from azure.storage.blob import BlockBlobService - from azure.storage.blob.models import Blob, BlobPermissions + BlockBlobService = get_sdk(cli_ctx, ResourceType.DATA_STORAGE, 'blob#BlockBlobService') + Blob = get_sdk(cli_ctx, ResourceType.DATA_STORAGE, 'blob#Blob') + BlobPermissions = get_sdk(cli_ctx, ResourceType.DATA_STORAGE, 'blob#BlobPermissions') result = [] service = BlockBlobService(bfs.account_name, _get_storage_account_key(cli_ctx, bfs.account_name, None)) effective_path = _get_path_for_storage(path)