Skip to content

Commit 6498d29

Browse files
Merge branch 'main' into revert_new_stack_check_for_non_glibc-131338
2 parents 733a28b + 1e69cd1 commit 6498d29

File tree

1,360 files changed

+57342
-22417
lines changed

Some content is hidden

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

1,360 files changed

+57342
-22417
lines changed

.devcontainer/devcontainer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"image": "ghcr.io/python/devcontainer:2024.09.25.11038928730",
2+
"image": "ghcr.io/python/devcontainer:2025.05.29.15334414373",
33
"onCreateCommand": [
44
// Install common tooling.
55
"dnf",

.editorconfig

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
root = true
22

3-
[*.{py,c,cpp,h,js,rst,md,yml,yaml}]
3+
[*.{py,c,cpp,h,js,rst,md,yml,yaml,gram}]
44
trim_trailing_whitespace = true
55
insert_final_newline = true
66
indent_style = space
77

8-
[*.{py,c,cpp,h}]
8+
[*.{py,c,cpp,h,gram}]
99
indent_size = 4
1010

1111
[*.rst]

.gitattributes

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
*.ico binary
1111
*.jpg binary
1212
*.pck binary
13+
*.pdf binary
1314
*.png binary
1415
*.psd binary
1516
*.tar binary
@@ -67,6 +68,7 @@ PCbuild/readme.txt dos
6768
**/clinic/*.cpp.h generated
6869
**/clinic/*.h.h generated
6970
*_db.h generated
71+
Doc/c-api/lifecycle.dot.svg generated
7072
Doc/data/stable_abi.dat generated
7173
Doc/library/token-list.inc generated
7274
Include/internal/pycore_ast.h generated

.github/CODEOWNERS

Lines changed: 28 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@ Modules/Setup* @erlend-aasland
2626
**/*context* @1st1
2727
**/*genobject* @markshannon
2828
**/*hamt* @1st1
29-
**/*jit* @brandtbucher @savannahostrowski
29+
**/*jit* @brandtbucher @savannahostrowski @diegorusso
30+
Python/perf_jit_trampoline.c # Exclude the owners of "**/*jit*", above.
3031
Objects/set* @rhettinger
3132
Objects/dict* @methane @markshannon
3233
Objects/typevarobject.c @JelleZijlstra
@@ -35,6 +36,7 @@ Objects/type* @markshannon
3536
Objects/codeobject.c @markshannon
3637
Objects/frameobject.c @markshannon
3738
Objects/call.c @markshannon
39+
Objects/object.c @ZeroIntensity
3840
Python/ceval*.c @markshannon
3941
Python/ceval*.h @markshannon
4042
Python/codegen.c @markshannon @iritkatriel
@@ -44,8 +46,9 @@ Python/flowgraph.c @markshannon @iritkatriel
4446
Python/instruction_sequence.c @iritkatriel
4547
Python/bytecodes.c @markshannon
4648
Python/optimizer*.c @markshannon
47-
Python/optimizer_analysis.c @Fidget-Spinner
48-
Python/optimizer_bytecodes.c @Fidget-Spinner
49+
Python/optimizer_analysis.c @Fidget-Spinner @tomasr8
50+
Python/optimizer_bytecodes.c @Fidget-Spinner @tomasr8
51+
Python/optimizer_symbols.c @tomasr8
4952
Python/symtable.c @JelleZijlstra @carljm
5053
Lib/_pyrepl/* @pablogsal @lysnikolaou @ambv
5154
Lib/test/test_patma.py @brandtbucher
@@ -66,8 +69,8 @@ Doc/_static/** @AA-Turner @hugovk
6669
Doc/tools/** @AA-Turner @hugovk
6770

6871
# runtime state/lifecycle
69-
**/*pylifecycle* @ericsnowcurrently
70-
**/*pystate* @ericsnowcurrently
72+
**/*pylifecycle* @ericsnowcurrently @ZeroIntensity
73+
**/*pystate* @ericsnowcurrently @ZeroIntensity
7174
**/*preconfig* @ericsnowcurrently
7275
**/*initconfig* @ericsnowcurrently
7376
**/*pathconfig* @ericsnowcurrently
@@ -187,13 +190,13 @@ Include/internal/pycore_time.h @pganssle @abalkin
187190
/Tools/cases_generator/ @markshannon
188191

189192
# AST
190-
Python/ast.c @isidentical @JelleZijlstra @eclips4
191-
Python/ast_preprocess.c @isidentical @eclips4
192-
Parser/asdl.py @isidentical @JelleZijlstra @eclips4
193-
Parser/asdl_c.py @isidentical @JelleZijlstra @eclips4
194-
Lib/ast.py @isidentical @JelleZijlstra @eclips4
195-
Lib/_ast_unparse.py @isidentical @JelleZijlstra @eclips4
196-
Lib/test/test_ast/ @eclips4
193+
Python/ast.c @isidentical @JelleZijlstra @eclips4 @tomasr8
194+
Python/ast_preprocess.c @isidentical @eclips4 @tomasr8
195+
Parser/asdl.py @isidentical @JelleZijlstra @eclips4 @tomasr8
196+
Parser/asdl_c.py @isidentical @JelleZijlstra @eclips4 @tomasr8
197+
Lib/ast.py @isidentical @JelleZijlstra @eclips4 @tomasr8
198+
Lib/_ast_unparse.py @isidentical @JelleZijlstra @eclips4 @tomasr8
199+
Lib/test/test_ast/ @eclips4 @tomasr8
197200

198201
# Mock
199202
/Lib/unittest/mock.py @cjw296
@@ -281,9 +284,13 @@ Doc/howto/clinic.rst @erlend-aasland
281284
# Subinterpreters
282285
**/*interpreteridobject.* @ericsnowcurrently
283286
**/*crossinterp* @ericsnowcurrently
284-
Lib/test/support/interpreters/ @ericsnowcurrently
285287
Modules/_interp*module.c @ericsnowcurrently
288+
Lib/test/test__interp*.py @ericsnowcurrently
289+
Lib/concurrent/interpreters/ @ericsnowcurrently
290+
Lib/test/support/channels.py @ericsnowcurrently
291+
Doc/library/concurrent.interpreters.rst @ericsnowcurrently
286292
Lib/test/test_interpreters/ @ericsnowcurrently
293+
Lib/concurrent/futures/interpreter.py @ericsnowcurrently
287294

288295
# Android
289296
**/*Android* @mhsmith @freakboy3742
@@ -331,3 +338,11 @@ Modules/_xxtestfuzz/ @ammaraskar
331338
**/*templateobject* @lysnikolaou
332339
**/*templatelib* @lysnikolaou
333340
**/*tstring* @lysnikolaou
341+
342+
# Remote debugging
343+
Python/remote_debug.h @pablogsal
344+
Python/remote_debugging.c @pablogsal
345+
Modules/_remote_debugging_module.c @pablogsal @ambv @1st1
346+
347+
# gettext
348+
**/*gettext* @tomasr8

.github/workflows/build.yml

Lines changed: 104 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,13 @@ permissions:
1515
contents: read
1616

1717
concurrency:
18-
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}-reusable
18+
# https://docs.github.com/en/actions/writing-workflows/workflow-syntax-for-github-actions#concurrency
19+
# 'group' must be a key uniquely representing a PR or push event.
20+
# github.workflow is the workflow name
21+
# github.actor is the user invoking the workflow
22+
# github.head_ref is the source branch of the PR or otherwise blank
23+
# github.run_id is a unique number for the current run
24+
group: ${{ github.workflow }}-${{ github.actor }}-${{ github.head_ref || github.run_id }}
1925
cancel-in-progress: true
2026

2127
env:
@@ -254,7 +260,7 @@ jobs:
254260
free-threading: ${{ matrix.free-threading }}
255261
os: ${{ matrix.os }}
256262

257-
build-ubuntu-ssltests:
263+
build-ubuntu-ssltests-openssl:
258264
name: 'Ubuntu SSL tests with OpenSSL'
259265
runs-on: ${{ matrix.os }}
260266
timeout-minutes: 60
@@ -316,6 +322,81 @@ jobs:
316322
- name: SSL tests
317323
run: ./python Lib/test/ssltests.py
318324

325+
build-ubuntu-ssltests-awslc:
326+
name: 'Ubuntu SSL tests with AWS-LC'
327+
runs-on: ${{ matrix.os }}
328+
timeout-minutes: 60
329+
needs: build-context
330+
if: needs.build-context.outputs.run-tests == 'true'
331+
strategy:
332+
fail-fast: false
333+
matrix:
334+
os: [ubuntu-24.04]
335+
awslc_ver: [1.55.0]
336+
env:
337+
AWSLC_VER: ${{ matrix.awslc_ver}}
338+
MULTISSL_DIR: ${{ github.workspace }}/multissl
339+
OPENSSL_DIR: ${{ github.workspace }}/multissl/aws-lc/${{ matrix.awslc_ver }}
340+
LD_LIBRARY_PATH: ${{ github.workspace }}/multissl/aws-lc/${{ matrix.awslc_ver }}/lib
341+
steps:
342+
- uses: actions/checkout@v4
343+
with:
344+
persist-credentials: false
345+
- name: Runner image version
346+
run: echo "IMAGE_OS_VERSION=${ImageOS}-${ImageVersion}" >> "$GITHUB_ENV"
347+
- name: Restore config.cache
348+
uses: actions/cache@v4
349+
with:
350+
path: config.cache
351+
key: ${{ github.job }}-${{ env.IMAGE_OS_VERSION }}-${{ needs.build-context.outputs.config-hash }}
352+
- name: Register gcc problem matcher
353+
run: echo "::add-matcher::.github/problem-matchers/gcc.json"
354+
- name: Install dependencies
355+
run: sudo ./.github/workflows/posix-deps-apt.sh
356+
- name: Configure SSL lib env vars
357+
run: |
358+
echo "MULTISSL_DIR=${GITHUB_WORKSPACE}/multissl" >> "$GITHUB_ENV"
359+
echo "OPENSSL_DIR=${GITHUB_WORKSPACE}/multissl/aws-lc/${AWSLC_VER}" >> "$GITHUB_ENV"
360+
echo "LD_LIBRARY_PATH=${GITHUB_WORKSPACE}/multissl/aws-lc/${AWSLC_VER}/lib" >> "$GITHUB_ENV"
361+
- name: 'Restore AWS-LC build'
362+
id: cache-aws-lc
363+
uses: actions/cache@v4
364+
with:
365+
path: ./multissl/aws-lc/${{ matrix.awslc_ver }}
366+
key: ${{ matrix.os }}-multissl-aws-lc-${{ matrix.awslc_ver }}
367+
- name: Install AWS-LC
368+
if: steps.cache-aws-lc.outputs.cache-hit != 'true'
369+
run: |
370+
python3 Tools/ssl/multissltests.py \
371+
--steps=library \
372+
--base-directory "$MULTISSL_DIR" \
373+
--awslc ${{ matrix.awslc_ver }} \
374+
--system Linux
375+
- name: Add ccache to PATH
376+
run: |
377+
echo "PATH=/usr/lib/ccache:$PATH" >> "$GITHUB_ENV"
378+
- name: Configure ccache action
379+
uses: hendrikmuhs/ccache-action@v1.2
380+
with:
381+
save: false
382+
- name: Configure CPython
383+
run: |
384+
./configure CFLAGS="-fdiagnostics-format=json" \
385+
--config-cache \
386+
--enable-slower-safety \
387+
--with-pydebug \
388+
--with-openssl="$OPENSSL_DIR" \
389+
--with-builtin-hashlib-hashes=blake2 \
390+
--with-ssl-default-suites=openssl
391+
- name: Build CPython
392+
run: make -j
393+
- name: Display build info
394+
run: make pythoninfo
395+
- name: Verify python is linked to AWS-LC
396+
run: ./python -c 'import ssl; print(ssl.OPENSSL_VERSION)' | grep AWS-LC
397+
- name: SSL tests
398+
run: ./python Lib/test/ssltests.py
399+
319400
build-wasi:
320401
name: 'WASI'
321402
needs: build-context
@@ -504,20 +585,28 @@ jobs:
504585
- name: Tests
505586
run: xvfb-run make ci
506587

507-
build-tsan:
508-
name: >-
509-
Thread sanitizer
510-
${{ fromJSON(matrix.free-threading) && '(free-threading)' || '' }}
588+
build-san:
589+
name: >- # ${{ '' } is a hack to nest jobs under the same sidebar category
590+
Sanitizers${{ '' }}
511591
needs: build-context
512592
if: needs.build-context.outputs.run-tests == 'true'
513593
strategy:
514594
fail-fast: false
515595
matrix:
596+
check-name:
597+
- Thread
516598
free-threading:
517599
- false
518600
- true
519-
uses: ./.github/workflows/reusable-tsan.yml
601+
sanitizer:
602+
- TSan
603+
include:
604+
- check-name: Undefined behavior
605+
sanitizer: UBSan
606+
free-threading: false
607+
uses: ./.github/workflows/reusable-san.yml
520608
with:
609+
sanitizer: ${{ matrix.sanitizer }}
521610
config_hash: ${{ needs.build-context.outputs.config-hash }}
522611
free-threading: ${{ matrix.free-threading }}
523612

@@ -614,11 +703,12 @@ jobs:
614703
- build-windows-msi
615704
- build-macos
616705
- build-ubuntu
617-
- build-ubuntu-ssltests
706+
- build-ubuntu-ssltests-awslc
707+
- build-ubuntu-ssltests-openssl
618708
- build-wasi
619709
- test-hypothesis
620710
- build-asan
621-
- build-tsan
711+
- build-san
622712
- cross-build-linux
623713
- cifuzz
624714
if: always()
@@ -629,7 +719,8 @@ jobs:
629719
with:
630720
allowed-failures: >-
631721
build-windows-msi,
632-
build-ubuntu-ssltests,
722+
build-ubuntu-ssltests-awslc,
723+
build-ubuntu-ssltests-openssl,
633724
test-hypothesis,
634725
cifuzz,
635726
allowed-skips: >-
@@ -647,11 +738,12 @@ jobs:
647738
check-generated-files,
648739
build-macos,
649740
build-ubuntu,
650-
build-ubuntu-ssltests,
741+
build-ubuntu-ssltests-awslc,
742+
build-ubuntu-ssltests-openssl,
651743
build-wasi,
652744
test-hypothesis,
653745
build-asan,
654-
build-tsan,
746+
build-san,
655747
cross-build-linux,
656748
'
657749
|| ''

.github/workflows/jit.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ on:
55
- '**jit**'
66
- 'Python/bytecodes.c'
77
- 'Python/optimizer*.c'
8+
- 'Python/executor_cases.c.h'
9+
- 'Python/optimizer_cases.c.h'
810
- '!Python/perf_jit_trampoline.c'
911
- '!**/*.md'
1012
- '!**/*.ini'
@@ -13,6 +15,8 @@ on:
1315
- '**jit**'
1416
- 'Python/bytecodes.c'
1517
- 'Python/optimizer*.c'
18+
- 'Python/executor_cases.c.h'
19+
- 'Python/optimizer_cases.c.h'
1620
- '!Python/perf_jit_trampoline.c'
1721
- '!**/*.md'
1822
- '!**/*.ini'

.github/workflows/posix-deps-apt.sh

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ apt-get -yq install \
55
build-essential \
66
pkg-config \
77
ccache \
8+
cmake \
89
gdb \
910
lcov \
1011
libb2-dev \
@@ -17,10 +18,18 @@ apt-get -yq install \
1718
libreadline6-dev \
1819
libsqlite3-dev \
1920
libssl-dev \
21+
libzstd-dev \
2022
lzma \
2123
lzma-dev \
2224
strace \
2325
tk-dev \
2426
uuid-dev \
2527
xvfb \
2628
zlib1g-dev
29+
30+
# Workaround missing libmpdec-dev on ubuntu 24.04:
31+
# https://launchpad.net/~ondrej/+archive/ubuntu/php
32+
# https://deb.sury.org/
33+
sudo add-apt-repository ppa:ondrej/php
34+
apt-get update
35+
apt-get -yq install libmpdec-dev

.github/workflows/reusable-docs.yml

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ jobs:
6666
run: |
6767
set -Eeuo pipefail
6868
# Build docs with the nit-picky option; write warnings to file
69-
make -C Doc/ PYTHON=../python SPHINXOPTS="--quiet --nitpicky --fail-on-warning --warning-file sphinx-warnings.txt" html
69+
make -C Doc/ PYTHON=../python SPHINXOPTS="--quiet --nitpicky --warning-file sphinx-warnings.txt" html
7070
- name: 'Check warnings'
7171
if: github.event_name == 'pull_request'
7272
run: |
@@ -75,6 +75,18 @@ jobs:
7575
--fail-if-regression \
7676
--fail-if-improved \
7777
--fail-if-new-news-nit
78+
- name: 'Build EPUB documentation'
79+
continue-on-error: true
80+
run: |
81+
set -Eeuo pipefail
82+
make -C Doc/ PYTHON=../python SPHINXOPTS="--quiet" epub
83+
pip install epubcheck
84+
epubcheck Doc/build/epub/Python.epub &> Doc/epubcheck.txt
85+
- name: 'Check for fatal errors in EPUB'
86+
if: github.event_name == 'pull_request'
87+
continue-on-error: true # until gh-136155 is fixed
88+
run: |
89+
python Doc/tools/check-epub.py
7890
7991
# Run "doctest" on HEAD as new syntax doesn't exist in the latest stable release
8092
doctest:

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy