Pablo Galindo Salgado
aafbdb5df5
gh-133742: Fix test_sysconfig and test_build_details for relocated directories ( #136987 )
2025-07-22 11:53:05 +00:00
Timon Viola
4d02f31cdd
gh-118350: Fix support of elements "textarea" and "title" in HTMLParser ( #135310 )
...
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
2025-07-22 13:27:13 +02:00
Hood Chatham
c933a6bb32
gh-124621: Emscripten: Support pyrepl in browser (GH-136931)
...
Tests / (push) Blocked by required conditions
Tests / Cross build Linux (push) Blocked by required conditions
Tests / Change detection (push) Waiting to run
Tests / Docs (push) Blocked by required conditions
Tests / Windows MSI (push) Blocked by required conditions
Tests / Check if Autoconf files are up to date (push) Blocked by required conditions
Tests / Check if generated files are up to date (push) Blocked by required conditions
Tests / Ubuntu SSL tests with OpenSSL (push) Blocked by required conditions
Tests / Ubuntu SSL tests with AWS-LC (push) Blocked by required conditions
Tests / WASI (push) Blocked by required conditions
Tests / Hypothesis tests on Ubuntu (push) Blocked by required conditions
Tests / Address sanitizer (push) Blocked by required conditions
Tests / Sanitizers (push) Blocked by required conditions
Tests / CIFuzz (push) Blocked by required conditions
Tests / All required checks pass (push) Blocked by required conditions
Lint / lint (push) Waiting to run
mypy / Run mypy on Lib/_pyrepl (push) Waiting to run
mypy / Run mypy on Lib/test/libregrtest (push) Waiting to run
mypy / Run mypy on Lib/tomllib (push) Waiting to run
mypy / Run mypy on Tools/build (push) Waiting to run
mypy / Run mypy on Tools/cases_generator (push) Waiting to run
mypy / Run mypy on Tools/clinic (push) Waiting to run
mypy / Run mypy on Tools/jit (push) Waiting to run
mypy / Run mypy on Tools/peg_generator (push) Waiting to run
Basic support for pyrepl in Emscripten. Limitations:
* requires JSPI
* no signal handling implemented
As followup work, it would be nice to implement a webworker variant
for when JSPI is not available and proper signal handling.
Because it requires JSPI, it doesn't work in Safari. Firefox requires
setting an experimental flag. All the Chromiums have full support since
May. Until we make it work without JSPI, let's keep the original web_example
around.
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
Co-authored-by: Éric <merwok@netwok.org>
2025-07-22 12:13:38 +02:00
Dave Peck
22c8658906
gh-132661: Document t-strings and templatelib
( #135229 )
...
Co-authored-by: Petr Viktorin <encukou@gmail.com>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
Co-authored-by: Loïc Simon <loic.pano@gmail.com>
Co-authored-by: pauleveritt <pauleveritt@me.com>
2025-07-22 12:44:13 +03:00
Cornelius Roemer
9a21df7c0a
Fix 3 typos in "Next" News items ( #136892 )
2025-07-22 11:22:08 +03:00
Malcolm Smith
149bddcc21
gh-131531: Android test fixes ( #136845 )
...
Modifies the test runner script to no longer export the the HOST environment
variable, and to allow for tests that produce no Python output (output from the
Android console is still expected and required). These changes stem from
knowledge gained during developing a PR for Android support in cibuildwheel.
2025-07-22 14:51:16 +08:00
Jelle Zijlstra
46cbdf967a
gh-135228: When @dataclass(slots=True) replaces a dataclass, make the original class collectible ( #136893 )
...
An interesting hack, but more localized in scope than #135230 .
This may be a breaking change if people intentionally keep the original class around
when using `@dataclass(slots=True)`, and then use `__dict__` or `__weakref__` on the
original class.
Co-authored-by: Alyssa Coghlan <ncoghlan@gmail.com>
2025-07-21 21:43:34 -07:00
Hood Chatham
bbe589f93c
gh-133600: Move config.site-wasm32-emscripten into the emscripten folder ( #136934 )
...
Tests / (push) Blocked by required conditions
Tests / Cross build Linux (push) Blocked by required conditions
Tests / Windows MSI (push) Blocked by required conditions
Tests / Change detection (push) Waiting to run
Tests / Docs (push) Blocked by required conditions
Tests / Check if Autoconf files are up to date (push) Blocked by required conditions
Tests / Check if generated files are up to date (push) Blocked by required conditions
Tests / Ubuntu SSL tests with OpenSSL (push) Blocked by required conditions
Tests / Ubuntu SSL tests with AWS-LC (push) Blocked by required conditions
Tests / WASI (push) Blocked by required conditions
Tests / Hypothesis tests on Ubuntu (push) Blocked by required conditions
Tests / Address sanitizer (push) Blocked by required conditions
Tests / Sanitizers (push) Blocked by required conditions
Tests / CIFuzz (push) Blocked by required conditions
Tests / All required checks pass (push) Blocked by required conditions
Lint / lint (push) Waiting to run
mypy / Run mypy on Lib/_pyrepl (push) Waiting to run
mypy / Run mypy on Lib/test/libregrtest (push) Waiting to run
mypy / Run mypy on Lib/tomllib (push) Waiting to run
mypy / Run mypy on Tools/build (push) Waiting to run
mypy / Run mypy on Tools/cases_generator (push) Waiting to run
mypy / Run mypy on Tools/clinic (push) Waiting to run
mypy / Run mypy on Tools/jit (push) Waiting to run
mypy / Run mypy on Tools/peg_generator (push) Waiting to run
Reorganises the large Emscripten-specific file into the Emscripten folder.
2025-07-22 07:58:31 +08:00
Emma Smith
6bf1c0ab34
gh-136170: Revert adding ZipFile.data_offset
(GH-136950)
...
* Revert "gh-84481: Make ZipFile.data_offset more robust (#132178 )"
This reverts commit 6cd1d6c6b1
.
* Revert "gh-84481: Add ZipFile.data_offset attribute (#132165 )"
This reverts commit 0788948dcb
.
---------
Co-authored-by: Gregory P. Smith <greg@krypto.org>
2025-07-21 23:16:30 +00:00
Nathan Goldbaum
89c220b93c
gh-133296: Publicly expose critical section API that accepts PyMutex (gh-135899)
...
This makes the following APIs public:
* `Py_BEGIN_CRITICAL_SECTION_MUTEX(mutex),`
* `Py_BEGIN_CRITICAL_SECTION2_MUTEX(mutex1, mutex2)`
* `void PyCriticalSection_BeginMutex(PyCriticalSection *c, PyMutex *mutex)`
* `void PyCriticalSection2_BeginMutex(PyCriticalSection2 *c, PyMutex *mutex1, PyMutex *mutex2)`
The macros are identical to the corresponding `Py_BEGIN_CRITICAL_SECTION` and
`Py_BEGIN_CRITICAL_SECTION2` macros (e.g., they include braces), but they
accept a `PyMutex` instead of an object.
The new macros are still paired with the existing END macros
(`Py_END_CRITICAL_SECTION`, `Py_END_CRITICAL_SECTION2`).
2025-07-21 17:25:43 -04:00
Kumar Aditya
f183996eb7
gh-136870: fix data race in PyThreadState_Clear
on sys_tracing_threads
( #136951 )
...
In free-threading, multiple threads can be cleared concurrently as such the modifications on `sys_tracing_threads` should be done while holding the profile lock, otherwise it can race with other threads setting up profiling.
2025-07-21 20:35:25 +00:00
sobolevn
3224429450
gh-136437: Document os.path.dirname
as accepting only pos-only ( #136946 )
Tests / Cross build Linux (push) Blocked by required conditions
Tests / (push) Blocked by required conditions
Tests / Windows MSI (push) Blocked by required conditions
Tests / Change detection (push) Waiting to run
Tests / Docs (push) Blocked by required conditions
Tests / Check if Autoconf files are up to date (push) Blocked by required conditions
Tests / Check if generated files are up to date (push) Blocked by required conditions
Tests / Ubuntu SSL tests with OpenSSL (push) Blocked by required conditions
Tests / Ubuntu SSL tests with AWS-LC (push) Blocked by required conditions
Tests / WASI (push) Blocked by required conditions
Tests / Hypothesis tests on Ubuntu (push) Blocked by required conditions
Tests / Address sanitizer (push) Blocked by required conditions
Tests / Sanitizers (push) Blocked by required conditions
Tests / CIFuzz (push) Blocked by required conditions
Tests / All required checks pass (push) Blocked by required conditions
Lint / lint (push) Waiting to run
mypy / Run mypy on Lib/_pyrepl (push) Waiting to run
mypy / Run mypy on Lib/test/libregrtest (push) Waiting to run
mypy / Run mypy on Lib/tomllib (push) Waiting to run
mypy / Run mypy on Tools/build (push) Waiting to run
mypy / Run mypy on Tools/cases_generator (push) Waiting to run
mypy / Run mypy on Tools/clinic (push) Waiting to run
mypy / Run mypy on Tools/jit (push) Waiting to run
mypy / Run mypy on Tools/peg_generator (push) Waiting to run
2025-07-21 18:22:58 +00:00
sobolevn
b5428bb0e7
gh-136437: Document some os.path
functions as requiring pos-only ( #136812 )
2025-07-21 21:01:43 +03:00
Peter Bierma
a10960699a
gh-136421: Load _datetime
static types during interpreter initialization (GH-136583)
...
`_datetime` is a special module, because it's the only non-builtin C extension that contains static types. As such, it would initialize static types in the module's execution function, which can run concurrently. Since static type initialization is not thread-safe, this caused crashes. This fixes it by moving the initialization of `_datetime`'s static types to interpreter startup (where all other static types are initialized), which is already properly protected through other locks.
2025-07-21 13:47:26 -04:00
Barney Gale
80b2d60a51
GH-136874: url2pathname()
: discard query and fragment components ( #136875 )
...
In `urllib.request.url2pathname()`, ignore any query or fragment components
in the given URL.
2025-07-21 17:33:20 +00:00
Josh Cannon
4b68289ca6
Pedantic rewording of why relative importing doesn't work in main modules (GH-136846)
...
Pedantically reword the section about relative imports and main modules.
2025-07-21 09:30:17 -07:00
Alper
65893c6f9c
gh-116738: Make syslog module thread-safe ( #136760 )
...
Make the setlogmask() function in the syslog module thread-safe. These changes are relevant for scenarios where the GIL is disabled or when using subinterpreters.
2025-07-21 09:24:42 -07:00
Nacho Caballero
5f9e38f9b9
gh-136859: Improve StrEnum
docs (GH-136864)
...
Co-authored-by: Nacho Caballero <nacho.caballero@astrazeneca.com>
Co-authored-by: Antonio Spadaro <ilovelinux@users.noreply.github.com>
2025-07-21 08:18:40 -07:00
Mikhail Efimov
58d305cf38
gh-136438: Make sure test_generated_cases
pass with all optimization levels ( #136594 )
...
Fix the `test_generated_cases` to work with `-O` or `-OO` flags.
Previously, `test_generated_cases` was catching an `AssertionError` while `Tools/cases_generator/optimizer_generator.py` used an `assert` statement. This approach semantically incorrect, no one should trying to catch an `AssertionError`!
Now the `assert` statement has been replaced with an explicit `raise ValueError(...)` and the corresponding `self.assertRaisesRegex(AssertionError, ...)` has been updated to catch a `ValueError` instead.
2025-07-21 15:25:25 +03:00
Petr Viktorin
658599c15d
gh-121028: Soft-deprecate sys.api_version (GH-136463)
2025-07-21 14:22:48 +02:00
Petr Viktorin
28153fec58
gh-135621: Simplify TermInfo (GH-136916)
2025-07-21 13:06:42 +02:00
Serhiy Storchaka
dee6501894
gh-135661: Fix parsing attributes with whitespaces around the "=" separator in HTMLParser (GH-136908)
...
Tests / Check if Autoconf files are up to date (push) Blocked by required conditions
Tests / (push) Blocked by required conditions
Tests / Cross build Linux (push) Blocked by required conditions
Tests / Windows MSI (push) Blocked by required conditions
Tests / Change detection (push) Waiting to run
Tests / Docs (push) Blocked by required conditions
Tests / Check if generated files are up to date (push) Blocked by required conditions
Tests / Ubuntu SSL tests with OpenSSL (push) Blocked by required conditions
Tests / Ubuntu SSL tests with AWS-LC (push) Blocked by required conditions
Tests / WASI (push) Blocked by required conditions
Tests / Hypothesis tests on Ubuntu (push) Blocked by required conditions
Tests / Address sanitizer (push) Blocked by required conditions
Tests / Sanitizers (push) Blocked by required conditions
Tests / CIFuzz (push) Blocked by required conditions
Tests / All required checks pass (push) Blocked by required conditions
Lint / lint (push) Waiting to run
mypy / Run mypy on Lib/_pyrepl (push) Waiting to run
mypy / Run mypy on Lib/test/libregrtest (push) Waiting to run
mypy / Run mypy on Lib/tomllib (push) Waiting to run
mypy / Run mypy on Tools/build (push) Waiting to run
mypy / Run mypy on Tools/cases_generator (push) Waiting to run
mypy / Run mypy on Tools/clinic (push) Waiting to run
mypy / Run mypy on Tools/jit (push) Waiting to run
mypy / Run mypy on Tools/peg_generator (push) Waiting to run
This fixes a regression introduced in GH-135930.
2025-07-21 12:07:15 +02:00
Łukasz Langa
09dfb50f1b
gh-135621: Remove dependency on curses from PyREPL (GH-136758)
2025-07-21 11:57:34 +02:00
adam j hartz
d1d526afe7
gh-136251: Improvements to WASM demo REPL (GH-136252)
...
Co-authored-by: Hood Chatham <roberthoodchatham@gmail.com>
2025-07-21 11:56:45 +02:00
Hood Chatham
9c7b2af73d
gh-136852: Emscripten: Fix bug in #136853 ( #136909 )
...
We need to get rid of some whitespace to make this work.
2025-07-21 11:17:36 +02:00
Sergey Muraviov
cf19b6435d
gh-134411: assert PyLong_FromLong(x) != NULL
when x
is known to be small ( #134415 )
...
Since `PyLong_From Long(PY_MONITORING_DEBUGGER_ID)` falls to `small_int` case and can't return `NULL`. Added `assert`s for extra confidence.
https://github.com/python/cpython/issues/134411#issuecomment-2897653868
2025-07-21 11:59:06 +03:00
Vinay Sajip
1e672935b4
gh-136882: Update stale link in the basic logging tutorial. ( #136885 )
...
Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
2025-07-21 10:29:12 +02:00
Bénédikt Tran
5798348a07
gh-136428: amend UUIDv8 performance improvements ( #136903 )
...
UUIDv8 has been added in Python 3.14.0a2 and its construction time
has been improved in Python 3.14.0a4, but since those changes will
not be visible when comparing the latest Python 3.13 and 3.14 together,
we do not document them on the What's New page to avoid confusion.
2025-07-21 08:23:16 +00:00
Dave Peck
c5e77af131
gh-132661: Disallow Template
/str
concatenation after PEP 750 spec update ( #135996 )
...
Co-authored-by: sobolevn <mail@sobolevn.me>
Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
2025-07-21 08:44:26 +02:00
AN Long
246be21de1
gh-136470: Correct InterpreterPoolExecutor's default thread name (GH-136472)
...
Tests / (push) Blocked by required conditions
Tests / Cross build Linux (push) Blocked by required conditions
Tests / Windows MSI (push) Blocked by required conditions
Tests / Change detection (push) Waiting to run
Tests / Docs (push) Blocked by required conditions
Tests / Check if Autoconf files are up to date (push) Blocked by required conditions
Tests / Check if generated files are up to date (push) Blocked by required conditions
Tests / Ubuntu SSL tests with OpenSSL (push) Blocked by required conditions
Tests / Ubuntu SSL tests with AWS-LC (push) Blocked by required conditions
Tests / WASI (push) Blocked by required conditions
Tests / Hypothesis tests on Ubuntu (push) Blocked by required conditions
Tests / Address sanitizer (push) Blocked by required conditions
Tests / Sanitizers (push) Blocked by required conditions
Tests / CIFuzz (push) Blocked by required conditions
Tests / All required checks pass (push) Blocked by required conditions
Lint / lint (push) Waiting to run
mypy / Run mypy on Lib/_pyrepl (push) Waiting to run
mypy / Run mypy on Lib/test/libregrtest (push) Waiting to run
mypy / Run mypy on Lib/tomllib (push) Waiting to run
mypy / Run mypy on Tools/build (push) Waiting to run
mypy / Run mypy on Tools/cases_generator (push) Waiting to run
mypy / Run mypy on Tools/clinic (push) Waiting to run
mypy / Run mypy on Tools/jit (push) Waiting to run
mypy / Run mypy on Tools/peg_generator (push) Waiting to run
The OS thread name is now correctly prefixed with `InterpreterPoolExecutor` instead of `ThreadPoolExecutor`.
2025-07-20 23:34:32 +00:00
Hood Chatham
aec7f5f8b2
gh-136852: Emscripten: Add PYTHON_NODE_VERSION environment variable ( #136853 )
...
To choose the node version we use. Together with:
https://github.com/python/buildmaster-config/pull/614
closes #136852 .
2025-07-21 00:30:35 +02:00
Pablo Galindo Salgado
acbe896cb1
GH-130645: Default to color help in argparse ( #136809 )
...
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
Co-authored-by: Adam Turner <9087854+aa-turner@users.noreply.github.com>
2025-07-20 14:55:44 -07:00
🇺🇦 Sviatoslav Sydorenko (Святослав Сидоренко)
65d2c51c10
GH-111758: Merge TSan and UBSan reusable GHA workflows ( #136820 )
...
Co-authored-by: Sviatoslav Sydorenko <webknjaz@redhat.com>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2025-07-20 23:03:46 +03:00
Peter Bierma
8f59fbb082
gh-136492: Add FrameLocalsProxyType
to types
(GH-136546)
...
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2025-07-20 20:49:00 +02:00
morotti
e24c66d55a
gh-91349: Adjust default compression level to 6 (down from 9) in gzip and tarfile (GH-131470)
...
Tests / (push) Blocked by required conditions
Tests / Windows MSI (push) Blocked by required conditions
Tests / Change detection (push) Waiting to run
Tests / Docs (push) Blocked by required conditions
Tests / Check if Autoconf files are up to date (push) Blocked by required conditions
Tests / Check if generated files are up to date (push) Blocked by required conditions
Tests / Ubuntu SSL tests with OpenSSL (push) Blocked by required conditions
Tests / Ubuntu SSL tests with AWS-LC (push) Blocked by required conditions
Tests / WASI (push) Blocked by required conditions
Tests / Hypothesis tests on Ubuntu (push) Blocked by required conditions
Tests / Address sanitizer (push) Blocked by required conditions
Tests / Undefined behavior sanitizer (push) Blocked by required conditions
Tests / Cross build Linux (push) Blocked by required conditions
Tests / CIFuzz (push) Blocked by required conditions
Tests / All required checks pass (push) Blocked by required conditions
Lint / lint (push) Waiting to run
mypy / Run mypy on Lib/_pyrepl (push) Waiting to run
mypy / Run mypy on Lib/test/libregrtest (push) Waiting to run
mypy / Run mypy on Lib/tomllib (push) Waiting to run
mypy / Run mypy on Tools/build (push) Waiting to run
mypy / Run mypy on Tools/cases_generator (push) Waiting to run
mypy / Run mypy on Tools/clinic (push) Waiting to run
mypy / Run mypy on Tools/jit (push) Waiting to run
mypy / Run mypy on Tools/peg_generator (push) Waiting to run
gh-91349: Adjust default compression level to 6 (down from 9) in gzip and tarfile
It is the default level used by most compression tools and a
better tradeoff between speed and performance.
Co-authored-by: rmorotti <romain.morotti@man.com>
Co-authored-by: Pieter Eendebak <pieter.eendebak@gmail.com>
2025-07-20 09:43:40 -07:00
Alexander Urieles
958657bbc3
gh-131724: Add a new max_response_headers param to HTTP/HTTPSConnection (GH-136814)
...
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
Co-authored-by: Petr Viktorin <encukou@gmail.com>
2025-07-20 13:53:54 +00:00
MonadChains
18a7f5dad8
gh-127598: Improve ModuleNotFoundError when -S is passed (GH-136821)
2025-07-20 15:33:58 +02:00
Bénédikt Tran
4a151cae33
gh-134531: prefer using _hashlib
module state instead of module object ( #136865 )
...
Some internal helper functions taking the module object to retrieve its state
under some conditions now directly take the module's state instead as those
conditions hold most of the time.
2025-07-20 13:10:36 +00:00
Bénédikt Tran
c504f62fe2
gh-136547: fix hashlib_helper
for blocking and requesting digests ( #136762 )
...
- Fix `hashlib_helper.block_algorithm` where the dummy functions were incorrectly defined.
- Rename `hashlib_helper.HashAPI` to `hashlib_helper.HashInfo` and add more helper methods.
- Simplify `hashlib_helper.requires_*()` functions.
- Rewrite some private helpers in `hashlib_helper`.
- Remove `find_{builtin,openssl}_hashdigest_constructor()` as they are no more needed and were
not meant to be public in the first place.
- Fix some tests in `test_hashlib` when FIPS mode is on.
2025-07-20 14:32:35 +02:00
Dominic H.
cc81b4e501
gh-86608: Improve and restructure tarfile examples ( #121771 )
...
Add an example on how to write a tarfile to stdout; general improvements.
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2025-07-20 12:19:47 +00:00
Dominic H.
c6e6fe92cd
gh-130655: gettext: Add fallback testcase ( #136857 )
2025-07-20 14:08:13 +02:00
Nacho Caballero
9c2f91cde8
gh-136854: Exit on error in make venv
( #136856 )
...
Co-authored-by: Nacho Caballero <nacho.caballero@astrazeneca.com>
2025-07-20 12:08:00 +00:00
Hugo van Kemenade
dda9d0011f
gh-108362: Retarget incremental GC changes to 3.14 ( #125453 )
2025-07-20 12:56:55 +03:00
Olga Pustovalova
588d9fb84a
gh-136438: Make sure test_remote_pdb
pass with all optimization levels (GH-136788)
Tests / Ubuntu SSL tests with OpenSSL (push) Blocked by required conditions
Tests / Ubuntu SSL tests with AWS-LC (push) Blocked by required conditions
Tests / WASI (push) Blocked by required conditions
Tests / Hypothesis tests on Ubuntu (push) Blocked by required conditions
Tests / (push) Blocked by required conditions
Tests / Windows MSI (push) Blocked by required conditions
Tests / Change detection (push) Waiting to run
Tests / Docs (push) Blocked by required conditions
Tests / Check if Autoconf files are up to date (push) Blocked by required conditions
Tests / Check if generated files are up to date (push) Blocked by required conditions
Tests / Address sanitizer (push) Blocked by required conditions
Tests / Undefined behavior sanitizer (push) Blocked by required conditions
Tests / Cross build Linux (push) Blocked by required conditions
Tests / CIFuzz (push) Blocked by required conditions
Tests / All required checks pass (push) Blocked by required conditions
Lint / lint (push) Waiting to run
mypy / Run mypy on Lib/_pyrepl (push) Waiting to run
mypy / Run mypy on Lib/test/libregrtest (push) Waiting to run
mypy / Run mypy on Lib/tomllib (push) Waiting to run
mypy / Run mypy on Tools/build (push) Waiting to run
mypy / Run mypy on Tools/cases_generator (push) Waiting to run
mypy / Run mypy on Tools/clinic (push) Waiting to run
mypy / Run mypy on Tools/jit (push) Waiting to run
mypy / Run mypy on Tools/peg_generator (push) Waiting to run
2025-07-20 10:57:54 +02:00
Bénédikt Tran
6be49ee517
gh-136787: improve exception messages for invalid hash algorithms ( #136802 )
2025-07-20 08:49:34 +00:00
Hood Chatham
800d37feca
gh-124621: Emscripten: Fix regression in use-after-close error handling ( #136837 )
Tests / Ubuntu SSL tests with OpenSSL (push) Blocked by required conditions
Tests / Ubuntu SSL tests with AWS-LC (push) Blocked by required conditions
Tests / WASI (push) Blocked by required conditions
Tests / Hypothesis tests on Ubuntu (push) Blocked by required conditions
Tests / Address sanitizer (push) Blocked by required conditions
Tests / (push) Blocked by required conditions
Tests / Undefined behavior sanitizer (push) Blocked by required conditions
Tests / Cross build Linux (push) Blocked by required conditions
Tests / Windows MSI (push) Blocked by required conditions
Tests / Change detection (push) Waiting to run
Tests / Docs (push) Blocked by required conditions
Tests / Check if Autoconf files are up to date (push) Blocked by required conditions
Tests / Check if generated files are up to date (push) Blocked by required conditions
Tests / CIFuzz (push) Blocked by required conditions
Tests / All required checks pass (push) Blocked by required conditions
Lint / lint (push) Waiting to run
mypy / Run mypy on Lib/_pyrepl (push) Waiting to run
mypy / Run mypy on Lib/test/libregrtest (push) Waiting to run
mypy / Run mypy on Lib/tomllib (push) Waiting to run
mypy / Run mypy on Tools/build (push) Waiting to run
mypy / Run mypy on Tools/cases_generator (push) Waiting to run
mypy / Run mypy on Tools/clinic (push) Waiting to run
mypy / Run mypy on Tools/jit (push) Waiting to run
mypy / Run mypy on Tools/peg_generator (push) Waiting to run
2025-07-19 21:43:50 +02:00
Disconnect3d
69ea1b3a8f
gh-136839: Refactor simple dict.update calls ( #136811 )
...
Tests / Ubuntu SSL tests with OpenSSL (push) Blocked by required conditions
Tests / Ubuntu SSL tests with AWS-LC (push) Blocked by required conditions
Tests / WASI (push) Blocked by required conditions
Tests / Hypothesis tests on Ubuntu (push) Blocked by required conditions
Tests / Address sanitizer (push) Blocked by required conditions
Tests / (push) Blocked by required conditions
Tests / Undefined behavior sanitizer (push) Blocked by required conditions
Tests / Cross build Linux (push) Blocked by required conditions
Tests / Check if generated files are up to date (push) Blocked by required conditions
Tests / Windows MSI (push) Blocked by required conditions
Tests / Change detection (push) Waiting to run
Tests / Docs (push) Blocked by required conditions
Tests / Check if Autoconf files are up to date (push) Blocked by required conditions
Tests / CIFuzz (push) Blocked by required conditions
Tests / All required checks pass (push) Blocked by required conditions
Lint / lint (push) Waiting to run
mypy / Run mypy on Lib/_pyrepl (push) Waiting to run
mypy / Run mypy on Lib/test/libregrtest (push) Waiting to run
mypy / Run mypy on Lib/tomllib (push) Waiting to run
mypy / Run mypy on Tools/build (push) Waiting to run
mypy / Run mypy on Tools/cases_generator (push) Waiting to run
mypy / Run mypy on Tools/clinic (push) Waiting to run
mypy / Run mypy on Tools/jit (push) Waiting to run
mypy / Run mypy on Tools/peg_generator (push) Waiting to run
Refactor simple dict.update calls
This commit refactors simple `dict.update({key: value})` calls which can
be done via `dict[key] = value` instead.
I found those cases with the [semgrep](https://semgrep.dev/ ) tool:
```
$ semgrep --lang python --pattern '$DICT.update({$A: ...})'
┌─────────────────┐
│ 5 Code Findings │
└─────────────────┘
Lib/dataclasses.py
1268┆ slots.update({slot: doc})
Lib/multiprocessing/resource_tracker.py
50┆ _CLEANUP_FUNCS.update({
51┆ 'semaphore': _multiprocessing.sem_unlink,
52┆ })
⋮┆----------------------------------------
53┆ _CLEANUP_FUNCS.update({
54┆ 'shared_memory': _posixshmem.shm_unlink,
55┆ })
Lib/tkinter/scrolledtext.py
26┆ kw.update({'yscrollcommand': self.vbar.set})
Lib/xmlrpc/server.py
242┆ self.funcs.update({'system.multicall' : self.system_multicall})
```
2025-07-19 10:12:10 -07:00
sobolevn
67036f1ee1
gh-133875: Remove deprecated pathlib.PurePath.is_reserved
( #133876 )
2025-07-19 17:07:46 +00:00
Hood Chatham
7ae4749d06
gh-124621: Emscripten: Add support for async input devices (GH-136822)
...
This is useful for implementing proper `input()`. It requires the
JavaScript engine to support the wasm JSPI spec which is now stage 4.
It is supported on Chrome since version 137 and on Firefox and node
behind a flag.
We override the `__wasi_fd_read()` syscall with our own variant that
checks for a readAsync operation. If it has it, we use our own async
variant of `fd_read()`, otherwise we use the original `fd_read()`.
We also add a variant of `FS.createDevice()` called
`FS.createAsyncInputDevice()`.
Finally, if JSPI is available, we wrap the `main()` symbol with
`WebAssembly.promising()` so that we can stack switch from `fd_read()`.
If JSPI is not available, attempting to read from an AsyncInputDevice
will raise an `OSError`.
2025-07-19 17:14:29 +02:00
Slavaqq
1ba23244f3
gh-136793: Update the sampling rate in the documentation ( #136829 )
2025-07-19 15:00:46 +00:00