8000 Merge branch 'main' into gh-100445 · hauntsaninja/cpython@78ca307 · GitHub
[go: up one dir, main page]

Skip to content

Commit 78ca307

Browse files
authored
Merge branch 'main' into pythongh-100445
2 parents a844eaf + 0b38ce4 commit 78ca307

File tree

292 files changed

+8992
-6204
lines changed

Some content is hidden

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

292 files changed

+8992
-6204
lines changed

.azure-pipelines/ci.yml

Lines changed: 0 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
variables:
2-
coverage: false
3-
41
trigger: ['main', '3.11', '3.10', '3.9', '3.8', '3.7']
52

63
jobs:
@@ -14,24 +11,6 @@ jobs:
1411
- template: ./prebuild-checks.yml
1512

1613

17-
- job: macOS_CI_Tests
18-
displayName: macOS CI Tests
19-
dependsOn: Prebuild
20-
#condition: and(succeeded(), eq(dependencies.Prebuild.outputs['tests.run'], 'true'))
21-
# bpo-39837: macOS tests on Azure Pipelines are disabled
22-
condition: false
23-
24-
variables:
25-
testRunTitle: '$(build.sourceBranchName)-macos'
26-
testRunPlatform: macos
27-
28-
pool:
29-
vmImage: macos-10.15
30-
31-
steps:
32-
- template: ./macos-steps.yml
33-
34-
3514
- job: Ubuntu_CI_Tests
3615
displayName: Ubuntu CI Tests
3716
dependsOn: Prebuild
@@ -51,33 +30,6 @@ jobs:
5130
dependencies: apt
5231

5332

54-
- job: Ubuntu_Coverage_CI_Tests
55-
displayName: Ubuntu CI Tests (coverage)
56-
dependsOn: Prebuild
57-
condition: |
58-
and(
59-
and(
60-
succeeded(),
61-
eq(variables['coverage'], 'true')
62-
),
63-
eq(dependencies.Prebuild.outputs['tests.run'], 'true')
64-
)
65-
66-
pool:
67-
vmImage: ubuntu-22.04
68-
69-
variables:
70-
testRunTitle: '$(Build.SourceBranchName)-linux-coverage'
71-
testRunPlatform: linux-coverage
72-
openssl_version: 1.1.1u
73-
74-
steps:
75-
- template: ./posix-steps.yml
76-
parameters:
77-
dependencies: apt
78-
coverage: true
79-
80-
8133
- job: Windows_CI_Tests
8234
displayName: Windows CI Tests
8335
dependsOn: Prebuild

.azure-pipelines/macos-steps.yml

Lines changed: 0 additions & 27 deletions
This file was deleted.

.azure-pipelines/posix-steps.yml

Lines changed: 9 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
parameters:
2-
coverage: false
32
sudo_dependencies: sudo
43
dependencies: apt
54
patchcheck: true
@@ -23,47 +22,16 @@ steps:
2322
- script: make -j4
2423
displayName: 'Build CPython'
2524

26-
- ${{ if eq(parameters.coverage, 'true') }}:
27-
- script: ./python -m venv venv && ./venv/bin/python -m pip install -U coverage
28-
displayName: 'Set up virtual environment'
25+
- script: make pythoninfo
26+
displayName: 'Display build info'
2927

30-
- script: ./venv/bin/python -m test.pythoninfo
31-
displayName: 'Display build info'
32-
33-
- script: |
34-
$COMMAND -m coverage run --pylib -m test \
35-
--fail-env-changed \
36-
-uall,-cpu \
37-
--junit-xml=$(build.binariesDirectory)/test-results.xml \
38-
-x test_multiprocessing_fork \
39-
-x test_multiprocessing_forkserver \
40-
-x test_multiprocessing_spawn \
41-
-x test_concurrent_futures
42-
displayName: 'Tests with coverage'
43-
env:
44-
${{ if eq(parameters.xvfb, 'true') }}:
45-
COMMAND: xvfb-run ./venv/bin/python
46-
${{ if ne(parameters.xvfb, 'true') }}:
47-
COMMAND: ./venv/bin/python
48-
49-
- script: ./venv/bin/python -m coverage xml
50-
displayName: 'Generate coverage.xml'
51-
52-
- script: source ./venv/bin/activate && bash <(curl -s https://codecov.io/bash) -y .github/codecov.yml
53-
displayName: 'Publish code coverage results'
54-
55-
56-
- ${{ if ne(parameters.coverage, 'true') }}:
57-
- script: make pythoninfo
58-
displayName: 'Display build info'
59-
60-
- script: $COMMAND buildbottest TESTOPTS="-j4 -uall,-cpu --junit-xml=$(build.binariesDirectory)/test-results.xml"
61-
displayName: 'Tests'
62-
env:
63-
${{ if eq(parameters.xvfb, 'true') }}:
64-
COMMAND: xvfb-run make
65-
${{ if ne(parameters.xvfb, 'true') }}:
66-
COMMAND: make
28+
- script: $COMMAND buildbottest TESTOPTS="-j4 -uall,-cpu --junit-xml=$(build.binariesDirectory)/test-results.xml"
29+
displayName: 'Tests'
30+
env:
31+
${{ if eq(parameters.xvfb, 'true') }}:
32+
COMMAND: xvfb-run make
33+
${{ if ne(parameters.xvfb, 'true') }}:
34+
COMMAND: make
6735

6836
- ${{ if eq(parameters.patchcheck, 'true') }}:
6937
- script: |

.azure-pipelines/pr.yml

Lines changed: 0 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
variables:
2-
coverage: false
3-
41
pr: ['main', '3.11', '3.10', '3.9', '3.8', '3.7']
52

63
jobs:
@@ -14,26 +11,6 @@ jobs:
1411
- template: ./prebuild-checks.yml
1512

1613

17-
- job: macOS_PR_Tests
18-
displayName: macOS PR Tests
19-
dependsOn: Prebuild
20-
#condition: and(succeeded(), eq(dependencies.Prebuild.outputs['tests.run'], 'true'))
21-
# b F41A po-39837: macOS tests on Azure Pipelines are disabled
22-
condition: false
23-
24-
variables:
25-
testRunTitle: '$(system.pullRequest.TargetBranch)-macos'
26-
testRunPlatform: macos
27-
28-
pool:
29-
vmImage: macos-10.15
30-
31-
steps:
32-
- template: ./macos-steps.yml
33-
parameters:
34-
targetBranch: $(System.PullRequest.TargetBranch)
35-
36-
3714
- job: Ubuntu_PR_Tests
3815
displayName: Ubuntu PR Tests
3916
dependsOn: Prebuild
@@ -53,33 +30,6 @@ jobs:
5330
dependencies: apt
5431

5532

56-
- job: Ubuntu_Coverage_PR_Tests
57-
displayName: Ubuntu PR Tests (coverage)
58-
dependsOn: Prebuild
59-
condition: |
60-
and(
61-
and(
62-
succeeded(),
63-
eq(variables['coverage'], 'true')
64-
),
65-
eq(dependencies.Prebuild.outputs['tests.run'], 'true')
66-
)
67-
68-
pool:
69-
vmImage: ubuntu-22.04
70-
71-
variables:
72-
testRunTitle: '$(Build.SourceBranchName)-linux-coverage'
73-
testRunPlatform: linux-coverage
74-
openssl_version: 1.1.1u
75-
76-
steps:
77-
- template: ./posix-steps.yml
78-
parameters:
79-
dependencies: apt
80-
coverage: true
81-
82-
8333
- job: Windows_PR_Tests
8434
displayName: Windows PR Tests
8535
dependsOn: Prebuild

.cirrus.yml renamed to .cirrus-DISABLED.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
# gh-91960: Job disabled since Python is out of free credit (September 2023):
2+
# https://discuss.python.org/t/freebsd-gets-a-new-cirrus-ci-github-action-job-and-a-new-buildbot/33122/26
3+
14
freebsd_task:
25
freebsd_instance:
36
matrix:
@@ -10,13 +13,16 @@ freebsd_task:
1013
sysctl_script:
1114
- sysctl net.inet.tcp.blackhole=0
1215
- sysctl net.inet.udp.blackhole=0
13-
build_script:
16+
configure_script:
1417
- mkdir build
1518
- cd build
1619
- ../configure --with-pydebug
20+
build_script:
21+
- cd build
1722
- make -j$(sysctl -n hw.ncpu)
1823
pythoninfo_script:
19-
- cd build && make pythoninfo
24+
- cd build
25+
- make pythoninfo
2026
test_script:
2127
- cd build
2228
# dtrace fails to build on FreeBSD - see gh-73263

.gitattributes

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ PC/classicAppCompat.* binary
2424
[attr]noeol -text
2525

2626
Lib/test/cjkencodings/* noeol
27-
Lib/test/coding20731.py noeol
27+
Lib/test/tokenizedata/coding20731.py noeol
2828
Lib/test/decimaltestdata/*.decTest noeol
2929
Lib/test/test_email/data/*.txt noeol
3030
Lib/test/test_importlib/resources/data01/* noeol

.github/CODEOWNERS

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99

1010
# pre-commit
1111
.pre-commit-config.yaml @hugovk @AlexWaygood
12+
.ruff.toml @hugovk @AlexWaygood
1213

1314
# Build system
1415
configure* @erlend-aasland @corona10
@@ -179,3 +180,6 @@ Doc/c-api/stable.rst @encukou
179180
/Tools/clinic/** @erlend-aasland @AlexWaygood
180181
/Lib/test/test_clinic.py @erlend-aasland @AlexWaygood
181182
Doc/howto/clinic.rst @erlend-aasland
183+
184+
# WebAssembly
185+
/Tools/wasm/ @brettcannon

.github/workflows/build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ jobs:
6363
# into the PR branch anyway.
6464
#
6565
# https://github.com/python/core-workflow/issues/373
66-
git diff --name-only origin/$GITHUB_BASE_REF.. | grep -qvE '(\.rst$|^Doc|^Misc)' && echo "run_tests=true" >> $GITHUB_OUTPUT || true
66+
git diff --name-only origin/$GITHUB_BASE_REF.. | grep -qvE '(\.rst$|^Doc|^Misc|^\.pre-commit-config\.yaml$|\.ruff\.toml$)' && echo "run_tests=true" >> $GITHUB_OUTPUT || true
6767
fi
6868
6969
# Check if we should run hypothesis tests

.github/workflows/lint.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,10 @@ on: [push, pull_request, workflow_dispatch]
55
permissions:
66
contents: read
77

8+
env:
9+
FORCE_COLOR: 1
10+
RUFF_FORMAT: github
11+
812
concurrency:
913
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
1014
cancel-in-progress: true

.github/workflows/require-pr-label.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ on:
55
types: [opened, reopened, labeled, unlabeled, synchronize]
66

77
permissions:
8-
issues: read
9-
pull-requests: read
8+
issues: write
9+
pull-requests: write
1010

1111
jobs:
1212
label:

0 commit comments

Comments
 (0)
0