Skip to content

Commit 21fda3c

Browse files
authored
Revert images to previous API version (Azure#4931)
1 parent ca9dba4 commit 21fda3c

File tree

7 files changed

+21
-8
lines changed

7 files changed

+21
-8
lines changed

azure-mgmt-compute/HISTORY.rst

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,19 @@
22
33
Release History
44
===============
5+
6+
4.6.2 (2019-04-22)
7+
++++++++++++++++++
8+
9+
**Bugfix**
10+
11+
- Revert "images" API version introduced in 4.6.0 from 2019-03-01 to 2018-10-01 for backward compatiblity #4891
12+
513
4.6.1 (2019-04-18)
614
++++++++++++++++++
715

816
**Bugfixes**
17+
918
- Make enum declarations in Compute package consistent, for the sake of code inspection.
1019

1120
4.6.0 (2019-04-12)

azure-mgmt-compute/azure/mgmt/compute/compute_management_client.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,7 @@ class ComputeManagementClient(MultiApiClientMixin, SDKClient):
8787
'resource_skus': '2017-09-01',
8888
'disks': '2018-09-30',
8989
'snapshots': '2018-09-30',
90+
'images': '2018-10-01',
9091
'proximity_placement_groups': '2018-10-01',
9192
None: DEFAULT_API_VERSION
9293
}},

azure-mgmt-compute/azure/mgmt/compute/models.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@
77
import warnings
88

99
from .v2017_09_01.models import *
10-
from .v2018_10_01.models import *
1110
from .v2018_09_30.models import *
11+
from .v2018_10_01.models import *
1212
from .v2019_03_01.models import * # Note that this line is overriding some models of 2018-09-01. See link below for details.
1313

1414
warnings.warn("Import models from this file is deprecated. See https://aka.ms/pysdkmodels",

azure-mgmt-compute/azure/mgmt/compute/version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@
55
# license information.
66
# --------------------------------------------------------------------------
77

8-
VERSION = "4.6.1"
8+
VERSION = "4.6.2"

azure-mgmt-compute/tests/recordings/test_mgmt_managed_disks.test_create_image_from_blob.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ interactions:
1414
accept-language: [en-US]
1515
x-ms-client-request-id: [aaefdaec-5d36-11e7-af9e-ecb1d756380e]
1616
method: PUT
17-
uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_managed_disks_test_create_image_from_blob1cfb14b2/providers/Microsoft.Compute/images/myImage?api-version=2019-03-01
17+
uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_managed_disks_test_create_image_from_blob1cfb14b2/providers/Microsoft.Compute/images/myImage?api-version=2018-10-01
1818
response:
1919
body: {string: "{\r\n \"properties\": {\r\n \"storageProfile\": {\r\n \"osDisk\":
2020
{\r\n \"osType\": \"Linux\",\r\n \"osState\": \"Generalized\",\r\n
@@ -24,7 +24,7 @@ interactions:
2424
\ \"location\": \"westus\",\r\n \"id\": \"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_managed_disks_test_create_image_from_blob1cfb14b2/providers/Microsoft.Compute/images/myImage\",\r\n
2525
\ \"name\": \"myImage\"\r\n}"}
2626
headers:
27-
Azure-AsyncOperation: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Compute/locations/westus/operations/53c76029-51ee-40c5-843a-3ab96eba05f4?api-version=2019-03-01']
27+
Azure-AsyncOperation: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Compute/locations/westus/operations/53c76029-51ee-40c5-843a-3ab96eba05f4?api-version=2018-10-01']
2828
Cache-Control: [no-cache]
2929
Content-Length: ['622']
3030
Content-Type: [application/json; charset=utf-8]
@@ -51,7 +51,7 @@ interactions:
5151
accept-language: [en-US]
5252
x-ms-client-request-id: [aaefdaec-5d36-11e7-af9e-ecb1d756380e]
5353
method: GET
54-
uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Compute/locations/westus/operations/53c76029-51ee-40c5-843a-3ab96eba05f4?api-version=2019-03-01
54+
uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Compute/locations/westus/operations/53c76029-51ee-40c5-843a-3ab96eba05f4?api-version=2018-10-01
5555
response:
5656
body: {string: "{\r\n \"startTime\": \"2017-06-30T01:51:43.9432726+00:00\",\r\n
5757
\ \"endTime\": \"2017-06-30T01:52:04.5545491+00:00\",\r\n \"status\": \"Succeeded\",\r\n
@@ -85,7 +85,7 @@ interactions:
8585
accept-language: [en-US]
8686
x-ms-client-request-id: [aaefdaec-5d36-11e7-af9e-ecb1d756380e]
8787
method: GET
88-
uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_managed_disks_test_create_image_from_blob1cfb14b2/providers/Microsoft.Compute/images/myImage?api-version=2019-03-01
88+
uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test_mgmt_managed_disks_test_create_image_from_blob1cfb14b2/providers/Microsoft.Compute/images/myImage?api-version=2018-10-01
8989
response:
9090
body: {string: "{\r\n \"properties\": {\r\n \"storageProfile\": {\r\n \"osDisk\":
9191
{\r\n \"osType\": \"Linux\",\r\n \"osState\": \"Generalized\",\r\n

azure-mgmt-compute/tests/test_mgmt_managed_disks.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ def test_md_from_storage_blob(self, resource_group, location):
9393
'location': location,
9494
'creation_data': {
9595
'create_option': DiskCreateOption.import_enum,
96-
'source_uri': 'https://mystorageaccount.blob.core.windows.net/inputtestdatadonotdelete/ubuntu.vhd'
96+
'source_uri': self.settings.LINUX_OS_VHD # 'https://mystorageaccount.blob.core.windows.net/inputtestdatadonotdelete/ubuntu.vhd'
9797
}
9898
}
9999
)
@@ -275,7 +275,7 @@ def test_create_image_from_blob(self, resource_group, location):
275275
'os_disk': {
276276
'os_type': 'Linux',
277277
'os_state': "Generalized",
278-
'blob_uri': 'https://mystorageaccount.blob.core.windows.net/inputtestdatadonotdelete/ubuntu.vhd',
278+
'blob_uri': self.settings.LINUX_OS_VHD, # 'https://mystorageaccount.blob.core.windows.net/inputtestdatadonotdelete/ubuntu.vhd'
279279
'caching': "ReadWrite",
280280
}
281281
}

azure-sdk-tools/devtools_testutils/mgmt_settings_fake.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,9 @@
2626
HDI_ADLS_ACCOUNT_NAME = 'fakehdiadlsaccount'
2727
HDI_ADLS_CLIENT_ID = '00000000-0000-0000-0000-000000000000'
2828

29+
# Ubuntu image
30+
LINUX_OS_VHD = "https://mystorageaccount.blob.core.windows.net/inputtestdatadonotdelete/ubuntu.vhd"
31+
2932
# Read for details of this file:
3033
# https://github.com/Azure/azure-sdk-for-python/wiki/Contributing-to-the-tests
3134

0 commit comments

Comments
 (0)