mirror of
https://github.com/sunnypilot/sunnypilot.git
synced 2026-08-07 17:27:01 +08:00
prevent typing issue in azure_container (#31044)
prvent that issue
old-commit-hash: 840db1f1b7
This commit is contained in:
@@ -4,7 +4,6 @@ from functools import lru_cache
|
||||
from pathlib import Path
|
||||
from typing import IO, Union
|
||||
|
||||
from azure.storage.blob import ContainerClient
|
||||
|
||||
TOKEN_PATH = Path("/data/azure_token")
|
||||
|
||||
@@ -49,6 +48,7 @@ class AzureContainer:
|
||||
return f"{self.ACCOUNT_URL}/{self.CONTAINER}/"
|
||||
|
||||
def get_client_and_key(self):
|
||||
from azure.storage.blob import ContainerClient
|
||||
client = ContainerClient(self.ACCOUNT_URL, self.CONTAINER, credential=get_azure_credential())
|
||||
key = get_container_sas(self.ACCOUNT, self.CONTAINER)
|
||||
return client, key
|
||||
|
||||
Reference in New Issue
Block a user