[Python] Solve timeout errors on file uploads with new azure.storage.blob package

Discussão em 'Python' iniciado por Stack, Março 21, 2025.

  1. Stack

    Stack Membro Participativo

    I had to upgrade a docker container that was using the older version of microsoft azure's python packages to download data from an api, then upload a json to Azure Blob Storage. So since the pip install of the former "azure" metapackage is no longer allowed I have to use the new standalone packages (azure-storage-blob==12.6.0).

    Switching from the function "create_blob_from_path" from the blockblobservice integrated in the old "azure" package, to the new standalone package and BlobClient.upload() fails on larger files with a timeout error that completely ignores the timeout parameter of the function.

    I get a ServiceResponseError with the msg "Connection aborted / The write operation timed out"

    Is there any way to solve that error ?

    The new function feels like a huge step backwards from create_blob_from_path, the absence of progress_callback mainly is deplorable...

    Continue reading...

Compartilhe esta Página