Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 05ea06d

Browse files
authored
Merge branch 'main' into exc_info-contextlib
2 parents 50d77b0 + 7c95345 commit 05ea06d

File tree

977 files changed

+53256
-43522
lines changed

Some content is hidden

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

977 files changed

+53256
-43522
lines changed

.azure-pipelines/ci.yml

Lines changed: 2 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -14,20 +14,6 @@ jobs:
1414
- template: ./prebuild-checks.yml
1515

1616

17-
- job: Docs_PR
18-
displayName: Docs PR
19-
dependsOn: Prebuild
20-
condition: and(succeeded(), eq(dependencies.Prebuild.outputs['docs.run'], 'true'))
21-
22-
pool:
23-
vmImage: ubuntu-22.04
24-
25-
steps:
26-
- template: ./docs-steps.yml
27-
parameters:
28-
upload: true
29-
30-
3117
- job: macOS_CI_Tests
3218
displayName: macOS CI Tests
3319
dependsOn: Prebuild
@@ -57,7 +43,7 @@ jobs:
5743
variables:
5844
testRunTitle: '$(build.sourceBranchName)-linux'
5945
testRunPlatform: linux
60-
openssl_version: 1.1.1t
46+
openssl_version: 1.1.1u
6147

6248
steps:
6349
- template: ./posix-steps.yml
@@ -83,7 +69,7 @@ jobs:
8369
variables:
8470
testRunTitle: '$(Build.SourceBranchName)-linux-coverage'
8571
testRunPlatform: linux-coverage
86-
openssl_version: 1.1.1t
72+
openssl_version: 1.1.1u
8773

8874
steps:
8975
- template: ./posix-steps.yml

.azure-pipelines/docs-steps.yml

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

.azure-pipelines/pr.yml

Lines changed: 2 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -14,18 +14,6 @@ jobs:
1414
- template: ./prebuild-checks.yml
1515

1616

17-
- job: Docs_PR
18-
displayName: Docs PR
19-
dependsOn: Prebuild
20-
condition: and(succeeded(), eq(dependencies.Prebuild.outputs['docs.run'], 'true'))
21-
22-
pool:
23-
vmImage: ubuntu-22.04
24-
25-
steps:
26-
- template: ./docs-steps.yml
27-
28-
2917
- job: macOS_PR_Tests
3018
displayName: macOS PR Tests
3119
dependsOn: Prebuild
@@ -57,7 +45,7 @@ jobs:
5745
variables:
5846
testRunTitle: '$(system.pullRequest.TargetBranch)-linux'
5947
testRunPlatform: linux
60-
openssl_version: 1.1.1t
48+
openssl_version: 1.1.1u
6149

6250
steps:
6351
- template: ./posix-steps.yml
@@ -83,7 +71,7 @@ jobs:
8371
variables:
8472
testRunTitle: '$(Build.SourceBranchName)-linux-coverage'
8573
testRunPlatform: linux-coverage
86-
openssl_version: 1.1.1t
74+
openssl_version: 1.1.1u
8775

8876
steps:
8977
- template: ./posix-steps.yml

.azure-pipelines/prebuild-checks.yml

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -11,18 +11,6 @@ steps:
1111
displayName: Fetch comparison tree
1212
condition: and(succeeded(), variables['System.PullRequest.TargetBranch'])
1313

14-
- script: |
15-
if ! git diff --name-only $(diffTarget) | grep -qE '(\.rst$|^Doc|^Misc)'
16-
then
17-
echo "No docs were updated: docs.run=false"
18-
echo "##vso[task.setvariable variable=run;isOutput=true]false"
19-
else
20-
echo "Docs were updated: docs.run=true"
21-
echo "##vso[task.setvariable variable=run;isOutput=true]true"
22-
fi
23-
displayName: Detect documentation changes
24-
name: docs
25-
2614
- script: |
2715
if ! git diff --name-only $(diffTarget) | grep -qvE '(\.rst$|^Doc|^Misc)'
2816
then

.coveragerc

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
[run]
2+
branch = True
3+
4+
[report]
5+
# Regexes for lines to exclude from consideration
6+
exclude_lines =
7+
# Don't complain if non-runnable code isn't run:
8+
if 0:
9+
if __name__ == .__main__.:
10+
11+
.*# pragma: no cover
12+
.*# pragma: no branch
13+
14+
# Additions for IDLE:
15+
.*# htest #
16+
if not (_htest or _utest):
17+
if not .*_utest:
18+
if .*_htest:
19+

.gitattributes

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,9 @@ Parser/parser.c generated
8585
Parser/token.c generated
8686
Programs/test_frozenmain.h generated
8787
Python/Python-ast.c generated
88+
Python/executor_cases.c.h generated
8889
Python/generated_cases.c.h generated
90+
Include/internal/pycore_opcode_metadata.h generated
8991
Python/opcode_targets.h generated
9092
Python/stdlib_module_names.h generated
9193
Tools/peg_generator/pegen/grammar_parser.py generated

.github/CODEOWNERS

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ Python/traceback.c @iritkatriel
6868
/Tools/build/parse_html5_entities.py @ezio-melotti
6969

7070
# Import (including importlib).
71-
**/*import* @brettcannon @encukou @ericsnowcurrently @ncoghlan @warsaw
71+
**/*import* @brettcannon @ericsnowcurrently @ncoghlan @warsaw
7272
**/*importlib/resources/* @jaraco @warsaw @FFY00
7373
**/importlib/metadata/* @jaraco @warsaw
7474

@@ -79,7 +79,7 @@ Doc/library/time.rst @pganssle @abalkin
7979
Lib/test/test_time.py @pganssle @abalkin
8080
Modules/timemodule.c @pganssle @abalkin
8181
Python/pytime.c @pganssle @abalkin
82-
Include/pytime.h @pganssle @abalkin
82+
Include/internal/pycore_time.h @pganssle @abalkin
8383

8484
# Email and related
8585
**/*mail* @python/email-team
@@ -118,6 +118,12 @@ Lib/ast.py @isidentical
118118
/Lib/test/test_subprocess.py @gpshead
119119
/Modules/*subprocess* @gpshead
120120

121+
# Limited C API & stable ABI
122+
Tools/build/stable_abi.py @encukou
123+
Misc/stable_abi.toml @encukou
124+
Doc/data/*.abi @encukou
125+
Doc/c-api/stable.rst @encukou
126+
121127
# Windows
122128
/PC/ @python/windows-team
123129
/PCbuild/ @python/windows-team
@@ -167,3 +173,7 @@ Lib/ast.py @isidentical
167173

168174
# zipfile.Path
169175
**/*zipfile/*_path.py @jaraco
176+
177+
# Argument Clinic
178+
/Tools/clinic/** @erlend-aasland @AlexWaygood
179+
/Lib/test/test_clinic.py @erlend-aasland @AlexWaygood

.github/workflows/build.yml

Lines changed: 69 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,7 @@ jobs:
8989
Doc/**
9090
Misc/**
9191
.github/workflows/reusable-docs.yml
92+
format: csv # works for paths with spaces
9293
- name: Check for docs changes
9394
if: >-
9495
github.event_name == 'pull_request'
@@ -123,10 +124,10 @@ jobs:
123124
run: echo "PATH=/usr/lib/ccache:$PATH" >> $GITHUB_ENV
124125
- name: Configure ccache action
125126
uses: hendrikmuhs/[email protected]
126-
- name: Check Autoconf version 2.69 and aclocal 1.16.3
127+
- name: Check Autoconf and aclocal versions
127128
run: |
128-
grep "Generated by GNU Autoconf 2.69" configure
129-
grep "aclocal 1.16.3" aclocal.m4
129+
grep "Generated by GNU Autoconf 2.71" configure
130+
grep "aclocal 1.16.4" aclocal.m4
130131
grep -q "runstatedir" configure
131132
grep -q "PKG_PROG_PKG_CONFIG" aclocal.m4
132133
- name: Configure CPython
@@ -219,17 +220,16 @@ jobs:
219220
path: config.cache
220221
key: ${{ github.job }}-${{ runner.os }}-${{ needs.check_source.outputs.config_hash }}
221222
- name: Install Homebrew dependencies
222-
run: brew install pkg-config openssl@1.1 xz gdbm tcl-tk
223+
run: brew install pkg-config openssl@3.0 xz gdbm tcl-tk
223224
- name: Configure CPython
224225
run: |
225-
CFLAGS="-I$(brew --prefix gdbm)/include -I$(brew --prefix xz)/include" \
226-
LDFLAGS="-L$(brew --prefix gdbm)/lib -I$(brew --prefix xz)/lib" \
227-
PKG_CONFIG_PATH="$(brew --prefix tcl-tk)/lib/pkgconfig" \
226+
GDBM_CFLAGS="-I$(brew --prefix gdbm)/include" \
227+
GDBM_LIBS="-L$(brew --prefix gdbm)/lib -lgdbm" \
228228
./configure \
229229
--config-cache \
230230
--with-pydebug \
231231
--prefix=/opt/python-dev \
232-
--with-openssl="$(brew --prefix openssl@1.1)"
232+
--with-openssl="$(brew --prefix openssl@3.0)"
233233
- name: Build CPython
234234
run: make -j4
235235
- name: Display build info
@@ -244,7 +244,7 @@ jobs:
244244
needs: check_source
245245
if: needs.check_source.outputs.run_tests == 'true'
246246
env:
247-
OPENSSL_VER: 1.1.1t
247+
OPENSSL_VER: 1.1.1u
248248
PYTHONSTRICTEXTENSIONBUILD: 1
249249
steps:
250250
- uses: actions/checkout@v3
@@ -313,7 +313,7 @@ jobs:
313313
strategy:
314314
fail-fast: false
315315
matrix:
316-
openssl_ver: [1.1.1t, 3.0.8, 3.1.0-beta1]
316+
openssl_ver: [1.1.1u, 3.0.9, 3.1.1]
317317
env:
318318
OPENSSL_VER: ${{ matrix.openssl_ver }}
319319
MULTISSL_DIR: ${{ github.workspace }}/multissl
@@ -365,7 +365,7 @@ jobs:
365365
needs: check_source
366366
if: needs.check_source.outputs.run_tests == 'true' && needs.check_source.outputs.run_hypothesis == 'true'
367367
env:
368-
OPENSSL_VER: 1.1.1t
368+
OPENSSL_VER: 1.1.1u
369369
PYTHONSTRICTEXTENSIONBUILD: 1
370370
steps:
371371
- uses: actions/checkout@v3
@@ -474,7 +474,7 @@ jobs:
474474
needs: check_source
475475
if: needs.check_source.outputs.run_tests == 'true'
476476
env:
477-
OPENSSL_VER: 1.1.1t
477+
OPENSSL_VER: 1.1.1u
478478
PYTHONSTRICTEXTENSIONBUILD: 1
479479
ASAN_OPTIONS: detect_leaks=0:allocator_may_return_null=1:handle_segv=0
480480
steps:
@@ -519,3 +519,60 @@ jobs:
519519
run: make pythoninfo
520520
- name: Tests
521521
run: xvfb-run make buildbottest TESTOPTS="-j4 -uall,-cpu"
522+
523+
all-required-green: # This job does nothing and is only used for the branch protection
524+
name: All required checks pass
525+
if: always()
526+
527+
needs:
528+
- check_source # Transitive dependency, needed to access `run_tests` value
529+
- check-docs
530+
- check_generated_files
531+
- build_win32
532+
- build_win_amd64
533+
- build_macos
534+
- build_ubuntu
535+
- build_ubuntu_ssltests
536+
- test_hypothesis
537+
- build_asan
538+
539+
runs-on: ubuntu-latest
540+
541+
steps:
542+
- name: Check whether the needed jobs succeeded or failed
543+
uses: re-actors/alls-green@05ac9388f0aebcb5727afa17fcccfecd6f8ec5fe
544+
with:
545+
allowed-failures: >-
546+
build_macos,
547+
build_ubuntu_ssltests,
548+
build_win32,
549+
test_hypothesis,
550+
allowed-skips: >-
551+
${{
552+
!fromJSON(needs.check_source.outputs.run-docs)
553+
&& '
554+
check-docs,
555+
'
556+
|| ''
557+
}}
558+
${{
559+
needs.check_source.outputs.run_tests != 'true'
560+
&& '
561+
check_generated_files,
562+
build_win32,
563+
build_win_amd64,
564+
build_macos,
565+
build_ubuntu,
566+
build_ubuntu_ssltests,
567+
build_asan,
568+
'
569+
|| ''
570+
}}
571+
${{
572+
!fromJSON(needs.check_source.outputs.run_hypothesis)
573+
&& '
574+
test_hypothesis,
575+
'
576+
|| ''
577+
}}
578+
jobs: ${{ toJSON(needs) }}

.github/workflows/new-bugs-announce-notifier.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,10 @@ jobs:
4141
url : issue.data.html_url,
4242
labels : issue.data.labels.map(label => { return label.name }).join(", "),
4343
assignee : issue.data.assignees.map(assignee => { return assignee.login }),
44-
body : issue.data.body
44+
// We need to truncate the body size, because the max size for
45+
// the whole payload is 16kb. We want to be safe and assume that
46+
// body can take up to ~8kb of space.
47+
body : issue.data.body.substring(0, 8000)
4548
};
4649
4750
const data = {

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
timeout-minutes: 10
1616

1717
steps:
18-
- uses: mheap/github-action-required-labels@v4
18+
- uses: mheap/github-action-required-labels@v5
1919
with:
2020
mode: exactly
2121
count: 0

0 commit comments

Comments
 (0)