Skip to content

Commit b7d9b30

Browse files
authored
[Packaging] Bump embedded Python version to 3.12.7 (#29887)
1 parent 8dfb199 commit b7d9b30

File tree

12 files changed

+105
-131
lines changed

12 files changed

+105
-131
lines changed

.azure-pipelines/breaking-change-tests.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@ jobs:
2222
fetchTags: true
2323
persistCredentials: true
2424
- task: UsePythonVersion@0
25-
displayName: 'Use Python 3.11'
25+
displayName: 'Use Python 3.12'
2626
inputs:
27-
versionSpec: 3.11
27+
versionSpec: 3.12
2828
- template: ${{ variables.Pipeline.Workspace }}/.azure-pipelines/templates/azdev_setup.yml
2929
- bash: |
3030
set -ev

azure-pipelines-full-tests.yml

+2-43
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,6 @@ jobs:
2525
matrix:
2626
Python39:
2727
python.version: '3.9'
28-
Python311:
29-
python.version: '3.11'
3028
Python312:
3129
python.version: '3.12'
3230
steps:
@@ -46,8 +44,6 @@ jobs:
4644
matrix:
4745
Python39:
4846
python.version: '3.9'
49-
Python311:
50-
python.version: '3.11'
5147
Python312:
5248
python.version: '3.12'
5349
steps:
@@ -67,8 +63,6 @@ jobs:
6763
matrix:
6864
Python39:
6965
python.version: '3.9'
70-
Python311:
71-
python.version: '3.11'
7266
Python312:
7367
python.version: '3.12'
7468
steps:
@@ -113,40 +107,6 @@ jobs:
113107
fullTest: true
114108
jobName: 'FullTest'
115109

116-
- job: AutomationFullTestPython311ProfileLatest
117-
displayName: Automation Full Test Python311 Profile Latest
118-
timeoutInMinutes: 9999
119-
strategy:
120-
maxParallel: 8
121-
matrix:
122-
instance1:
123-
Instance_idx: 1
124-
instance2:
125-
Instance_idx: 2
126-
instance3:
127-
Instance_idx: 3
128-
instance4:
129-
Instance_idx: 4
130-
instance5:
131-
Instance_idx: 5
132-
instance6:
133-
Instance_idx: 6
134-
instance7:
135-
Instance_idx: 7
136-
instance8:
137-
Instance_idx: 8
138-
pool:
139-
name: ${{ variables.ubuntu_pool }}
140-
steps:
141-
- template: .azure-pipelines/templates/automation_test.yml
142-
parameters:
143-
pythonVersion: '3.11'
144-
profile: 'latest'
145-
instance_cnt: '8'
146-
instance_idx: '$(Instance_idx)'
147-
fullTest: true
148-
jobName: 'FullTest'
149-
150110
- job: AutomationFullTestPython312ProfileLatest
151111
displayName: Automation Full Test Python312 Profile Latest
152112
timeoutInMinutes: 9999
@@ -187,16 +147,15 @@ jobs:
187147
- AutomationTest20190301
188148
- AutomationTest20180301
189149
- AutomationFullTestPython39ProfileLatest
190-
- AutomationFullTestPython311ProfileLatest
191150
condition: and(failed(), in(variables['Build.Reason'], 'BatchedCI'))
192151
displayName: Notify CI Errors
193152
pool:
194153
name: ${{ variables.ubuntu_pool }}
195154
steps:
196155
- task: UsePythonVersion@0
197-
displayName: 'Use Python 3.11'
156+
displayName: 'Use Python 3.12'
198157
inputs:
199-
versionSpec: 3.11
158+
versionSpec: 3.12
200159
- task: AzureCLI@2
201160
inputs:
202161
azureSubscription: 'Azure CLI'

azure-pipelines.yml

+50-57
Original file line numberDiff line numberDiff line change
@@ -129,9 +129,9 @@ jobs:
129129

130130
steps:
131131
- task: UsePythonVersion@0
132-
displayName: 'Use Python 3.11'
132+
displayName: 'Use Python 3.12'
133133
inputs:
134-
versionSpec: 3.11
134+
versionSpec: 3.12
135135

136136
- bash: ./scripts/ci/dependency_check.sh
137137
displayName: 'Verify src/azure-cli/requirements.py3.Linux.txt'
@@ -144,9 +144,9 @@ jobs:
144144

145145
steps:
146146
- task: UsePythonVersion@0
147-
displayName: 'Use Python 3.11'
147+
displayName: 'Use Python 3.12'
148148
inputs:
149-
versionSpec: 3.11
149+
versionSpec: 3.12
150150

151151
- bash: ./scripts/ci/dependency_check.sh
152152
displayName: 'Verify src/azure-cli/requirements.py3.Darwin.txt'
@@ -159,9 +159,9 @@ jobs:
159159

160160
steps:
161161
- task: UsePythonVersion@0
162-
displayName: 'Use Python 3.11'
162+
displayName: 'Use Python 3.12'
163163
inputs:
164-
versionSpec: 3.11
164+
versionSpec: 3.12
165165

166166
- task: BatchScript@1
167167
inputs:
@@ -176,9 +176,9 @@ jobs:
176176
name: ${{ variables.ubuntu_pool }}
177177
steps:
178178
- task: UsePythonVersion@0
179-
displayName: 'Use Python 3.11'
179+
displayName: 'Use Python 3.12'
180180
inputs:
181-
versionSpec: 3.11
181+
versionSpec: 3.12
182182
- template: .azure-pipelines/templates/azdev_setup.yml
183183
- bash: |
184184
set -ev
@@ -437,9 +437,9 @@ jobs:
437437
name: ${{ variables.ubuntu_pool }}
438438
steps:
439439
- task: UsePythonVersion@0
440-
displayName: 'Use Python 3.11'
440+
displayName: 'Use Python 3.12'
441441
inputs:
442-
versionSpec: 3.11
442+
versionSpec: 3.12
443443

444444
- task: PipAuthenticate@1
445445
condition: eq(variables['Build.SourceBranch'], 'refs/heads/release')
@@ -469,7 +469,12 @@ jobs:
469469

470470
- job: TestPythonWheel
471471
displayName: Test Python Wheels
472-
472+
strategy:
473+
matrix:
474+
Python39:
475+
python.version: '3.9'
476+
Python312:
477+
python.version: '3.12'
473478
dependsOn: BuildPythonWheel
474479
condition: succeeded()
475480
pool:
@@ -480,35 +485,23 @@ jobs:
480485
inputs:
481486
TargetPath: '$(Build.ArtifactStagingDirectory)/metadata'
482487
artifactName: metadata
483-
484-
485488
- task: DownloadPipelineArtifact@1
486489
displayName: 'Download PyPI Packages'
487490
inputs:
488491
TargetPath: '$(Build.ArtifactStagingDirectory)/pypi'
489492
artifactName: pypi
490-
491-
493+
- task: UsePythonVersion@0
494+
displayName: 'Use Python $(python.version)'
495+
inputs:
496+
versionSpec: '$(python.version)'
492497
- bash: |
493498
#!/usr/bin/env bash
494-
495-
# Verify the pip wheels
496-
497499
set -ex
498500
499501
CLI_VERSION=`cat $BUILD_ARTIFACTSTAGINGDIRECTORY/metadata/version`
500-
PYPI_FILES=$(cd $BUILD_ARTIFACTSTAGINGDIRECTORY/pypi; pwd)
501-
502-
echo "== Testing pip install on Python 3.9 =="
503-
docker run \
504-
--rm -v $PYPI_FILES:/mnt/pypi mcr.microsoft.com/mirror/docker/library/python:3.9-slim \
505-
/bin/bash -c "cd /mnt/pypi && ls && pip install --find-links ./ azure_cli-$CLI_VERSION*whl && az self-test && az --version && sleep 5"
506-
507-
echo "== Testing pip install on Python 3.11 =="
508-
docker run \
509-
--rm -v $PYPI_FILES:/mnt/pypi mcr.microsoft.com/mirror/docker/library/python:3.11-slim \
510-
/bin/bash -c "cd /mnt/pypi && ls && pip install --find-links ./ azure_cli-$CLI_VERSION*whl && az self-test && az --version && sleep 5"
511-
502+
echo "== Testing pip install on $PYTHON_VERSION =="
503+
cd $BUILD_ARTIFACTSTAGINGDIRECTORY/pypi
504+
pip install --find-links ./ azure_cli-$CLI_VERSION*whl && az self-test && az --version && sleep 5
512505
displayName: 'Test pip Install'
513506
514507
- job: TestCore
@@ -520,8 +513,8 @@ jobs:
520513
matrix:
521514
Python39:
522515
python.version: '3.9'
523-
Python311:
524-
python.version: '3.11'
516+
Python312:
517+
python.version: '3.12'
525518
steps:
526519
- template: .azure-pipelines/templates/automation_test.yml
527520
parameters:
@@ -537,8 +530,8 @@ jobs:
537530
matrix:
538531
Python39:
539532
python.version: '3.9'
540-
Python311:
541-
python.version: '3.11'
533+
Python312:
534+
python.version: '3.12'
542535
steps:
543536
- template: .azure-pipelines/templates/automation_test.yml
544537
parameters:
@@ -557,14 +550,14 @@ jobs:
557550
matrix:
558551
Python39:
559552
python.version: '3.9'
560-
Python311:
561-
python.version: '3.11'
553+
Python312:
554+
python.version: '3.12'
562555
steps:
563556
- task: UsePythonVersion@0
564557
displayName: 'Use Python $(python.version)'
565558
inputs:
566559
versionSpec: '$(python.version)'
567-
- bash: pip install --upgrade pip wheel
560+
- bash: pip install --upgrade pip wheel setuptools
568561
displayName: 'Install pip and wheel'
569562
- bash: ./scripts/ci/test_profile_integration.sh
570563
displayName: 'Run Integration Test against Profiles'
@@ -578,15 +571,15 @@ jobs:
578571
name: ${{ variables.ubuntu_pool }}
579572
strategy:
580573
matrix:
581-
Python311:
582-
python.version: '3.11'
574+
Python312:
575+
python.version: '3.12'
583576
steps:
584577
- task: UsePythonVersion@0
585578
displayName: 'Use Python $(python.version)'
586579
inputs:
587580
versionSpec: '$(python.version)'
588-
- bash: pip install --upgrade pip wheel
589-
displayName: 'Install pip and wheel'
581+
- bash: pip install --upgrade pip wheel setuptools
582+
displayName: 'Install pip and wheel setuptools'
590583
- bash: ./scripts/ci/test_extensions.sh
591584
displayName: 'Load extensions'
592585

@@ -623,7 +616,7 @@ jobs:
623616
-e CLI_VERSION=$CLI_VERSION \
624617
-e HOMEBREW_UPSTREAM_URL=$HOMEBREW_UPSTREAM_URL \
625618
--name azurecli \
626-
mcr.microsoft.com/mirror/docker/library/python:3.11-slim \
619+
mcr.microsoft.com/azurelinux/base/python:3 \
627620
/mnt/scripts/run.sh
628621
629622
# clean up
@@ -670,7 +663,7 @@ jobs:
670663
set -ev
671664
# Force relink [email protected] in Homebrew to resolve the conflict with pre-installed python 3.xx on macOS-12 image
672665
# See: https://github.com/Azure/azure-cli/issues/29054
673-
python_version=3.11
666+
python_version=3.12
674667
brew unlink python@$python_version && brew link --overwrite python@$python_version
675668
676669
echo == Remove pre-installed azure-cli ==
@@ -1050,9 +1043,9 @@ jobs:
10501043
name: ${{ variables.ubuntu_pool }}
10511044
steps:
10521045
- task: UsePythonVersion@0
1053-
displayName: 'Use Python 3.11'
1046+
displayName: 'Use Python 3.12'
10541047
inputs:
1055-
versionSpec: 3.11
1048+
versionSpec: 3.12
10561049
- template: .azure-pipelines/templates/azdev_setup.yml
10571050
- bash: |
10581051
set -ev
@@ -1066,9 +1059,9 @@ jobs:
10661059
name: ${{ variables.ubuntu_pool }}
10671060
steps:
10681061
- task: UsePythonVersion@0
1069-
displayName: 'Use Python 3.11'
1062+
displayName: 'Use Python 3.12'
10701063
inputs:
1071-
versionSpec: 3.11
1064+
versionSpec: 3.12
10721065
- template: .azure-pipelines/templates/azdev_setup.yml
10731066
- bash: |
10741067
set -ev
@@ -1083,8 +1076,8 @@ jobs:
10831076
matrix:
10841077
Python39:
10851078
python.version: '3.9'
1086-
Python311:
1087-
python.version: '3.11'
1079+
Python312:
1080+
python.version: '3.12'
10881081
pool:
10891082
name: ${{ variables.ubuntu_pool }}
10901083
steps:
@@ -1112,9 +1105,9 @@ jobs:
11121105
name: ${{ variables.ubuntu_pool }}
11131106
steps:
11141107
- task: UsePythonVersion@0
1115-
displayName: 'Use Python 3.11'
1108+
displayName: 'Use Python 3.12'
11161109
inputs:
1117-
versionSpec: 3.11
1110+
versionSpec: 3.12
11181111
- template: .azure-pipelines/templates/azdev_setup.yml
11191112
- bash: |
11201113
set -ev
@@ -1135,9 +1128,9 @@ jobs:
11351128
name: ${{ variables.ubuntu_pool }}
11361129
steps:
11371130
- task: UsePythonVersion@0
1138-
displayName: 'Use Python 3.11'
1131+
displayName: 'Use Python 3.12'
11391132
inputs:
1140-
versionSpec: 3.11
1133+
versionSpec: 3.12
11411134
- template: .azure-pipelines/templates/azdev_setup.yml
11421135
- bash: |
11431136
set -ev
@@ -1163,9 +1156,9 @@ jobs:
11631156
name: ${{ variables.ubuntu_pool }}
11641157
steps:
11651158
- task: UsePythonVersion@0
1166-
displayName: 'Use Python 3.11'
1159+
displayName: 'Use Python 3.12'
11671160
inputs:
1168-
versionSpec: 3.11
1161+
versionSpec: 3.12
11691162
- template: .azure-pipelines/templates/azdev_setup.yml
11701163
- bash: |
11711164
set -ev
@@ -1253,9 +1246,9 @@ jobs:
12531246
name: ${{ variables.ubuntu_pool }}
12541247
steps:
12551248
- task: UsePythonVersion@0
1256-
displayName: 'Use Python 3.11'
1249+
displayName: 'Use Python 3.12'
12571250
inputs:
1258-
versionSpec: 3.11
1251+
versionSpec: 3.12
12591252
- task: AzureCLI@2
12601253
inputs:
12611254
azureSubscription: 'Azure CLI'

0 commit comments

Comments
 (0)