Skip to content

Commit 5e79b0b

Browse files
sfc-gh-stakedaankit-bhatnagar167
authored andcommitted
SNOW-89190: fix Azure GovCloud PUT and GET command issue
1 parent 7c85ae6 commit 5e79b0b

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

azure_util.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,12 @@ def create_client(stage_info, use_accelerate_endpoint=False):
4444
sas_token = stage_credentials[u'AZURE_SAS_TOKEN']
4545
if sas_token and sas_token.startswith(u'?'):
4646
sas_token = sas_token[1:]
47+
end_point = stage_info['endPoint']
48+
if end_point.startswith('blob.'):
49+
end_point = end_point[len('blob.'):]
4750
client = BlockBlobService(account_name=stage_info[u'storageAccount'],
48-
sas_token=sas_token)
51+
sas_token=sas_token,
52+
endpoint_suffix=end_point)
4953
client.retry = ExponentialRetry(
5054
initial_backoff=1, increment_base=2, max_attempts=60, random_jitter_range=2).retry
5155
return client

0 commit comments

Comments
 (0)