diff --git a/docs-ref-services/latest/storage.md b/docs-ref-services/latest/storage.md index ed4e4a6842e1..ca901ea0f195 100644 --- a/docs-ref-services/latest/storage.md +++ b/docs-ref-services/latest/storage.md @@ -4,79 +4,89 @@ description: Reference for Azure Storage SDK for Python ms.date: 03/01/2024 ms.topic: reference ms.devlang: python -ms.service: storage +ms.service: azure-storage --- -# Azure Storage client libraries for Python - -## Client Packages (12.X.X) - Latest - -| Package Name | Reference | Package Manager | Source | -|--------------|-----------------------------------------------|---------------------------------------------------|--------------------------------------------------------| -| Storage Blob | [Reference](storage-blob-readme.md) | [PyPi](https://pypi.org/project/azure-storage-blob/) | [GitHub](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/storage/azure-storage-blob) | -| Storage Queue | [Reference](storage-queue-readme.md) | [PyPi](https://pypi.org/project/azure-storage-queue/) | [GitHub](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/storage/azure-storage-queue/azure/storage/queue) | -| Storage File Share | [Reference](storage-file-share-readme.md) | [PyPi](https://pypi.org/project/azure-storage-file-share/) | [GitHub](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/storage/azure-storage-file-share/azure/storage/fileshare) | -| Storage File Data Lake (Preview) | [Reference](storage-file-datalake-readme.md) | [PyPi](https://pypi.org/project/azure-storage-file-datalake/) | [GitHub](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/storage/azure-storage-file-datalake/azure/storage/filedatalake) | -| | | | | - -## Client Packages (2.X.X) - Legacy -| Package Name | Reference | Package Manager | Source | -|--------------|-----------------------------------------------|---------------------------------------------------|--------------------------------------------------------| -| Storage Blob | [Reference](/python/api/azure-storage-blob/?view=azure-python-previous&preserve-view=true) | [PyPi](https://pypi.org/project/azure-storage-blob/2.1.0/) | [GitHub](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/storage/azure-storage-blob) | -| Storage Queue | [Reference](/python/api/azure-storage-queue/?view=azure-python-previous&preserve-view=true) | [PyPi](https://pypi.org/project/azure-storage-queue/2.1.0/) | [GitHub](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/storage/azure-storage-queue/azure/storage/queue) | -| Storage File Share | [Reference](/python/api/azure-storage-file/?view=azure-python-previous&preserve-view=true) | [PyPi](https://pypi.org/project/azure-storage-file/) | [GitHub](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/storage/azure-storage-file-share/azure/storage/fileshare) | -| | | | | - -## Management -| Package Name | Reference | Package Manager | Source | -|--------------|-----------------------------------------------|---------------------------------------------------|--------------------------------------------------------| -| Storage Management | [Reference](/python/api/azure-mgmt-storage/) | [PyPi](https://pypi.org/project/azure-mgmt-storage/) | [GitHub](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/storage/azure-mgmt-storage) | -| | | | | - - -## Install the libraries - -### Client - -Azure Storage Client Libraries consist of 3 packages: Blob, File Share, and Queue. To install the blob package, run: - -```bash -pip install azure-storage-blob -``` - -### Management - -```bash -pip install azure-mgmt-storage -``` - -## Samples - -| Article | Description | -|--|--| -| [Get started with Azure Blob Storage in Python](/azure/storage/blobs/storage-python-how-to-use-blob-storage) | Create, read, update, restrict access, and delete files and objects in Azure Storage. | -| [Manage Azure Storage accounts](/samples/azure-samples/azure-samples-python-management/storage) | Create, update, and delete storage accounts. Retrieve and regenerate storage account access keys. - -Explore more [sample Python code](https://azure.microsoft.com/resources/samples/?platform=python) you can use in your apps. - -## Known issues - -This section details known issues for the Azure Storage client libraries for Python. - -### InvalidHeaderValue error message when using beta version of SDK - -In rare scenarios, applications that have upgraded to the latest beta or generally available version of the SDK can receive an `InvalidHeaderValue` error message. This issue can occur when using any of the Storage libraries. The error message looks similar to the following sample: - -```console -HTTP/1.1 400 The value for one of the HTTP headers is not in the correct format. -Content-Length: 328 -Content-Type: application/xml -Server: Microsoft-HTTPAPI/2.0 -x-ms-request-id: -Date: Fri, 19 May 2023 17:10:33 GMT - -InvalidHeaderValueThe value for one of the HTTP headers is not in the correct format. -RequestId: -Time:2023-05-19T17:10:34.2972651Zx-ms-versionyyyy-mm-dd -``` - -If you've upgraded to the latest beta or generally available of the SDK and you experience this error, it's recommended that you downgrade to the previous generally available version of the SDK to see if the issue resolves. If the issue persists, or if the recommendation is not feasible, [open a support ticket](https://ms.portal.azure.com/#create/Microsoft.Support) to explore further options. \ No newline at end of file +# Azure Storage client libraries for Python + +## Client Packages (12.X.X) - Latest + +| Package Name | Reference | Package Manager | Source | +|--------------|-----------------------------------------------|---------------------------------------------------|--------------------------------------------------------| +| Storage Blob | [Reference](storage-blob-readme.md) | [PyPi](https://pypi.org/project/azure-storage-blob/) | [GitHub](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/storage/azure-storage-blob) | +| Storage Queue | [Reference](storage-queue-readme.md) | [PyPi](https://pypi.org/project/azure-storage-queue/) | [GitHub](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/storage/azure-storage-queue/azure/storage/queue) | +| Storage File Share | [Reference](storage-file-share-readme.md) | [PyPi](https://pypi.org/project/azure-storage-file-share/) | [GitHub](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/storage/azure-storage-file-share/azure/storage/fileshare) | +| Storage File Data Lake (Preview) | [Reference](storage-file-datalake-readme.md) | [PyPi](https://pypi.org/project/azure-storage-file-datalake/) | [GitHub](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/storage/azure-storage-file-datalake/azure/storage/filedatalake) | +| | | | | + +## Client Packages (2.X.X) - Legacy +| Package Name | Reference | Package Manager | Source | +|--------------|-----------------------------------------------|---------------------------------------------------|--------------------------------------------------------| +| Storage Blob | [Reference](/python/api/azure-storage-blob/?view=azure-python-previous&preserve-view=true) | [PyPi](https://pypi.org/project/azure-storage-blob/2.1.0/) | [GitHub](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/storage/azure-storage-blob) | +| Storage Queue | [Reference](/python/api/azure-storage-queue/?view=azure-python-previous&preserve-view=true) | [PyPi](https://pypi.org/project/azure-storage-queue/2.1.0/) | [GitHub](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/storage/azure-storage-queue/azure/storage/queue) | +| Storage File Share | [Reference](/python/api/azure-storage-file/?view=azure-python-previous&preserve-view=true) | [PyPi](https://pypi.org/project/azure-storage-file/) | [GitHub](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/storage/azure-storage-file-share/azure/storage/fileshare) | +| | | | | + +## Management +| Package Name | Reference | Package Manager | Source | +|--------------|-----------------------------------------------|---------------------------------------------------|--------------------------------------------------------| +| Storage Management | [Reference](/python/api/azure-mgmt-storage/) | [PyPi](https://pypi.org/project/azure-mgmt-storage/) | [GitHub](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/storage/azure-mgmt-storage) | +| | | | | + + +## Install the libraries + +### Client + +Azure Storage Client Libraries consist of 3 packages: Blob, File Share, and Queue. To install the blob package, run: + +```bash +pip install azure-storage-blob +``` + +### Management + +```bash +pip install azure-mgmt-storage +``` + +## Samples + +| Article | Description | +|--|--| +| [Get started with Azure Blob Storage in Python](/azure/storage/blobs/storage-python-how-to-use-blob-storage) | Create, read, update, restrict access, and delete files and objects in Azure Storage. | +| [Manage Azure Storage accounts](/samples/azure-samples/azure-samples-python-management/storage) | Create, update, and delete storage accounts. Retrieve and regenerate storage account access keys. + +Explore more [sample Python code](https://azure.microsoft.com/resources/samples/?platform=python) you can use in your apps. + +## Known issues + +This section details known issues for the Azure Storage client libraries for Python. + +### Downloads of sparse page blobs with BlobClient.download_blob can result in extra data + +Under rare circumstances, performing a full download of a sparse Page Blob using `BlobClient.download_blob` could result in the downloaded content containing up to one "chunk" of extra data (all byte value `\x00`) at the end. Specifically, this could occur if the total blob size was not divisible by the chunk size used for the download (defaults to 4 MiB). + +#### Issue details + +| Client library | Versions impacted | Minimum safe version | Recommended action | +|--|--|--|--| +| azure-storage-blob | 12.0 to 12.19.0 | 12.19.1 | [Update to latest version or minimum 12.19.1](https://pypi.org/project/azure-storage-blob/) | + +### InvalidHeaderValue error message when using beta version of SDK + +In rare scenarios, applications that have upgraded to the latest beta or generally available version of the SDK can receive an `InvalidHeaderValue` error message. This issue can occur when using any of the Storage libraries. The error message looks similar to the following sample: + +```console +HTTP/1.1 400 The value for one of the HTTP headers is not in the correct format. +Content-Length: 328 +Content-Type: application/xml +Server: Microsoft-HTTPAPI/2.0 +x-ms-request-id: +Date: Fri, 19 May 2023 17:10:33 GMT + +InvalidHeaderValueThe value for one of the HTTP headers is not in the correct format. +RequestId: +Time:2023-05-19T17:10:34.2972651Zx-ms-versionyyyy-mm-dd +``` + +If you've upgraded to the latest beta or generally available of the SDK and you experience this error, it's recommended that you downgrade to the previous generally available version of the SDK to see if the issue resolves. If the issue persists, or if the recommendation is not feasible, [open a support ticket](https://portal.azure.com/#create/Microsoft.Support) to explore further options.