From 5d04b21a79bb0c674ae7ca6bb53e2bf575e56d4c Mon Sep 17 00:00:00 2001 From: allegroai <> Date: Fri, 8 May 2020 22:13:39 +0300 Subject: [PATCH] Fix upload_object_via_stream() in Azure storage driver --- trains/storage/helper.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/trains/storage/helper.py b/trains/storage/helper.py index b7ea0ff6..4e107027 100644 --- a/trains/storage/helper.py +++ b/trains/storage/helper.py @@ -1587,7 +1587,7 @@ class _AzureBlobServiceStorageDriver(_Driver): container.blob_service.create_blob_from_bytes( container.name, object_name, - bytes(iterator), + iterator.read() if hasattr(iterator, "read") else bytes(iterator), # timeout=300, max_connections=2, )