Skip to content

Commit ffae37c

Browse files
Merge branch 'main' into isotp
2 parents 73b4b98 + 2a5cdb2 commit ffae37c

1,481 files changed

Lines changed: 97713 additions & 66067 deletions

File tree

Some content is hidden

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

.azure-pipelines/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
trigger: ['main', '3.12', '3.11', '3.10', '3.9', '3.8', '3.7']
1+
trigger: ['main', '3.13', '3.12', '3.11', '3.10', '3.9', '3.8']
22

33
jobs:
44
- job: Prebuild

.azure-pipelines/posix-deps-apt.sh

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

.azure-pipelines/posix-steps.yml

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

.azure-pipelines/pr.yml

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

.devcontainer/Dockerfile

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

.devcontainer/devcontainer.json

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
{
2-
"build": {
3-
"dockerfile": "Dockerfile"
4-
},
2+
"image": "ghcr.io/python/devcontainer:2024.09.25.11038928730",
53
"onCreateCommand": [
64
// Install common tooling.
75
"dnf",

.gitattributes

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,6 @@ Lib/test/cjkencodings/* noeol
2727
Lib/test/tokenizedata/coding20731.py noeol
2828
Lib/test/decimaltestdata/*.decTest noeol
2929
Lib/test/test_email/data/*.txt noeol
30-
Lib/test/test_importlib/resources/data01/* noeol
31-
Lib/test/test_importlib/resources/namespacedata01/* noeol
3230
Lib/test/xmltestdata/* noeol
3331

3432
# Shell scripts should have LF even on Windows because of Cygwin

.github/CODEOWNERS

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -33,11 +33,11 @@ Objects/frameobject.c @markshannon
3333
Objects/call.c @markshannon
3434
Python/ceval*.c @markshannon
3535
Python/ceval*.h @markshannon
36+
Python/codegen.c @markshannon @iritkatriel
3637
Python/compile.c @markshannon @iritkatriel
3738
Python/assemble.c @markshannon @iritkatriel
3839
Python/flowgraph.c @markshannon @iritkatriel
3940
Python/instruction_sequence.c @iritkatriel
40-
Python/ast_opt.c @isidentical
4141
Python/bytecodes.c @markshannon
4242
Python/optimizer*.c @markshannon
4343
Python/optimizer_analysis.c @Fidget-Spinner
@@ -157,10 +157,12 @@ Include/internal/pycore_time.h @pganssle @abalkin
157157
/Tools/cases_generator/ @markshannon
158158

159159
# AST
160-
Python/ast.c @isidentical @JelleZijlstra
161-
Parser/asdl.py @isidentical @JelleZijlstra
162-
Parser/asdl_c.py @isidentical @JelleZijlstra
163-
Lib/ast.py @isidentical @JelleZijlstra
160+
Python/ast.c @isidentical @JelleZijlstra @eclips4
161+
Python/ast_opt.c @isidentical @eclips4
162+
Parser/asdl.py @isidentical @JelleZijlstra @eclips4
163+
Parser/asdl_c.py @isidentical @JelleZijlstra @eclips4
164+
Lib/ast.py @isidentical @JelleZijlstra @eclips4
165+
Lib/test/test_ast/ @eclips4
164166

165167
# Mock
166168
/Lib/unittest/mock.py @cjw296
@@ -205,14 +207,14 @@ Doc/c-api/stable.rst @encukou
205207
**/*bisect* @rhettinger
206208
**/*heapq* @rhettinger
207209
**/*functools* @rhettinger
208-
**/*decimal* @rhettinger
209210

210211
**/*dataclasses* @ericvsmith
211212

212213
**/*ensurepip* @pfmoore @pradyunsg
213214

214-
**/*idlelib* @terryjreedy
215215
/Doc/library/idle.rst @terryjreedy
216+
**/*idlelib* @terryjreedy
217+
**/*turtledemo* @terryjreedy
216218

217219
**/*annotationlib* @JelleZijlstra
218220
**/*typing* @JelleZijlstra @AlexWaygood
@@ -275,3 +277,8 @@ Lib/test/test_interpreters/ @ericsnowcurrently
275277
# Config Parser
276278
Lib/configparser.py @jaraco
277279
Lib/test/test_configparser.py @jaraco
280+
281+
# Doc sections
282+
Doc/reference/ @willingc
283+
284+
**/*weakref* @kumaraditya303

.github/ISSUE_TEMPLATE/crash.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ body:
3232
- "3.10"
3333
- "3.11"
3434
- "3.12"
35+
- "3.13"
3536
- "CPython main branch"
3637
validations:
3738
required: true

.github/workflows/build.yml

Lines changed: 20 additions & 124 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,5 @@
11
name: Tests
22

3-
# gh-84728: "paths-ignore" is not used to skip documentation-only PRs, because
4-
# it prevents to mark a job as mandatory. A PR cannot be merged if a job is
5-
# mandatory but not scheduled because of "paths-ignore".
63
on:
74
workflow_dispatch:
85
push:
@@ -23,121 +20,19 @@ concurrency:
2320

2421
jobs:
2522
check_source:
26-
name: 'Check for source changes'
27-
runs-on: ubuntu-latest
28-
timeout-minutes: 10
29-
outputs:
30-
# Some of the referenced steps set outputs conditionally and there may be
31-
# cases when referencing them evaluates to empty strings. It is nice to
32-
# work with proper booleans so they have to be evaluated through JSON
33-
# conversion in the expressions. However, empty strings used like that
34-
# may trigger all sorts of undefined and hard-to-debug behaviors in
35-
# GitHub Actions CI/CD. To help with this, all of the outputs set here
36-
# that are meant to be used as boolean flags (and not arbitrary strings),
37-
# MUST have fallbacks with default values set. A common pattern would be
38-
# to add ` || false` to all such expressions here, in the output
39-
# definitions. They can then later be safely used through the following
40-
# idiom in job conditionals and other expressions. Here's some examples:
41-
#
42-
# if: fromJSON(needs.check_source.outputs.run-docs)
43-
#
44-
# ${{
45-
# fromJSON(needs.check_source.outputs.run_tests)
46-
# && 'truthy-branch'
47-
# || 'falsy-branch'
48-
# }}
49-
#
50-
run-docs: ${{ steps.docs-changes.outputs.run-docs || false }}
51-
run-win-msi: ${{ steps.win-msi-changes.outputs.run-win-msi || false }}
52-
run_tests: ${{ steps.check.outputs.run_tests || false }}
53-
run_hypothesis: ${{ steps.check.outputs.run_hypothesis || false }}
54-
run_cifuzz: ${{ steps.check.outputs.run_cifuzz || false }}
55-
config_hash: ${{ steps.config_hash.outputs.hash }} # str
56-
steps:
57-
- uses: actions/checkout@v4
58-
- name: Check for source changes
59-
id: check
60-
run: |
61-
if [ -z "$GITHUB_BASE_REF" ]; then
62-
echo "run_tests=true" >> $GITHUB_OUTPUT
63-
else
64-
git fetch origin $GITHUB_BASE_REF --depth=1
65-
# git diff "origin/$GITHUB_BASE_REF..." (3 dots) may be more
66-
# reliable than git diff "origin/$GITHUB_BASE_REF.." (2 dots),
67-
# but it requires to download more commits (this job uses
68-
# "git fetch --depth=1").
69-
#
70-
# git diff "origin/$GITHUB_BASE_REF..." (3 dots) works with Git
71-
# 2.26, but Git 2.28 is stricter and fails with "no merge base".
72-
#
73-
# git diff "origin/$GITHUB_BASE_REF.." (2 dots) should be enough on
74-
# GitHub, since GitHub starts by merging origin/$GITHUB_BASE_REF
75-
# into the PR branch anyway.
76-
#
77-
# https://github.com/python/core-workflow/issues/373
78-
git diff --name-only origin/$GITHUB_BASE_REF.. | grep -qvE '(\.rst$|^Doc|^Misc|^\.pre-commit-config\.yaml$|\.ruff\.toml$|\.md$|mypy\.ini$)' && echo "run_tests=true" >> $GITHUB_OUTPUT || true
79-
fi
80-
81-
# Check if we should run hypothesis tests
82-
GIT_BRANCH=${GITHUB_BASE_REF:-${GITHUB_REF#refs/heads/}}
83-
echo $GIT_BRANCH
84-
if $(echo "$GIT_BRANCH" | grep -q -w '3\.\(8\|9\|10\|11\)'); then
85-
echo "Branch too old for hypothesis tests"
86-
echo "run_hypothesis=false" >> $GITHUB_OUTPUT
87-
else
88-
echo "Run hypothesis tests"
89-
echo "run_hypothesis=true" >> $GITHUB_OUTPUT
90-
fi
91-
92-
# oss-fuzz maintains a configuration for fuzzing the main branch of
93-
# CPython, so CIFuzz should be run only for code that is likely to be
94-
# merged into the main branch; compatibility with older branches may
95-
# be broken.
96-
FUZZ_RELEVANT_FILES='(\.c$|\.h$|\.cpp$|^configure$|^\.github/workflows/build\.yml$|^Modules/_xxtestfuzz)'
97-
if [ "$GITHUB_BASE_REF" = "main" ] && [ "$(git diff --name-only origin/$GITHUB_BASE_REF.. | grep -qE $FUZZ_RELEVANT_FILES; echo $?)" -eq 0 ]; then
98-
# The tests are pretty slow so they are executed only for PRs
99-
# changing relevant files.
100-
echo "Run CIFuzz tests"
101-
echo "run_cifuzz=true" >> $GITHUB_OUTPUT
102-
else
103-
echo "Branch too old for CIFuzz tests; or no C files were changed"
104-
echo "run_cifuzz=false" >> $GITHUB_OUTPUT
105-
fi
106-
- name: Compute hash for config cache key
107-
id: config_hash
108-
run: |
109-
echo "hash=${{ hashFiles('configure', 'configure.ac', '.github/workflows/build.yml') }}" >> $GITHUB_OUTPUT
110-
- name: Get a list of the changed documentation-related files
111-
if: github.event_name == 'pull_request'
112-
id: changed-docs-files
113-
uses: Ana06/get-changed-files@v2.3.0
114-
with:
115-
filter: |
116-
Doc/**
117-
Misc/**
118-
.github/workflows/reusable-docs.yml
119-
format: csv # works for paths with spaces
120-
- name: Check for docs changes
121-
if: >-
122-
github.event_name == 'pull_request'
123-
&& steps.changed-docs-files.outputs.added_modified_renamed != ''
124-
id: docs-changes
125-
run: |
126-
echo "run-docs=true" >> "${GITHUB_OUTPUT}"
127-
- name: Get a list of the MSI installer-related files
128-
id: changed-win-msi-files
129-
uses: Ana06/get-changed-files@v2.3.0
130-
with:
131-
filter: |
132-
Tools/msi/**
133-
.github/workflows/reusable-windows-msi.yml
134-
format: csv # works for paths with spaces
135-
- name: Check for changes in MSI installer-related files
136-
if: >-
137-
steps.changed-win-msi-files.outputs.added_modified_renamed != ''
138-
id: win-msi-changes
139-
run: |
140-
echo "run-win-msi=true" >> "${GITHUB_OUTPUT}"
23+
name: Change detection
24+
# To use boolean outputs from this job, parse them as JSON.
25+
# Here's some examples:
26+
#
27+
# if: fromJSON(needs.check_source.outputs.run-docs)
28+
#
29+
# ${{
30+
# fromJSON(needs.check_source.outputs.run_tests)
31+
# && 'truthy-branch'
32+
# || 'falsy-branch'
33+
# }}
34+
#
35+
uses: ./.github/workflows/reusable-change-detection.yml
14136

14237
check-docs:
14338
name: Docs
@@ -300,14 +195,15 @@ jobs:
300195

301196
build_ubuntu_ssltests:
302197
name: 'Ubuntu SSL tests with OpenSSL'
303-
runs-on: ubuntu-22.04
198+
runs-on: ${{ matrix.os }}
304199
timeout-minutes: 60
305200
needs: check_source
306201
if: needs.check_source.outputs.run_tests == 'true'
307202
strategy:
308203
fail-fast: false
309204
matrix:
310-
openssl_ver: [1.1.1w, 3.0.13, 3.1.5, 3.2.1]
205+
os: [ubuntu-22.04]
206+
openssl_ver: [3.0.15, 3.1.7, 3.2.3, 3.3.2]
311207
env:
312208
OPENSSL_VER: ${{ matrix.openssl_ver }}
313209
MULTISSL_DIR: ${{ github.workspace }}/multissl
@@ -336,7 +232,7 @@ jobs:
336232
uses: actions/cache@v4
337233
with:
338234
path: ./multissl/openssl/${{ env.OPENSSL_VER }}
339-
key: ${{ runner.os }}-multissl-openssl-${{ env.OPENSSL_VER }}
235+
key: ${{ matrix.os }}-multissl-openssl-${{ env.OPENSSL_VER }}
340236
- name: Install OpenSSL
341237
if: steps.cache-openssl.outputs.cache-hit != 'true'
342238
run: python3 Tools/ssl/multissltests.py --steps=library --base-directory $MULTISSL_DIR --openssl $OPENSSL_VER --system Linux
@@ -371,7 +267,7 @@ jobs:
371267
needs: check_source
372268
if: needs.check_source.outputs.run_tests == 'true' && needs.check_source.outputs.run_hypothesis == 'true'
373269
env:
374-
OPENSSL_VER: 3.0.13
270+
OPENSSL_VER: 3.0.15
375271
PYTHONSTRICTEXTENSIONBUILD: 1
376272
steps:
377273
- uses: actions/checkout@v4
@@ -485,7 +381,7 @@ jobs:
485381
needs: check_source
486382
if: needs.check_source.outputs.run_tests == 'true'
487383
env:
488-
OPENSSL_VER: 3.0.13
384+
OPENSSL_VER: 3.0.15
489385
PYTHONSTRICTEXTENSIONBUILD: 1
490386
ASAN_OPTIONS: detect_leaks=0:allocator_may_return_null=1:handle_segv=0
491387
steps:
@@ -515,7 +411,7 @@ jobs:
515411
uses: actions/cache@v4
516412
with:
517413
path: ./multissl/openssl/${{ env.OPENSSL_VER }}
518-
key: ${{ runner.os }}-multissl-openssl-${{ env.OPENSSL_VER }}
414+
key: ${{ matrix.os }}-multissl-openssl-${{ env.OPENSSL_VER }}
519415
- name: Install OpenSSL
520416
if: steps.cache-openssl.outputs.cache-hit != 'true'
521417
run: python3 Tools/ssl/multissltests.py --steps=library --base-directory $MULTISSL_DIR --openssl $OPENSSL_VER --system Linux

0 commit comments

Comments
 (0)