Skip to content

Commit 881eacc

Browse files
committed
Merge branch 'master' of https://github.com/Azure/azure-sdk-for-python into add_warnings
* 'master' of https://github.com/Azure/azure-sdk-for-python: Implementation for Datasources operations (#11012) rename SearchIndexClient -> SearchClient (#10964) Servicebus - Track2 - Remove timeout from Send (#11002) Fixing compute test (#11036) fixing merge error (#11039) Update Ubuntu VM Image to 18.04 (#11032) add regular endpoint in new env variable (#11031)
2 parents 5ade091 + 157e7dd commit 881eacc

File tree

64 files changed

+2118
-219
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

64 files changed

+2118
-219
lines changed

eng/pipelines/autorest_checks.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
displayName: 'Run AutoRest'
2626

2727
pool:
28-
vmImage: 'ubuntu-16.04'
28+
vmImage: 'ubuntu-18.04'
2929

3030
steps:
3131
- task: NodeTool@0

eng/pipelines/generate-all-docs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
timeoutInMinutes: 120
2020

2121
pool:
22-
vmImage: 'ubuntu-16.04'
22+
vmImage: 'ubuntu-18.04'
2323

2424
steps:
2525
- task: UsePythonVersion@0

eng/pipelines/templates/jobs/archetype-sdk-client.yml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -10,31 +10,31 @@ parameters:
1010
TestMatrix:
1111
Linux_Python27:
1212
OSName: 'Linux'
13-
OSVmImage: 'ubuntu-16.04'
13+
OSVmImage: 'ubuntu-18.04'
1414
PythonVersion: '2.7'
1515
CoverageArg: ''
1616
RunForPR: true
1717
Linux_Python35:
1818
OSName: 'Linux'
19-
OSVmImage: 'ubuntu-16.04'
19+
OSVmImage: 'ubuntu-18.04'
2020
PythonVersion: '3.5'
2121
CoverageArg: ''
2222
RunForPR: false
2323
Linux_Python36:
2424
OSName: 'Linux'
25-
OSVmImage: 'ubuntu-16.04'
25+
OSVmImage: 'ubuntu-18.04'
2626
PythonVersion: '3.6'
2727
CoverageArg: ''
2828
RunForPR: false
2929
Linux_Python37:
3030
OSName: 'Linux'
31-
OSVmImage: 'ubuntu-16.04'
31+
OSVmImage: 'ubuntu-18.04'
3232
PythonVersion: '3.7'
3333
CoverageArg: ''
3434
RunForPR: false
3535
Linux_Python38:
3636
OSName: 'Linux'
37-
OSVmImage: 'ubuntu-16.04'
37+
OSVmImage: 'ubuntu-18.04'
3838
PythonVersion: '3.8'
3939
CoverageArg: ''
4040
RunForPR: true
@@ -52,7 +52,7 @@ parameters:
5252
RunForPR: false
5353
Linux_pypy3:
5454
OSName: 'Linux'
55-
OSVmImage: 'ubuntu-16.04'
55+
OSVmImage: 'ubuntu-18.04'
5656
PythonVersion: 'pypy3'
5757
CoverageArg: '--disablecov'
5858
RunForPR: false
@@ -64,7 +64,7 @@ jobs:
6464
- template: ../variables/globals.yml
6565

6666
pool:
67-
vmImage: 'ubuntu-16.04'
67+
vmImage: 'ubuntu-18.04'
6868

6969
steps:
7070
- template: ../steps/build-artifacts.yml
@@ -83,7 +83,7 @@ jobs:
8383
- 'Build'
8484

8585
pool:
86-
vmImage: 'ubuntu-16.04'
86+
vmImage: 'ubuntu-18.04'
8787

8888
steps:
8989
- template: ../steps/analyze.yml
@@ -156,7 +156,7 @@ jobs:
156156
- 'Build'
157157

158158
pool:
159-
vmImage: 'ubuntu-16.04'
159+
vmImage: 'ubuntu-18.04'
160160

161161
steps:
162162
- template: ../steps/run_mypy.yml
@@ -175,7 +175,7 @@ jobs:
175175
- 'Build'
176176

177177
pool:
178-
vmImage: 'ubuntu-16.04'
178+
vmImage: 'ubuntu-18.04'
179179

180180
steps:
181181
- template: ../steps/run_pylint.yml
@@ -194,7 +194,7 @@ jobs:
194194
- 'Build'
195195

196196
pool:
197-
vmImage: 'ubuntu-16.04'
197+
vmImage: 'ubuntu-18.04'
198198

199199
steps:
200200
- template: ../steps/test_regression.yml

eng/pipelines/templates/jobs/archetype-sdk-tests.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ parameters:
1515
Matrix:
1616
Linux_Python35:
1717
OSName: 'Linux'
18-
OSVmImage: 'ubuntu-16.04'
18+
OSVmImage: 'ubuntu-18.04'
1919
PythonVersion: '3.5'
2020
MacOs_Python37:
2121
OSName: 'MacOS'
@@ -27,11 +27,11 @@ parameters:
2727
PythonVersion: '2.7'
2828
Linux_PyPy3:
2929
OSName: 'Linux'
30-
OSVmImage: 'ubuntu-16.04'
30+
OSVmImage: 'ubuntu-18.04'
3131
PythonVersion: 'pypy3'
3232
Linux_Python38:
3333
OSName: 'Linux'
34-
OSVmImage: 'ubuntu-16.04'
34+
OSVmImage: 'ubuntu-18.04'
3535
PythonVersion: '3.8'
3636

3737
jobs:

eng/pipelines/templates/jobs/tests-nightly-python.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
timeoutInMinutes: 90
1111

1212
pool:
13-
vmImage: 'ubuntu-16.04'
13+
vmImage: 'ubuntu-18.04'
1414

1515
steps:
1616
- task: UsePythonVersion@0

eng/pipelines/templates/stages/archetype-python-release.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ stages:
1818
environment: github
1919

2020
pool:
21-
vmImage: ubuntu-16.04
21+
vmImage: ubuntu-18.04
2222

2323
strategy:
2424
runOnce:
@@ -50,7 +50,7 @@ stages:
5050
dependsOn: TagRepository
5151

5252
pool:
53-
vmImage: ubuntu-16.04
53+
vmImage: ubuntu-18.04
5454

5555
strategy:
5656
runOnce:
@@ -132,7 +132,7 @@ stages:
132132
dependsOn: PublishPackage
133133

134134
pool:
135-
vmImage: ubuntu-16.04
135+
vmImage: ubuntu-18.04
136136

137137
strategy:
138138
runOnce:
@@ -164,7 +164,7 @@ stages:
164164
variables:
165165
devFeedName: public/azure-sdk-for-python
166166
pool:
167-
vmImage: ubuntu-16.04
167+
vmImage: ubuntu-18.04
168168
steps:
169169
- checkout: none
170170
- download: current

sdk/compute/azure-mgmt-compute/setup.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,9 @@
3636
pass
3737

3838
# Version extraction inspired from 'requests'
39-
with open(os.path.join(package_folder_path, 'version.py'), 'r') as fd:
39+
with open(os.path.join(package_folder_path, 'version.py')
40+
if os.path.exists(os.path.join(package_folder_path, 'version.py'))
41+
else os.path.join(package_folder_path, '_version.py'), 'r') as fd:
4042
version = re.search(r'^VERSION\s*=\s*[\'"]([^\'"]*)[\'"]',
4143
fd.read(), re.MULTILINE).group(1)
4244

sdk/compute/azure-mgmt-compute/tests/test_cli_mgmt_compute.py

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -187,10 +187,13 @@ def test_compute(self, resource_group):
187187
INSTANCE_IDS = ["1"]
188188
LOG_ANALYTIC_NAME = "loganalytic"
189189

190-
191-
SUBNET = self.create_virtual_network(RESOURCE_GROUP, AZURE_LOCATION, NETWORK_NAME, SUBNET_NAME)
192-
NIC_ID = self.create_network_interface(RESOURCE_GROUP, AZURE_LOCATION, INTERFACE_NAME, SUBNET)
193-
# VAULT_ID, VAULT_URL, KEY_NAME = self.create_key(RESOURCE_GROUP, AZURE_LOCATION, KEY_VAULT, TENANT_ID)
190+
if self.is_live:
191+
SUBNET = self.create_virtual_network(RESOURCE_GROUP, AZURE_LOCATION, NETWORK_NAME, SUBNET_NAME)
192+
NIC_ID = self.create_network_interface(RESOURCE_GROUP, AZURE_LOCATION, INTERFACE_NAME, SUBNET)
193+
# VAULT_ID, VAULT_URL, KEY_NAME = self.create_key(RESOURCE_GROUP, AZURE_LOCATION, KEY_VAULT, TENANT_ID)
194+
else:
195+
SUBNET = "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/" + RESOURCE_GROUP + "/providers/Microsoft.Network/virtualNetworks/" + NETWORK_NAME + "/subnets/" + SUBNET_NAME
196+
NIC_ID = "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/" + RESOURCE_GROUP + "/providers/Microsoft.Network/networkInterfaces/" + INTERFACE_NAME
194197

195198
# Create an empty managed disk.[put]
196199
BODY = {

sdk/compute/azure-mgmt-compute/tests/test_mgmt_compute.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
# Licensed under the MIT License. See License.txt in the project root for
66
# license information.
77
#--------------------------------------------------------------------------
8+
89
import unittest
910

1011
from collections import namedtuple

0 commit comments

Comments
 (0)