From 79ec4b97929150e5cd28fd20cd57a1cc2971a037 Mon Sep 17 00:00:00 2001 From: xiafu Date: Fri, 7 May 2021 10:29:04 -0700 Subject: [PATCH] [Storage][Fix]Copy source is redirecting It seems previously the website wasn't redirecting from http to https. Service doesn't support redirecting. --- ...test_common_blob.test_abort_copy_blob.yaml | 170 ++++++++----- ...ommon_blob_async.test_abort_copy_blob.yaml | 230 +++++++----------- .../tests/test_common_blob.py | 2 +- .../tests/test_common_blob_async.py | 2 +- 4 files changed, 206 insertions(+), 198 deletions(-) diff --git a/sdk/storage/azure-storage-blob/tests/recordings/test_common_blob.test_abort_copy_blob.yaml b/sdk/storage/azure-storage-blob/tests/recordings/test_common_blob.test_abort_copy_blob.yaml index 002c017f95f0..1a74800d7c61 100644 --- a/sdk/storage/azure-storage-blob/tests/recordings/test_common_blob.test_abort_copy_blob.yaml +++ b/sdk/storage/azure-storage-blob/tests/recordings/test_common_blob.test_abort_copy_blob.yaml @@ -3,7 +3,7 @@ interactions: body: null headers: Accept: - - '*/*' + - application/xml Accept-Encoding: - gzip, deflate Connection: @@ -11,37 +11,81 @@ interactions: Content-Length: - '0' User-Agent: - - azsdk-python-storage-blob/12.0.0b5 Python/3.6.3 (Windows-10-10.0.18362-SP0) + - azsdk-python-storage-blob/12.8.1 Python/3.7.3 (Windows-10-10.0.19041-SP0) x-ms-date: - - Fri, 25 Oct 2019 18:09:15 GMT + - Fri, 07 May 2021 17:24:58 GMT x-ms-version: - - '2019-02-02' + - '2020-06-12' method: PUT - uri: https://storagename.blob.core.windows.net/utcontainer207e0f24?timeout=5&restype=container + uri: https://storagename.blob.core.windows.net/utcontainer207e0f24?restype=container&timeout=5 response: body: - string: '' + string: "\uFEFFContainerAlreadyExistsThe + specified container already exists.\nRequestId:098d9483-201e-0042-6765-43ea74000000\nTime:2021-05-07T17:24:59.0332365Z" headers: content-length: + - '230' + content-type: + - application/xml + date: + - Fri, 07 May 2021 17:24:58 GMT + server: + - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + x-ms-error-code: + - ContainerAlreadyExists + x-ms-version: + - '2020-06-12' + status: + code: 409 + message: The specified container already exists. +- request: + body: null + headers: + Accept: + - application/xml + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: - '0' + User-Agent: + - azsdk-python-storage-blob/12.8.1 Python/3.7.3 (Windows-10-10.0.19041-SP0) + x-ms-copy-source: + - https://www.gutenberg.org/files/59466/59466-0.txt + x-ms-date: + - Fri, 07 May 2021 17:24:59 GMT + x-ms-version: + - '2020-06-12' + method: PUT + uri: https://storagename.blob.core.windows.net/utcontainer207e0f24/59466-0.txt + response: + body: + string: "\uFEFFOperationTimedOutOperation + could not be completed within the specified time.\nRequestId:098d94c3-201e-0042-1b65-43ea74000000\nTime:2021-05-07T17:25:29.0954770Z" + headers: + connection: + - close + content-length: + - '245' + content-type: + - application/xml date: - - Fri, 25 Oct 2019 18:09:15 GMT - etag: - - '"0x8D7597672739994"' - last-modified: - - Fri, 25 Oct 2019 18:09:15 GMT + - Fri, 07 May 2021 17:25:28 GMT server: - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + x-ms-error-code: + - OperationTimedOut x-ms-version: - - '2019-02-02' + - '2020-06-12' status: - code: 201 - message: Created + code: 500 + message: Operation could not be completed within the specified time. - request: body: null headers: Accept: - - '*/*' + - application/xml Accept-Encoding: - gzip, deflate Connection: @@ -49,13 +93,13 @@ interactions: Content-Length: - '0' User-Agent: - - azsdk-python-storage-blob/12.0.0b5 Python/3.6.3 (Windows-10-10.0.18362-SP0) + - azsdk-python-storage-blob/12.8.1 Python/3.7.3 (Windows-10-10.0.19041-SP0) x-ms-copy-source: - - http://www.gutenberg.org/files/59466/59466-0.txt + - https://www.gutenberg.org/files/59466/59466-0.txt x-ms-date: - - Fri, 25 Oct 2019 18:09:16 GMT + - Fri, 07 May 2021 17:25:45 GMT x-ms-version: - - '2019-02-02' + - '2020-06-12' method: PUT uri: https://storagename.blob.core.windows.net/utcontainer207e0f24/59466-0.txt response: @@ -65,19 +109,19 @@ interactions: content-length: - '0' date: - - Fri, 25 Oct 2019 18:09:15 GMT + - Fri, 07 May 2021 17:25:53 GMT etag: - - '"0x8D7597672BABFC7"' + - '"0x8D9117D2A923BB3"' last-modified: - - Fri, 25 Oct 2019 18:09:16 GMT + - Fri, 07 May 2021 17:25:53 GMT server: - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 x-ms-copy-id: - - c1d192f4-9fc2-437b-a08f-3e3d0800a6e8 + - d912a019-0bad-431d-8295-2db29beabc08 x-ms-copy-status: - pending x-ms-version: - - '2019-02-02' + - '2020-06-12' status: code: 202 message: Accepted @@ -85,7 +129,7 @@ interactions: body: null headers: Accept: - - '*/*' + - application/xml Accept-Encoding: - gzip, deflate Connection: @@ -93,15 +137,15 @@ interactions: Content-Length: - '0' User-Agent: - - azsdk-python-storage-blob/12.0.0b5 Python/3.6.3 (Windows-10-10.0.18362-SP0) + - azsdk-python-storage-blob/12.8.1 Python/3.7.3 (Windows-10-10.0.19041-SP0) x-ms-copy-action: - abort x-ms-date: - - Fri, 25 Oct 2019 18:09:16 GMT + - Fri, 07 May 2021 17:25:53 GMT x-ms-version: - - '2019-02-02' + - '2020-06-12' method: PUT - uri: https://storagename.blob.core.windows.net/utcontainer207e0f24/59466-0.txt?copyid=c1d192f4-9fc2-437b-a08f-3e3d0800a6e8&comp=copy + uri: https://storagename.blob.core.windows.net/utcontainer207e0f24/59466-0.txt?comp=copy©id=d912a019-0bad-431d-8295-2db29beabc08 response: body: string: '' @@ -109,11 +153,11 @@ interactions: content-length: - '0' date: - - Fri, 25 Oct 2019 18:09:16 GMT + - Fri, 07 May 2021 17:25:53 GMT server: - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 x-ms-version: - - '2019-02-02' + - '2020-06-12' status: code: 204 message: No Content @@ -121,17 +165,17 @@ interactions: body: null headers: Accept: - - '*/*' + - application/xml Accept-Encoding: - gzip, deflate Connection: - keep-alive User-Agent: - - azsdk-python-storage-blob/12.0.0b5 Python/3.6.3 (Windows-10-10.0.18362-SP0) + - azsdk-python-storage-blob/12.8.1 Python/3.7.3 (Windows-10-10.0.19041-SP0) x-ms-date: - - Fri, 25 Oct 2019 18:09:16 GMT + - Fri, 07 May 2021 17:25:53 GMT x-ms-version: - - '2019-02-02' + - '2020-06-12' method: HEAD uri: https://storagename.blob.core.windows.net/utcontainer207e0f24/59466-0.txt response: @@ -145,13 +189,15 @@ interactions: content-type: - text/plain date: - - Fri, 25 Oct 2019 18:09:16 GMT + - Fri, 07 May 2021 17:25:53 GMT etag: - - '"0x8D7597672C6CFE7"' + - '"0x8D9117D2ACFC50A"' last-modified: - - Fri, 25 Oct 2019 18:09:16 GMT + - Fri, 07 May 2021 17:25:53 GMT server: - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + vary: + - Origin x-ms-access-tier: - Hot x-ms-access-tier-inferred: @@ -159,17 +205,17 @@ interactions: x-ms-blob-type: - BlockBlob x-ms-copy-completion-time: - - Fri, 25 Oct 2019 18:09:16 GMT + - Fri, 07 May 2021 17:25:53 GMT x-ms-copy-id: - - c1d192f4-9fc2-437b-a08f-3e3d0800a6e8 + - d912a019-0bad-431d-8295-2db29beabc08 x-ms-copy-progress: - 0/439274 x-ms-copy-source: - - http://www.gutenberg.org/files/59466/59466-0.txt + - https://www.gutenberg.org/files/59466/59466-0.txt x-ms-copy-status: - aborted x-ms-creation-time: - - Fri, 25 Oct 2019 18:09:16 GMT + - Fri, 07 May 2021 17:25:53 GMT x-ms-lease-state: - available x-ms-lease-status: @@ -177,7 +223,7 @@ interactions: x-ms-server-encrypted: - 'true' x-ms-version: - - '2019-02-02' + - '2020-06-12' status: code: 200 message: OK @@ -191,19 +237,19 @@ interactions: Connection: - keep-alive User-Agent: - - azsdk-python-storage-blob/12.0.0b5 Python/3.6.3 (Windows-10-10.0.18362-SP0) + - azsdk-python-storage-blob/12.8.1 Python/3.7.3 (Windows-10-10.0.19041-SP0) x-ms-date: - - Fri, 25 Oct 2019 18:09:16 GMT + - Fri, 07 May 2021 17:25:53 GMT x-ms-range: - bytes=0-33554431 x-ms-version: - - '2019-02-02' + - '2020-06-12' method: GET uri: https://storagename.blob.core.windows.net/utcontainer207e0f24/59466-0.txt response: body: string: "\uFEFFInvalidRangeThe - range specified is invalid for the current size of the resource.\nRequestId:cc210932-f01e-005f-6a5f-8b0351000000\nTime:2019-10-25T18:09:16.3940806Z" + range specified is invalid for the current size of the resource.\nRequestId:689b1184-801e-00bf-7466-436451000000\nTime:2021-05-07T17:25:53.8087976Z" headers: content-length: - '249' @@ -212,13 +258,15 @@ interactions: content-type: - application/xml date: - - Fri, 25 Oct 2019 18:09:16 GMT + - Fri, 07 May 2021 17:25:53 GMT server: - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + vary: + - Origin x-ms-error-code: - InvalidRange x-ms-version: - - '2019-02-02' + - '2020-06-12' status: code: 416 message: The range specified is invalid for the current size of the resource. @@ -232,11 +280,11 @@ interactions: Connection: - keep-alive User-Agent: - - azsdk-python-storage-blob/12.0.0b5 Python/3.6.3 (Windows-10-10.0.18362-SP0) + - azsdk-python-storage-blob/12.8.1 Python/3.7.3 (Windows-10-10.0.19041-SP0) x-ms-date: - - Fri, 25 Oct 2019 18:09:16 GMT + - Fri, 07 May 2021 17:25:53 GMT x-ms-version: - - '2019-02-02' + - '2020-06-12' method: GET uri: https://storagename.blob.core.windows.net/utcontainer207e0f24/59466-0.txt response: @@ -250,27 +298,29 @@ interactions: content-type: - text/plain date: - - Fri, 25 Oct 2019 18:09:16 GMT + - Fri, 07 May 2021 17:25:53 GMT etag: - - '"0x8D7597672C6CFE7"' + - '"0x8D9117D2ACFC50A"' last-modified: - - Fri, 25 Oct 2019 18:09:16 GMT + - Fri, 07 May 2021 17:25:53 GMT server: - Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + vary: + - Origin x-ms-blob-type: - BlockBlob x-ms-copy-completion-time: - - Fri, 25 Oct 2019 18:09:16 GMT + - Fri, 07 May 2021 17:25:53 GMT x-ms-copy-id: - - c1d192f4-9fc2-437b-a08f-3e3d0800a6e8 + - d912a019-0bad-431d-8295-2db29beabc08 x-ms-copy-progress: - 0/439274 x-ms-copy-source: - - http://www.gutenberg.org/files/59466/59466-0.txt + - https://www.gutenberg.org/files/59466/59466-0.txt x-ms-copy-status: - aborted x-ms-creation-time: - - Fri, 25 Oct 2019 18:09:16 GMT + - Fri, 07 May 2021 17:25:53 GMT x-ms-lease-state: - available x-ms-lease-status: @@ -278,7 +328,7 @@ interactions: x-ms-server-encrypted: - 'true' x-ms-version: - - '2019-02-02' + - '2020-06-12' status: code: 200 message: OK diff --git a/sdk/storage/azure-storage-blob/tests/recordings/test_common_blob_async.test_abort_copy_blob.yaml b/sdk/storage/azure-storage-blob/tests/recordings/test_common_blob_async.test_abort_copy_blob.yaml index 56f97f337f75..d24c11693a9c 100644 --- a/sdk/storage/azure-storage-blob/tests/recordings/test_common_blob_async.test_abort_copy_blob.yaml +++ b/sdk/storage/azure-storage-blob/tests/recordings/test_common_blob_async.test_abort_copy_blob.yaml @@ -2,46 +2,44 @@ interactions: - request: body: null headers: + Accept: + - application/xml User-Agent: - - azsdk-python-storage-blob/12.0.0b5 Python/3.6.3 (Windows-10-10.0.18362-SP0) + - azsdk-python-storage-blob/12.8.1 Python/3.7.3 (Windows-10-10.0.19041-SP0) x-ms-date: - - Fri, 25 Oct 2019 18:32:35 GMT + - Fri, 07 May 2021 17:24:40 GMT x-ms-version: - - '2019-02-02' + - '2020-06-12' method: PUT - uri: https://storagename.blob.core.windows.net/utcontainer853e11a1?timeout=5&restype=container + uri: https://storagename.blob.core.windows.net/utcontainer853e11a1?restype=container&timeout=5 response: body: - string: '' + string: "\uFEFFContainerAlreadyExistsThe + specified container already exists.\nRequestId:0a88dda9-501e-00de-3a65-434712000000\nTime:2021-05-07T17:24:40.3129787Z" headers: - content-length: '0' - date: Fri, 25 Oct 2019 18:32:35 GMT - etag: '"0x8D75979B52173AA"' - last-modified: Fri, 25 Oct 2019 18:32:36 GMT + content-length: '230' + content-type: application/xml + date: Fri, 07 May 2021 17:24:39 GMT server: Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 - x-ms-version: '2019-02-02' + x-ms-error-code: ContainerAlreadyExists + x-ms-version: '2020-06-12' status: - code: 201 - message: Created - url: !!python/object/new:yarl.URL - state: !!python/tuple - - !!python/object/new:urllib.parse.SplitResult - - https - - pyacrstorageiqnubxlez5qu.blob.core.windows.net - - /utcontainer853e11a1 - - timeout=5&restype=container - - '' + code: 409 + message: The specified container already exists. + url: https://emilydevtest.blob.core.windows.net/utcontainer853e11a1?restype=container&timeout=5 - request: body: null headers: + Accept: + - application/xml User-Agent: - - azsdk-python-storage-blob/12.0.0b5 Python/3.6.3 (Windows-10-10.0.18362-SP0) + - azsdk-python-storage-blob/12.8.1 Python/3.7.3 (Windows-10-10.0.19041-SP0) x-ms-copy-source: - - http://www.gutenberg.org/files/59466/59466-0.txt + - https://www.gutenberg.org/files/59466/59466-0.txt x-ms-date: - - Fri, 25 Oct 2019 18:32:36 GMT + - Fri, 07 May 2021 17:24:40 GMT x-ms-version: - - '2019-02-02' + - '2020-06-12' method: PUT uri: https://storagename.blob.core.windows.net/utcontainer853e11a1/59466-0.txt response: @@ -49,65 +47,55 @@ interactions: string: '' headers: content-length: '0' - date: Fri, 25 Oct 2019 18:32:35 GMT - etag: '"0x8D75979B54D97E4"' - last-modified: Fri, 25 Oct 2019 18:32:36 GMT + date: Fri, 07 May 2021 17:24:46 GMT + etag: '"0x8D9117D038D94CA"' + last-modified: Fri, 07 May 2021 17:24:47 GMT server: Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 - x-ms-copy-id: 84a205bb-f74e-43a4-b4c0-ffda461e139b + x-ms-copy-id: ac5a11e4-abf9-4c72-8621-7f1d24f71a1a x-ms-copy-status: pending - x-ms-version: '2019-02-02' + x-ms-version: '2020-06-12' status: code: 202 message: Accepted - url: !!python/object/new:yarl.URL - state: !!python/tuple - - !!python/object/new:urllib.parse.SplitResult - - https - - pyacrstorageiqnubxlez5qu.blob.core.windows.net - - /utcontainer853e11a1/59466-0.txt - - '' - - '' + url: https://emilydevtest.blob.core.windows.net/utcontainer853e11a1/59466-0.txt - request: body: null headers: + Accept: + - application/xml User-Agent: - - azsdk-python-storage-blob/12.0.0b5 Python/3.6.3 (Windows-10-10.0.18362-SP0) + - azsdk-python-storage-blob/12.8.1 Python/3.7.3 (Windows-10-10.0.19041-SP0) x-ms-copy-action: - abort x-ms-date: - - Fri, 25 Oct 2019 18:32:36 GMT + - Fri, 07 May 2021 17:24:47 GMT x-ms-version: - - '2019-02-02' + - '2020-06-12' method: PUT - uri: https://storagename.blob.core.windows.net/utcontainer853e11a1/59466-0.txt?copyid=84a205bb-f74e-43a4-b4c0-ffda461e139b&comp=copy + uri: https://storagename.blob.core.windows.net/utcontainer853e11a1/59466-0.txt?comp=copy©id=ac5a11e4-abf9-4c72-8621-7f1d24f71a1a response: body: string: '' headers: content-length: '0' - date: Fri, 25 Oct 2019 18:32:36 GMT + date: Fri, 07 May 2021 17:24:46 GMT server: Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 - x-ms-version: '2019-02-02' + x-ms-version: '2020-06-12' status: code: 204 message: No Content - url: !!python/object/new:yarl.URL - state: !!python/tuple - - !!python/object/new:urllib.parse.SplitResult - - https - - pyacrstorageiqnubxlez5qu.blob.core.windows.net - - /utcontainer853e11a1/59466-0.txt - - copyid=84a205bb-f74e-43a4-b4c0-ffda461e139b&comp=copy - - '' + url: https://emilydevtest.blob.core.windows.net/utcontainer853e11a1/59466-0.txt?comp=copy©id=ac5a11e4-abf9-4c72-8621-7f1d24f71a1a - request: body: null headers: + Accept: + - application/xml User-Agent: - - azsdk-python-storage-blob/12.0.0b5 Python/3.6.3 (Windows-10-10.0.18362-SP0) + - azsdk-python-storage-blob/12.8.1 Python/3.7.3 (Windows-10-10.0.19041-SP0) x-ms-date: - - Fri, 25 Oct 2019 18:32:36 GMT + - Fri, 07 May 2021 17:24:47 GMT x-ms-version: - - '2019-02-02' + - '2020-06-12' method: HEAD uri: https://storagename.blob.core.windows.net/utcontainer853e11a1/59466-0.txt response: @@ -117,83 +105,71 @@ interactions: accept-ranges: bytes content-length: '0' content-type: text/plain - date: Fri, 25 Oct 2019 18:32:36 GMT - etag: '"0x8D75979B557AC7E"' - last-modified: Fri, 25 Oct 2019 18:32:36 GMT + date: Fri, 07 May 2021 17:24:46 GMT + etag: '"0x8D9117D039ED5FD"' + last-modified: Fri, 07 May 2021 17:24:47 GMT server: Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + vary: Origin x-ms-access-tier: Hot x-ms-access-tier-inferred: 'true' x-ms-blob-type: BlockBlob - x-ms-copy-completion-time: Fri, 25 Oct 2019 18:32:36 GMT - x-ms-copy-id: 84a205bb-f74e-43a4-b4c0-ffda461e139b + x-ms-copy-completion-time: Fri, 07 May 2021 17:24:47 GMT + x-ms-copy-id: ac5a11e4-abf9-4c72-8621-7f1d24f71a1a x-ms-copy-progress: 0/439274 - x-ms-copy-source: http://www.gutenberg.org/files/59466/59466-0.txt + x-ms-copy-source: https://www.gutenberg.org/files/59466/59466-0.txt x-ms-copy-status: aborted - x-ms-creation-time: Fri, 25 Oct 2019 18:32:36 GMT + x-ms-creation-time: Fri, 07 May 2021 17:24:47 GMT x-ms-lease-state: available x-ms-lease-status: unlocked x-ms-server-encrypted: 'true' - x-ms-version: '2019-02-02' + x-ms-version: '2020-06-12' status: code: 200 message: OK - url: !!python/object/new:yarl.URL - state: !!python/tuple - - !!python/object/new:urllib.parse.SplitResult - - https - - pyacrstorageiqnubxlez5qu.blob.core.windows.net - - /utcontainer853e11a1/59466-0.txt - - '' - - '' + url: https://emilydevtest.blob.core.windows.net/utcontainer853e11a1/59466-0.txt - request: body: null headers: Accept: - application/xml User-Agent: - - azsdk-python-storage-blob/12.0.0b5 Python/3.6.3 (Windows-10-10.0.18362-SP0) + - azsdk-python-storage-blob/12.8.1 Python/3.7.3 (Windows-10-10.0.19041-SP0) x-ms-date: - - Fri, 25 Oct 2019 18:32:36 GMT + - Fri, 07 May 2021 17:24:47 GMT x-ms-range: - bytes=0-33554431 x-ms-version: - - '2019-02-02' + - '2020-06-12' method: GET uri: https://storagename.blob.core.windows.net/utcontainer853e11a1/59466-0.txt response: body: string: "\uFEFFInvalidRangeThe - range specified is invalid for the current size of the resource.\nRequestId:e88f870e-a01e-002f-1e62-8b6532000000\nTime:2019-10-25T18:32:36.5452071Z" + range specified is invalid for the current size of the resource.\nRequestId:0a88eeba-501e-00de-7765-434712000000\nTime:2021-05-07T17:24:47.9514163Z" headers: content-length: '249' content-range: bytes */0 content-type: application/xml - date: Fri, 25 Oct 2019 18:32:36 GMT + date: Fri, 07 May 2021 17:24:47 GMT server: Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + vary: Origin x-ms-error-code: InvalidRange - x-ms-version: '2019-02-02' + x-ms-version: '2020-06-12' status: code: 416 message: The range specified is invalid for the current size of the resource. - url: !!python/object/new:yarl.URL - state: !!python/tuple - - !!python/object/new:urllib.parse.SplitResult - - https - - pyacrstorageiqnubxlez5qu.blob.core.windows.net - - /utcontainer853e11a1/59466-0.txt - - '' - - '' + url: https://emilydevtest.blob.core.windows.net/utcontainer853e11a1/59466-0.txt - request: body: null headers: Accept: - application/xml User-Agent: - - azsdk-python-storage-blob/12.0.0b5 Python/3.6.3 (Windows-10-10.0.18362-SP0) + - azsdk-python-storage-blob/12.8.1 Python/3.7.3 (Windows-10-10.0.19041-SP0) x-ms-date: - - Fri, 25 Oct 2019 18:32:36 GMT + - Fri, 07 May 2021 17:24:47 GMT x-ms-version: - - '2019-02-02' + - '2020-06-12' method: GET uri: https://storagename.blob.core.windows.net/utcontainer853e11a1/59466-0.txt response: @@ -203,81 +179,69 @@ interactions: accept-ranges: bytes content-length: '0' content-type: text/plain - date: Fri, 25 Oct 2019 18:32:36 GMT - etag: '"0x8D75979B557AC7E"' - last-modified: Fri, 25 Oct 2019 18:32:36 GMT + date: Fri, 07 May 2021 17:24:47 GMT + etag: '"0x8D9117D039ED5FD"' + last-modified: Fri, 07 May 2021 17:24:47 GMT server: Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + vary: Origin x-ms-blob-type: BlockBlob - x-ms-copy-completion-time: Fri, 25 Oct 2019 18:32:36 GMT - x-ms-copy-id: 84a205bb-f74e-43a4-b4c0-ffda461e139b + x-ms-copy-completion-time: Fri, 07 May 2021 17:24:47 GMT + x-ms-copy-id: ac5a11e4-abf9-4c72-8621-7f1d24f71a1a x-ms-copy-progress: 0/439274 - x-ms-copy-source: http://www.gutenberg.org/files/59466/59466-0.txt + x-ms-copy-source: https://www.gutenberg.org/files/59466/59466-0.txt x-ms-copy-status: aborted - x-ms-creation-time: Fri, 25 Oct 2019 18:32:36 GMT + x-ms-creation-time: Fri, 07 May 2021 17:24:47 GMT x-ms-lease-state: available x-ms-lease-status: unlocked x-ms-server-encrypted: 'true' - x-ms-version: '2019-02-02' + x-ms-version: '2020-06-12' status: code: 200 message: OK - url: !!python/object/new:yarl.URL - state: !!python/tuple - - !!python/object/new:urllib.parse.SplitResult - - https - - pyacrstorageiqnubxlez5qu.blob.core.windows.net - - /utcontainer853e11a1/59466-0.txt - - '' - - '' + url: https://emilydevtest.blob.core.windows.net/utcontainer853e11a1/59466-0.txt - request: body: null headers: Accept: - application/xml User-Agent: - - azsdk-python-storage-blob/12.0.0b5 Python/3.6.3 (Windows-10-10.0.18362-SP0) + - azsdk-python-storage-blob/12.8.1 Python/3.7.3 (Windows-10-10.0.19041-SP0) x-ms-date: - - Fri, 25 Oct 2019 18:32:36 GMT + - Fri, 07 May 2021 17:24:47 GMT x-ms-range: - bytes=0-33554431 x-ms-version: - - '2019-02-02' + - '2020-06-12' method: GET uri: https://storagename.blob.core.windows.net/utcontainer853e11a1/59466-0.txt response: body: string: "\uFEFFInvalidRangeThe - range specified is invalid for the current size of the resource.\nRequestId:e88f8785-a01e-002f-1162-8b6532000000\nTime:2019-10-25T18:32:36.6232820Z" + range specified is invalid for the current size of the resource.\nRequestId:0a88eeca-501e-00de-0765-434712000000\nTime:2021-05-07T17:24:47.9844398Z" headers: content-length: '249' content-range: bytes */0 content-type: application/xml - date: Fri, 25 Oct 2019 18:32:36 GMT + date: Fri, 07 May 2021 17:24:47 GMT server: Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + vary: Origin x-ms-error-code: InvalidRange - x-ms-version: '2019-02-02' + x-ms-version: '2020-06-12' status: code: 416 message: The range specified is invalid for the current size of the resource. - url: !!python/object/new:yarl.URL - state: !!python/tuple - - !!python/object/new:urllib.parse.SplitResult - - https - - pyacrstorageiqnubxlez5qu.blob.core.windows.net - - /utcontainer853e11a1/59466-0.txt - - '' - - '' + url: https://emilydevtest.blob.core.windows.net/utcontainer853e11a1/59466-0.txt - request: body: null headers: Accept: - application/xml User-Agent: - - azsdk-python-storage-blob/12.0.0b5 Python/3.6.3 (Windows-10-10.0.18362-SP0) + - azsdk-python-storage-blob/12.8.1 Python/3.7.3 (Windows-10-10.0.19041-SP0) x-ms-date: - - Fri, 25 Oct 2019 18:32:36 GMT + - Fri, 07 May 2021 17:24:48 GMT x-ms-version: - - '2019-02-02' + - '2020-06-12' method: GET uri: https://storagename.blob.core.windows.net/utcontainer853e11a1/59466-0.txt response: @@ -287,30 +251,24 @@ interactions: accept-ranges: bytes content-length: '0' content-type: text/plain - date: Fri, 25 Oct 2019 18:32:36 GMT - etag: '"0x8D75979B557AC7E"' - last-modified: Fri, 25 Oct 2019 18:32:36 GMT + date: Fri, 07 May 2021 17:24:47 GMT + etag: '"0x8D9117D039ED5FD"' + last-modified: Fri, 07 May 2021 17:24:47 GMT server: Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0 + vary: Origin x-ms-blob-type: BlockBlob - x-ms-copy-completion-time: Fri, 25 Oct 2019 18:32:36 GMT - x-ms-copy-id: 84a205bb-f74e-43a4-b4c0-ffda461e139b + x-ms-copy-completion-time: Fri, 07 May 2021 17:24:47 GMT + x-ms-copy-id: ac5a11e4-abf9-4c72-8621-7f1d24f71a1a x-ms-copy-progress: 0/439274 - x-ms-copy-source: http://www.gutenberg.org/files/59466/59466-0.txt + x-ms-copy-source: https://www.gutenberg.org/files/59466/59466-0.txt x-ms-copy-status: aborted - x-ms-creation-time: Fri, 25 Oct 2019 18:32:36 GMT + x-ms-creation-time: Fri, 07 May 2021 17:24:47 GMT x-ms-lease-state: available x-ms-lease-status: unlocked x-ms-server-encrypted: 'true' - x-ms-version: '2019-02-02' + x-ms-version: '2020-06-12' status: code: 200 message: OK - url: !!python/object/new:yarl.URL - state: !!python/tuple - - !!python/object/new:urllib.parse.SplitResult - - https - - pyacrstorageiqnubxlez5qu.blob.core.windows.net - - /utcontainer853e11a1/59466-0.txt - - '' - - '' + url: https://emilydevtest.blob.core.windows.net/utcontainer853e11a1/59466-0.txt version: 1 diff --git a/sdk/storage/azure-storage-blob/tests/test_common_blob.py b/sdk/storage/azure-storage-blob/tests/test_common_blob.py index 9ded9b100221..5e8712024490 100644 --- a/sdk/storage/azure-storage-blob/tests/test_common_blob.py +++ b/sdk/storage/azure-storage-blob/tests/test_common_blob.py @@ -1348,7 +1348,7 @@ def test_copy_blob_async_private_blob_with_sas(self, resource_group, location, s @GlobalStorageAccountPreparer() def test_abort_copy_blob(self, resource_group, location, storage_account, storage_account_key): self._setup(storage_account, storage_account_key) - source_blob = "http://www.gutenberg.org/files/59466/59466-0.txt" + source_blob = "https://www.gutenberg.org/files/59466/59466-0.txt" copied_blob = self.bsc.get_blob_client(self.container_name, '59466-0.txt') # Act diff --git a/sdk/storage/azure-storage-blob/tests/test_common_blob_async.py b/sdk/storage/azure-storage-blob/tests/test_common_blob_async.py index 102080da3379..0cafa8ca3865 100644 --- a/sdk/storage/azure-storage-blob/tests/test_common_blob_async.py +++ b/sdk/storage/azure-storage-blob/tests/test_common_blob_async.py @@ -1514,7 +1514,7 @@ async def test_copy_blob_async_private_blob_with_sas(self, resource_group, locat async def test_abort_copy_blob(self, resource_group, location, storage_account, storage_account_key): # Arrange await self._setup(storage_account, storage_account_key) - source_blob = "http://www.gutenberg.org/files/59466/59466-0.txt" + source_blob = "https://www.gutenberg.org/files/59466/59466-0.txt" copied_blob = self.bsc.get_blob_client(self.container_name, '59466-0.txt') # Act