azure-storage-blob 12.26.0b1__py3-none-any.whl → 12.27.0b1__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- azure/storage/blob/__init__.py +3 -2
- azure/storage/blob/_blob_client.py +43 -38
- azure/storage/blob/_blob_client_helpers.py +4 -3
- azure/storage/blob/_blob_service_client.py +16 -13
- azure/storage/blob/_container_client.py +25 -22
- azure/storage/blob/_deserialize.py +1 -1
- azure/storage/blob/_download.py +7 -7
- azure/storage/blob/_encryption.py +177 -184
- azure/storage/blob/_generated/_azure_blob_storage.py +3 -2
- azure/storage/blob/_generated/_configuration.py +2 -2
- azure/storage/blob/_generated/_utils/__init__.py +6 -0
- azure/storage/blob/_generated/{_serialization.py → _utils/serialization.py} +4 -22
- azure/storage/blob/_generated/aio/_azure_blob_storage.py +3 -2
- azure/storage/blob/_generated/aio/_configuration.py +2 -2
- azure/storage/blob/_generated/aio/operations/_append_blob_operations.py +6 -10
- azure/storage/blob/_generated/aio/operations/_blob_operations.py +35 -39
- azure/storage/blob/_generated/aio/operations/_block_blob_operations.py +9 -13
- azure/storage/blob/_generated/aio/operations/_container_operations.py +20 -24
- azure/storage/blob/_generated/aio/operations/_page_blob_operations.py +13 -17
- azure/storage/blob/_generated/aio/operations/_service_operations.py +10 -14
- azure/storage/blob/_generated/models/_models_py3.py +30 -9
- azure/storage/blob/_generated/operations/_append_blob_operations.py +11 -15
- azure/storage/blob/_generated/operations/_blob_operations.py +60 -64
- azure/storage/blob/_generated/operations/_block_blob_operations.py +16 -20
- azure/storage/blob/_generated/operations/_container_operations.py +39 -43
- azure/storage/blob/_generated/operations/_page_blob_operations.py +23 -27
- azure/storage/blob/_generated/operations/_service_operations.py +19 -23
- azure/storage/blob/_lease.py +1 -0
- azure/storage/blob/_list_blobs_helper.py +1 -1
- azure/storage/blob/_quick_query_helper.py +3 -3
- azure/storage/blob/_serialize.py +1 -0
- azure/storage/blob/_shared/__init__.py +7 -7
- azure/storage/blob/_shared/authentication.py +49 -32
- azure/storage/blob/_shared/avro/avro_io.py +44 -42
- azure/storage/blob/_shared/avro/avro_io_async.py +42 -41
- azure/storage/blob/_shared/avro/datafile.py +24 -21
- azure/storage/blob/_shared/avro/datafile_async.py +15 -15
- azure/storage/blob/_shared/avro/schema.py +196 -217
- azure/storage/blob/_shared/base_client.py +81 -59
- azure/storage/blob/_shared/base_client_async.py +58 -51
- azure/storage/blob/_shared/constants.py +1 -1
- azure/storage/blob/_shared/models.py +94 -92
- azure/storage/blob/_shared/parser.py +3 -3
- azure/storage/blob/_shared/policies.py +186 -147
- azure/storage/blob/_shared/policies_async.py +53 -65
- azure/storage/blob/_shared/request_handlers.py +50 -45
- azure/storage/blob/_shared/response_handlers.py +54 -45
- azure/storage/blob/_shared/shared_access_signature.py +65 -73
- azure/storage/blob/_shared/uploads.py +56 -49
- azure/storage/blob/_shared/uploads_async.py +70 -58
- azure/storage/blob/_version.py +1 -1
- azure/storage/blob/aio/__init__.py +3 -2
- azure/storage/blob/aio/_blob_client_async.py +53 -40
- azure/storage/blob/aio/_blob_service_client_async.py +13 -11
- azure/storage/blob/aio/_container_client_async.py +28 -25
- azure/storage/blob/aio/_download_async.py +7 -7
- azure/storage/blob/aio/_lease_async.py +1 -0
- azure/storage/blob/aio/_quick_query_helper_async.py +3 -3
- {azure_storage_blob-12.26.0b1.dist-info → azure_storage_blob-12.27.0b1.dist-info}/METADATA +3 -4
- azure_storage_blob-12.27.0b1.dist-info/RECORD +86 -0
- azure_storage_blob-12.26.0b1.dist-info/RECORD +0 -85
- {azure_storage_blob-12.26.0b1.dist-info → azure_storage_blob-12.27.0b1.dist-info}/LICENSE +0 -0
- {azure_storage_blob-12.26.0b1.dist-info → azure_storage_blob-12.27.0b1.dist-info}/WHEEL +0 -0
- {azure_storage_blob-12.26.0b1.dist-info → azure_storage_blob-12.27.0b1.dist-info}/top_level.txt +0 -0
@@ -228,7 +228,11 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
228
228
|
- except in the case of AzureSasCredential, where the conflicting SAS tokens will raise a ValueError.
|
229
229
|
If using an instance of AzureNamedKeyCredential, "name" should be the storage account name, and "key"
|
230
230
|
should be the storage account key.
|
231
|
-
:type credential:
|
231
|
+
:type credential:
|
232
|
+
~azure.core.credentials.AzureNamedKeyCredential or
|
233
|
+
~azure.core.credentials.AzureSasCredential or
|
234
|
+
~azure.core.credentials_async.AsyncTokenCredential or
|
235
|
+
str or dict[str, str] or None
|
232
236
|
:param str snapshot:
|
233
237
|
The optional blob snapshot on which to operate. This can be the snapshot ID string
|
234
238
|
or the response returned from :func:`create_snapshot`. If specified, this will override
|
@@ -238,7 +242,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
238
242
|
:keyword str audience: The audience to use when requesting tokens for Azure Active Directory
|
239
243
|
authentication. Only has an effect when credential is of type TokenCredential. The value could be
|
240
244
|
https://storage.azure.com/ (default) or https://<account>.blob.core.windows.net.
|
241
|
-
:
|
245
|
+
:return: A Blob client.
|
242
246
|
:rtype: ~azure.storage.blob.BlobClient
|
243
247
|
"""
|
244
248
|
account_url, container_name, blob_name, path_snapshot = _from_blob_url(blob_url=blob_url, snapshot=snapshot)
|
@@ -276,13 +280,17 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
276
280
|
Credentials provided here will take precedence over those in the connection string.
|
277
281
|
If using an instance of AzureNamedKeyCredential, "name" should be the storage account name, and "key"
|
278
282
|
should be the storage account key.
|
279
|
-
:type credential:
|
283
|
+
:type credential:
|
284
|
+
~azure.core.credentials.AzureNamedKeyCredential or
|
285
|
+
~azure.core.credentials.AzureSasCredential or
|
286
|
+
~azure.core.credentials_async.AsyncTokenCredential or
|
287
|
+
str or dict[str, str] or None
|
280
288
|
:keyword str version_id: The version id parameter is an opaque DateTime value that, when present,
|
281
289
|
specifies the version of the blob to operate on.
|
282
290
|
:keyword str audience: The audience to use when requesting tokens for Azure Active Directory
|
283
291
|
authentication. Only has an effect when credential is of type TokenCredential. The value could be
|
284
292
|
https://storage.azure.com/ (default) or https://<account>.blob.core.windows.net.
|
285
|
-
:
|
293
|
+
:return: A Blob client.
|
286
294
|
:rtype: ~azure.storage.blob.BlobClient
|
287
295
|
|
288
296
|
.. admonition:: Example:
|
@@ -309,7 +317,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
309
317
|
The information can also be retrieved if the user has a SAS to a container or blob.
|
310
318
|
The keys in the returned dictionary include 'sku_name' and 'account_kind'.
|
311
319
|
|
312
|
-
:
|
320
|
+
:return: A dict of account information (SKU and account type).
|
313
321
|
:rtype: dict(str, str)
|
314
322
|
"""
|
315
323
|
try:
|
@@ -430,7 +438,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
430
438
|
ACLs are bypassed and full permissions are granted. User must also have required RBAC permission.
|
431
439
|
|
432
440
|
:paramtype source_token_intent: Literal['backup']
|
433
|
-
:
|
441
|
+
:return: Response from creating a new block blob for a given URL.
|
434
442
|
:rtype: Dict[str, Any]
|
435
443
|
"""
|
436
444
|
if kwargs.get('cpk') and self.scheme.lower() != 'https':
|
@@ -581,7 +589,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
581
589
|
the timeout will apply to each call individually.
|
582
590
|
multiple calls to the Azure service and the timeout will apply to
|
583
591
|
each call individually.
|
584
|
-
:
|
592
|
+
:return: Blob-updated property dict (Etag and last modified)
|
585
593
|
:rtype: dict[str, Any]
|
586
594
|
|
587
595
|
.. admonition:: Example:
|
@@ -726,7 +734,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
726
734
|
the timeout will apply to each call individually.
|
727
735
|
multiple calls to the Azure service and the timeout will apply to
|
728
736
|
each call individually.
|
729
|
-
:
|
737
|
+
:return: A streaming object (StorageStreamDownloader)
|
730
738
|
:rtype: ~azure.storage.blob.aio.StorageStreamDownloader
|
731
739
|
|
732
740
|
.. admonition:: Example:
|
@@ -853,7 +861,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
853
861
|
This value is not tracked or validated on the client. To configure client-side network timeouts
|
854
862
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
855
863
|
#other-client--per-operation-configuration>`__.
|
856
|
-
:
|
864
|
+
:return: A streaming object (BlobQueryReader)
|
857
865
|
:rtype: ~azure.storage.blob.aio.BlobQueryReader
|
858
866
|
"""
|
859
867
|
error_cls = kwargs.pop("error_cls", BlobQueryError)
|
@@ -905,7 +913,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
905
913
|
and retains the blob for a specified number of days.
|
906
914
|
After the specified number of days, the blob's data is removed from the service during garbage collection.
|
907
915
|
Soft deleted blob is accessible through :func:`~ContainerClient.list_blobs()` specifying `include=['deleted']`
|
908
|
-
option. Soft-deleted blob can be restored using :func
|
916
|
+
option. Soft-deleted blob can be restored using :func:`~BlobClient.undelete_blob()` operation.
|
909
917
|
|
910
918
|
:param str delete_snapshots:
|
911
919
|
Required if the blob has associated snapshots. Values include:
|
@@ -953,6 +961,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
953
961
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
954
962
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
955
963
|
#other-client--per-operation-configuration>`__.
|
964
|
+
:return: None
|
956
965
|
:rtype: None
|
957
966
|
|
958
967
|
.. admonition:: Example:
|
@@ -991,6 +1000,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
991
1000
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
992
1001
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
993
1002
|
#other-client--per-operation-configuration>`__.
|
1003
|
+
:return: None
|
994
1004
|
:rtype: None
|
995
1005
|
|
996
1006
|
.. admonition:: Example:
|
@@ -1022,7 +1032,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
1022
1032
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
1023
1033
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
1024
1034
|
#other-client--per-operation-configuration>`__.
|
1025
|
-
:
|
1035
|
+
:return: boolean
|
1026
1036
|
:rtype: bool
|
1027
1037
|
"""
|
1028
1038
|
version_id = get_version_id(self.version_id, kwargs)
|
@@ -1092,7 +1102,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
1092
1102
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
1093
1103
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
1094
1104
|
#other-client--per-operation-configuration>`__.
|
1095
|
-
:
|
1105
|
+
:return: BlobProperties
|
1096
1106
|
:rtype: ~azure.storage.blob.BlobProperties
|
1097
1107
|
|
1098
1108
|
.. admonition:: Example:
|
@@ -1180,7 +1190,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
1180
1190
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
1181
1191
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
1182
1192
|
#other-client--per-operation-configuration>`__.
|
1183
|
-
:
|
1193
|
+
:return: Blob-updated property dict (Etag and last modified)
|
1184
1194
|
:rtype: Dict[str, Any]
|
1185
1195
|
"""
|
1186
1196
|
options = _set_http_headers_options(content_settings=content_settings, **kwargs)
|
@@ -1247,7 +1257,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
1247
1257
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
1248
1258
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
1249
1259
|
#other-client--per-operation-configuration>`__.
|
1250
|
-
:
|
1260
|
+
:return: Blob-updated property dict (Etag and last modified)
|
1251
1261
|
:rtype: Dict[str, Union[str, datetime]]
|
1252
1262
|
"""
|
1253
1263
|
if kwargs.get('cpk') and self.scheme.lower() != 'https':
|
@@ -1283,7 +1293,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
1283
1293
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
1284
1294
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
1285
1295
|
#other-client--per-operation-configuration>`__.
|
1286
|
-
:
|
1296
|
+
:return: Key value pairs of blob tags.
|
1287
1297
|
:rtype: Dict[str, str]
|
1288
1298
|
"""
|
1289
1299
|
|
@@ -1309,7 +1319,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
1309
1319
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
1310
1320
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
1311
1321
|
#other-client--per-operation-configuration>`__.
|
1312
|
-
:
|
1322
|
+
:return: Key value pairs of blob tags.
|
1313
1323
|
:rtype: Dict[str, str]
|
1314
1324
|
"""
|
1315
1325
|
|
@@ -1334,7 +1344,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
1334
1344
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
1335
1345
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
1336
1346
|
#other-client--per-operation-configuration>`__.
|
1337
|
-
:
|
1347
|
+
:return: Key value pairs of blob tags.
|
1338
1348
|
:rtype: Dict[str, Union[str, datetime, bool]]
|
1339
1349
|
"""
|
1340
1350
|
|
@@ -1431,7 +1441,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
1431
1441
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
1432
1442
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
1433
1443
|
#other-client--per-operation-configuration>`__.
|
1434
|
-
:
|
1444
|
+
:return: Blob-updated property dict (Etag and last modified).
|
1435
1445
|
:rtype: dict[str, Any]
|
1436
1446
|
"""
|
1437
1447
|
if self.require_encryption or (self.key_encryption_key is not None):
|
@@ -1527,7 +1537,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
1527
1537
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
1528
1538
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
1529
1539
|
#other-client--per-operation-configuration>`__.
|
1530
|
-
:
|
1540
|
+
:return: Blob-updated property dict (Etag and last modified).
|
1531
1541
|
:rtype: dict[str, Any]
|
1532
1542
|
"""
|
1533
1543
|
if self.require_encryption or (self.key_encryption_key is not None):
|
@@ -1607,7 +1617,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
1607
1617
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
1608
1618
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
1609
1619
|
#other-client--per-operation-configuration>`__.
|
1610
|
-
:
|
1620
|
+
:return: Blob-updated property dict (Snapshot ID, Etag, and last modified).
|
1611
1621
|
:rtype: dict[str, Any]
|
1612
1622
|
|
1613
1623
|
.. admonition:: Example:
|
@@ -1813,7 +1823,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
1813
1823
|
|
1814
1824
|
.. versionadded:: 12.10.0
|
1815
1825
|
|
1816
|
-
:
|
1826
|
+
:return: A dictionary of copy properties (etag, last_modified, copy_id, copy_status).
|
1817
1827
|
:rtype: dict[str, Union[str, ~datetime.datetime]]
|
1818
1828
|
|
1819
1829
|
.. admonition:: Example:
|
@@ -1852,6 +1862,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
1852
1862
|
The copy operation to abort. This can be either an ID, or an
|
1853
1863
|
instance of BlobProperties.
|
1854
1864
|
:type copy_id: str or ~azure.storage.blob.BlobProperties
|
1865
|
+
:return: None
|
1855
1866
|
:rtype: None
|
1856
1867
|
|
1857
1868
|
.. admonition:: Example:
|
@@ -1918,7 +1929,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
1918
1929
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
1919
1930
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
1920
1931
|
#other-client--per-operation-configuration>`__.
|
1921
|
-
:
|
1932
|
+
:return: A BlobLeaseClient object.
|
1922
1933
|
:rtype: ~azure.storage.blob.aio.BlobLeaseClient
|
1923
1934
|
|
1924
1935
|
.. admonition:: Example:
|
@@ -1967,6 +1978,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
1967
1978
|
Required if the blob has an active lease. Value can be a BlobLeaseClient object
|
1968
1979
|
or the lease ID as a string.
|
1969
1980
|
:paramtype lease: ~azure.storage.blob.aio.BlobLeaseClient or str
|
1981
|
+
:return: None
|
1970
1982
|
:rtype: None
|
1971
1983
|
"""
|
1972
1984
|
access_conditions = get_access_conditions(kwargs.pop('lease', None))
|
@@ -2034,7 +2046,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
2034
2046
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
2035
2047
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
2036
2048
|
#other-client--per-operation-configuration>`__.
|
2037
|
-
:
|
2049
|
+
:return: Blob property dict.
|
2038
2050
|
:rtype: Dict[str, Any]
|
2039
2051
|
"""
|
2040
2052
|
if self.require_encryption or (self.key_encryption_key is not None):
|
@@ -2109,7 +2121,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
2109
2121
|
ACLs are bypassed and full permissions are granted. User must also have required RBAC permission.
|
2110
2122
|
|
2111
2123
|
:paramtype source_token_intent: Literal['backup']
|
2112
|
-
:
|
2124
|
+
:return: Blob property dict.
|
2113
2125
|
:rtype: Dict[str, Any]
|
2114
2126
|
"""
|
2115
2127
|
if kwargs.get('cpk') and self.scheme.lower() != 'https':
|
@@ -2155,7 +2167,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
2155
2167
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
2156
2168
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
2157
2169
|
#other-client--per-operation-configuration>`__.
|
2158
|
-
:
|
2170
|
+
:return: A tuple of two lists - committed and uncommitted blocks
|
2159
2171
|
:rtype: Tuple[List[BlobBlock], List[BlobBlock]]
|
2160
2172
|
"""
|
2161
2173
|
access_conditions = get_access_conditions(kwargs.pop('lease', None))
|
@@ -2268,7 +2280,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
2268
2280
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
2269
2281
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
2270
2282
|
#other-client--per-operation-configuration>`__.
|
2271
|
-
:
|
2283
|
+
:return: Blob-updated property dict (Etag and last modified).
|
2272
2284
|
:rtype: dict(str, Any)
|
2273
2285
|
"""
|
2274
2286
|
if self.require_encryption or (self.key_encryption_key is not None):
|
@@ -2310,6 +2322,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
2310
2322
|
Required if the blob has an active lease. Value can be a BlobLeaseClient object
|
2311
2323
|
or the lease ID as a string.
|
2312
2324
|
:paramtype lease: ~azure.storage.blob.aio.BlobLeaseClient or str
|
2325
|
+
:return: None
|
2313
2326
|
:rtype: None
|
2314
2327
|
"""
|
2315
2328
|
access_conditions = get_access_conditions(kwargs.pop('lease', None))
|
@@ -2365,7 +2378,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
2365
2378
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
2366
2379
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
2367
2380
|
#other-client--per-operation-configuration>`__.
|
2368
|
-
:
|
2381
|
+
:return: Blob-updated property dict (Etag and last modified)
|
2369
2382
|
:rtype: Dict[str, Any]
|
2370
2383
|
"""
|
2371
2384
|
version_id = get_version_id(self.version_id, kwargs)
|
@@ -2398,7 +2411,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
2398
2411
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
2399
2412
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
2400
2413
|
#other-client--per-operation-configuration>`__.
|
2401
|
-
:
|
2414
|
+
:return: Key value pairs of blob tags.
|
2402
2415
|
:rtype: Dict[str, str]
|
2403
2416
|
"""
|
2404
2417
|
version_id = get_version_id(self.version_id, kwargs)
|
@@ -2470,7 +2483,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
2470
2483
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
2471
2484
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
2472
2485
|
#other-client--per-operation-configuration>`__.
|
2473
|
-
:
|
2486
|
+
:return:
|
2474
2487
|
A tuple of two lists of page ranges as dictionaries with 'start' and 'end' keys.
|
2475
2488
|
The first element are filled page ranges, the 2nd element is cleared page ranges.
|
2476
2489
|
:rtype: tuple(list(dict(str, str), list(dict(str, str))
|
@@ -2563,7 +2576,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
2563
2576
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
2564
2577
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
2565
2578
|
#other-client--per-operation-configuration>`__.
|
2566
|
-
:
|
2579
|
+
:return: An iterable (auto-paging) of PageRange.
|
2567
2580
|
:rtype: ~azure.core.paging.ItemPaged[~azure.storage.blob.PageRange]
|
2568
2581
|
"""
|
2569
2582
|
results_per_page = kwargs.pop('results_per_page', None)
|
@@ -2646,7 +2659,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
2646
2659
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
2647
2660
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
2648
2661
|
#other-client--per-operation-configuration>`__.
|
2649
|
-
:
|
2662
|
+
:return:
|
2650
2663
|
A tuple of two lists of page ranges as dictionaries with 'start' and 'end' keys.
|
2651
2664
|
The first element are filled page ranges, the 2nd element is cleared page ranges.
|
2652
2665
|
:rtype: tuple(list(dict(str, str), list(dict(str, str))
|
@@ -2711,7 +2724,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
2711
2724
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
2712
2725
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
2713
2726
|
#other-client--per-operation-configuration>`__.
|
2714
|
-
:
|
2727
|
+
:return: Blob-updated property dict (Etag and last modified).
|
2715
2728
|
:rtype: dict(str, Any)
|
2716
2729
|
"""
|
2717
2730
|
options = _set_sequence_number_options(sequence_number_action, sequence_number=sequence_number, **kwargs)
|
@@ -2767,7 +2780,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
2767
2780
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
2768
2781
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
2769
2782
|
#other-client--per-operation-configuration>`__.
|
2770
|
-
:
|
2783
|
+
:return: Blob-updated property dict (Etag and last modified).
|
2771
2784
|
:rtype: dict(str, Any)
|
2772
2785
|
"""
|
2773
2786
|
if kwargs.get('cpk') and self.scheme.lower() != 'https':
|
@@ -2863,7 +2876,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
2863
2876
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
2864
2877
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
2865
2878
|
#other-client--per-operation-configuration>`__.
|
2866
|
-
:
|
2879
|
+
:return: Blob-updated property dict (Etag and last modified).
|
2867
2880
|
:rtype: dict(str, Any)
|
2868
2881
|
"""
|
2869
2882
|
if self.require_encryption or (self.key_encryption_key is not None):
|
@@ -2994,7 +3007,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
2994
3007
|
ACLs are bypassed and full permissions are granted. User must also have required RBAC permission.
|
2995
3008
|
|
2996
3009
|
:paramtype source_token_intent: Literal['backup']
|
2997
|
-
:
|
3010
|
+
:return: Response after uploading pages from specified URL.
|
2998
3011
|
:rtype: Dict[str, Any]
|
2999
3012
|
"""
|
3000
3013
|
|
@@ -3075,7 +3088,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
3075
3088
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
3076
3089
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
3077
3090
|
#other-client--per-operation-configuration>`__.
|
3078
|
-
:
|
3091
|
+
:return: Blob-updated property dict (Etag and last modified).
|
3079
3092
|
:rtype: dict(str, Any)
|
3080
3093
|
"""
|
3081
3094
|
if self.require_encryption or (self.key_encryption_key is not None):
|
@@ -3172,7 +3185,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
3172
3185
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
3173
3186
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
3174
3187
|
#other-client--per-operation-configuration>`__.
|
3175
|
-
:
|
3188
|
+
:return: Blob-updated property dict (Etag, last modified, append offset, committed block count).
|
3176
3189
|
:rtype: dict(str, Any)
|
3177
3190
|
"""
|
3178
3191
|
if self.require_encryption or (self.key_encryption_key is not None):
|
@@ -3296,7 +3309,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
3296
3309
|
ACLs are bypassed and full permissions are granted. User must also have required RBAC permission.
|
3297
3310
|
|
3298
3311
|
:paramtype source_token_intent: Literal['backup']
|
3299
|
-
:
|
3312
|
+
:return: Result after appending a new block.
|
3300
3313
|
:rtype: Dict[str, Union[str, datetime, int]]
|
3301
3314
|
"""
|
3302
3315
|
if self.require_encryption or (self.key_encryption_key is not None):
|
@@ -3354,7 +3367,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
3354
3367
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
3355
3368
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
3356
3369
|
#other-client--per-operation-configuration>`__.
|
3357
|
-
:
|
3370
|
+
:return: Blob-updated property dict (Etag, last modified, append offset, committed block count).
|
3358
3371
|
:rtype: dict(str, Any)
|
3359
3372
|
"""
|
3360
3373
|
if self.require_encryption or (self.key_encryption_key is not None):
|
@@ -3370,7 +3383,7 @@ class BlobClient(AsyncStorageAccountHostsMixin, StorageAccountHostsMixin, Storag
|
|
3370
3383
|
|
3371
3384
|
The container need not already exist. Defaults to current blob's credentials.
|
3372
3385
|
|
3373
|
-
:
|
3386
|
+
:return: A ContainerClient.
|
3374
3387
|
:rtype: ~azure.storage.blob.ContainerClient
|
3375
3388
|
|
3376
3389
|
.. admonition:: Example:
|
@@ -145,7 +145,7 @@ class BlobServiceClient( # type: ignore [misc]
|
|
145
145
|
|
146
146
|
:param str hostname:
|
147
147
|
The hostname of the current location mode.
|
148
|
-
:
|
148
|
+
:return: A formatted endpoint URL including current location mode hostname.
|
149
149
|
:rtype: str
|
150
150
|
"""
|
151
151
|
return f"{self.scheme}://{hostname}/{self._query_str}"
|
@@ -177,7 +177,7 @@ class BlobServiceClient( # type: ignore [misc]
|
|
177
177
|
:keyword str audience: The audience to use when requesting tokens for Azure Active Directory
|
178
178
|
authentication. Only has an effect when credential is of type TokenCredential. The value could be
|
179
179
|
https://storage.azure.com/ (default) or https://<account>.blob.core.windows.net.
|
180
|
-
:
|
180
|
+
:return: A Blob service client.
|
181
181
|
:rtype: ~azure.storage.blob.BlobServiceClient
|
182
182
|
|
183
183
|
.. admonition:: Example:
|
@@ -235,7 +235,7 @@ class BlobServiceClient( # type: ignore [misc]
|
|
235
235
|
The information can also be retrieved if the user has a SAS to a container or blob.
|
236
236
|
The keys in the returned dictionary include 'sku_name' and 'account_kind'.
|
237
237
|
|
238
|
-
:
|
238
|
+
:return: A dict of account information (SKU and account type).
|
239
239
|
:rtype: dict(str, str)
|
240
240
|
|
241
241
|
.. admonition:: Example:
|
@@ -309,7 +309,7 @@ class BlobServiceClient( # type: ignore [misc]
|
|
309
309
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
310
310
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
311
311
|
#other-client--per-operation-configuration>`__.
|
312
|
-
:
|
312
|
+
:return: An object containing blob service properties such as
|
313
313
|
analytics logging, hour/minute metrics, cors rules, etc.
|
314
314
|
:rtype: Dict[str, Any]
|
315
315
|
|
@@ -379,6 +379,7 @@ class BlobServiceClient( # type: ignore [misc]
|
|
379
379
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
380
380
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
381
381
|
#other-client--per-operation-configuration>`__.
|
382
|
+
:return: None
|
382
383
|
:rtype: None
|
383
384
|
|
384
385
|
.. admonition:: Example:
|
@@ -443,7 +444,7 @@ class BlobServiceClient( # type: ignore [misc]
|
|
443
444
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
444
445
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
445
446
|
#other-client--per-operation-configuration>`__.
|
446
|
-
:
|
447
|
+
:return: An iterable (auto-paging) of ContainerProperties.
|
447
448
|
:rtype: ~azure.core.async_paging.AsyncItemPaged[~azure.storage.blob.ContainerProperties]
|
448
449
|
|
449
450
|
.. admonition:: Example:
|
@@ -496,7 +497,7 @@ class BlobServiceClient( # type: ignore [misc]
|
|
496
497
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
497
498
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
498
499
|
#other-client--per-operation-configuration>`__.
|
499
|
-
:
|
500
|
+
:return: An iterable (auto-paging) response of BlobProperties.
|
500
501
|
:rtype: ~azure.core.async_paging.AsyncItemPaged[~azure.storage.blob.FilteredBlob]
|
501
502
|
"""
|
502
503
|
|
@@ -545,7 +546,7 @@ class BlobServiceClient( # type: ignore [misc]
|
|
545
546
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
546
547
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
547
548
|
#other-client--per-operation-configuration>`__.
|
548
|
-
:
|
549
|
+
:return: A container client to interact with the newly created container.
|
549
550
|
:rtype: ~azure.storage.blob.aio.ContainerClient
|
550
551
|
|
551
552
|
.. admonition:: Example:
|
@@ -607,6 +608,7 @@ class BlobServiceClient( # type: ignore [misc]
|
|
607
608
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
608
609
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
609
610
|
#other-client--per-operation-configuration>`__.
|
611
|
+
:return: None
|
610
612
|
:rtype: None
|
611
613
|
|
612
614
|
.. admonition:: Example:
|
@@ -646,7 +648,7 @@ class BlobServiceClient( # type: ignore [misc]
|
|
646
648
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
647
649
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
648
650
|
#other-client--per-operation-configuration>`__.
|
649
|
-
:
|
651
|
+
:return: A container client for the renamed container.
|
650
652
|
:rtype: ~azure.storage.blob.ContainerClient
|
651
653
|
"""
|
652
654
|
renamed_container = self.get_container_client(new_name)
|
@@ -685,7 +687,7 @@ class BlobServiceClient( # type: ignore [misc]
|
|
685
687
|
This value is not tracked or validated on the client. To configure client-side network timesouts
|
686
688
|
see `here <https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/storage/azure-storage-blob
|
687
689
|
#other-client--per-operation-configuration>`__.
|
688
|
-
:
|
690
|
+
:return: The recovered soft-deleted ContainerClient.
|
689
691
|
:rtype: ~azure.storage.blob.aio.ContainerClient
|
690
692
|
"""
|
691
693
|
new_name = kwargs.pop('new_name', None)
|
@@ -709,7 +711,7 @@ class BlobServiceClient( # type: ignore [misc]
|
|
709
711
|
The container. This can either be the name of the container,
|
710
712
|
or an instance of ContainerProperties.
|
711
713
|
:type container: str or ~azure.storage.blob.ContainerProperties
|
712
|
-
:
|
714
|
+
:return: A ContainerClient.
|
713
715
|
:rtype: ~azure.storage.blob.aio.ContainerClient
|
714
716
|
|
715
717
|
.. admonition:: Example:
|
@@ -760,7 +762,7 @@ class BlobServiceClient( # type: ignore [misc]
|
|
760
762
|
:type snapshot: str or dict(str, Any)
|
761
763
|
:keyword str version_id: The version id parameter is an opaque DateTime value that, when present,
|
762
764
|
specifies the version of the blob to operate on.
|
763
|
-
:
|
765
|
+
:return: A BlobClient.
|
764
766
|
:rtype: ~azure.storage.blob.aio.BlobClient
|
765
767
|
|
766
768
|
.. admonition:: Example:
|