bkap123
9e0802330c
gh-145036: Fix data race for list capacity in free-threading ( #145365 )
...
Co-authored-by: Kumar Aditya <kumaraditya@python.org>
2026-03-10 22:00:11 +05:30
Serhiy Storchaka
3f33bf83e8
gh-145743: Fix inconsistency after calling Struct.__init__() with invalid format (GH-145744)
...
Only set the format attribute after successful (re-)initialization.
2026-03-10 18:29:23 +02:00
Farhan Saif
bf4017b161
gh-125053: Document that ob_mutex must only be used via critical section API ( #144599 )
...
Add a warning in the free-threading extensions howto explaining that
PyObject.ob_mutex is reserved for the critical section API and must not
be locked directly with PyMutex_Lock, as this can cause deadlocks.
Extension authors who need their own lock should add a separate PyMutex
field to their object struct.
Also add an ob_mutex member entry under PyObject in the C API reference
(Doc/c-api/structures.rst) with a cross-reference to the howto.
Co-authored-by: Victor Stinner <vstinner@python.org>
2026-03-10 17:23:39 +01:00
Alexander Shadchin
2756d56eef
gh-85277: Fix building without stropts.h or empty stropts.h ( #143521 )
2026-03-10 17:02:57 +01:00
Ali Towaiji
2114da976c
gh-145591: Move slicing note to __getitem__ (GH-145606)
2026-03-10 16:48:41 +01:00
Charlie Lin
467507a651
gh-145697: Add .sql and .sqlite3 recognition in mimetypes (GH-145698)
...
Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
Co-authored-by: Benedikt Johannes <benedikt.johannes.hofer@gmail.com>
2026-03-10 16:21:33 +01:00
Peter Bierma
7990313afa
Docs: Improve the C API documentation involving threads (GH-145520)
...
Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
2026-03-10 10:57:13 -04:00
Hugo van Kemenade
7fbdc8fb54
Merge branch 'main' of https://github.com/python/cpython
2026-03-10 16:41:02 +02:00
Hugo van Kemenade
1900aa9d36
Post 3.15.0a7
2026-03-10 16:40:10 +02:00
Adorilson Bezerra
9585f509d7
gh-106318: Add examples for str.isspace() docs ( #145399 )
2026-03-10 16:19:24 +02:00
Steve Dower
ae0d2875bc
gh-145035: Allows removing the _pyrepl module to completely disable the modern REPL (GH-145159)
2026-03-10 14:58:32 +01:00
Matt Van Horn
2d35f9bc1c
gh-145492: Fix defaultdict __repr__ infinite recursion (GH-145659)
...
Co-Authored-By: Thomas Kowalski <thom.kowa@gmail.com>
2026-03-10 14:20:42 +01:00
Hugo van Kemenade
6024d3c6da
Python 3.15.0a7
2026-03-10 14:31:15 +02:00
Kumar Aditya
728e4a075e
gh-142651: use NonCallableMock._lock for thread safety of call_count ( #142922 )
2026-03-10 12:11:12 +00:00
Hugo van Kemenade
368a26777a
gh-142927: Detect system theme in flame graph like in heatmap ( #144885 )
2026-03-10 13:38:48 +02:00
Hugo van Kemenade
55b36fdb3d
gh-133879: Copyedit "What's new in Python 3.15" ( #145737 )
2026-03-10 13:11:43 +02:00
Sergey Miryanov
478a315b7a
GH-145247: Implement _PyTuple_FromPair() ( #145325 )
...
Implement _PyTuple_FromPair() and _PyTuple_FromPairSteal().
Co-authored-by: Pieter Eendebak <pieter.eendebak@gmail.com>
Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Bartosz Sławecki <bartosz@ilikepython.com>
Co-authored-by: Kumar Aditya <kumaraditya@python.org>
2026-03-10 11:44:20 +01:00
Pieter Eendebak
3f7141dac9
gh-145376: Fix refleaks and double decref for code in Python/ ( #145666 )
2026-03-10 10:46:13 +01:00
Emma Smith
19676e5fc2
gh-145607: Ensure BIG_DATA has two compressed blocks in test_bz2 ( #145730 )
2026-03-10 11:21:57 +02:00
Stan Ulbrych
bdf0105291
gh-103997: Remove incorrect statements about -c dedenting (gh-138624)
2026-03-10 09:56:00 +01:00
Hugo van Kemenade
170d85a37d
gh-145731: Fix negative timestamp during DST on Windows (GH-145728)
2026-03-10 09:45:07 +01:00
Hai Zhu
66eafc9ea7
gh-144681: Fix JIT trace builder assertion failure when conditional branch jump target coincides with fallthrough target (GH-144742)
2026-03-10 12:12:48 +08:00
Stan Ulbrych
099943b122
Vary compiler flags in fuzz_pycompile ( #145236 )
...
* Vary compiler flags in fuzz_pycompile
* Drop `PyCF_SOURCE_IS_UTF8`
2026-03-09 22:51:00 +00:00
Sam Gross
0b65c88c2a
gh-145685: Stop the world when updating MRO of existing types (gh-145707)
...
We already have a stop-the-world pause elsewhere in this code path
(type_set_bases) and this makes will make it easier to avoid contention
on the TYPE_LOCK when looking up names in the MRO hierarchy.
Also use deferred reference counting for non-immortal MROs.
2026-03-09 18:41:07 -04:00
Stan Ulbrych
63eaaf9599
gh-145701: Fix __classdict__ & __conditional_annotations__ in class-scope inlined comprehensions (GH-145702)
2026-03-09 12:56:41 -07:00
Stan Ulbrych
d6c1763a08
Remove the distutils-sig@python.org email in 'Installing Python Modules' ( #145613 )
2026-03-09 19:43:13 +00:00
Filipe Laíns
64d6c75dd0
GH-145273: don't skip missing platstdlib warning if stdlib_zip is found ( #145544 )
2026-03-09 19:37:33 +00:00
Hugo van Kemenade
f31ac36df6
Docs: Update programming FAQ ( #144573 )
...
Co-authored-by: Savannah Ostrowski <savannah@python.org>
Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
Co-authored-by: Stan Ulbrych <stan@ulbrych.org>
2026-03-09 20:23:11 +02:00
Petr Viktorin
07a39ca07e
gh-145278: Revert "freeze encodings (partially) and linecache ( #145279 )" ( #145689 )
2026-03-09 18:18:14 +00:00
Stan Ulbrych
255e79fa95
gh-143055: Fix crash in AST unparser when unparsing dict comprehension unpacking ( #145556 )
2026-03-09 10:37:23 -07:00
Sam Gross
d76df75f51
gh-145615: Fix mimalloc page leak in the free-threaded build (gh-145626)
...
Fix three issues that caused mimalloc pages to be leaked until the
owning thread exited:
1. In _PyMem_mi_page_maybe_free(), move pages out of the full queue
when relying on QSBR to defer freeing the page. Pages in the full
queue are never searched by mi_page_queue_find_free_ex(), so a page
left there is unusable for allocations.
2. Move _PyMem_mi_page_clear_qsbr() from _mi_page_free_collect() to
_mi_page_thread_free_collect() where it only fires when all blocks
on the page are free (used == 0). The previous placement was too
broad: it cleared QSBR state whenever local_free was non-NULL, but
_mi_page_free_collect() is called from non-allocation paths (e.g.,
page visiting in mi_heap_visit_blocks) where the page is not being
reused.
3. In _PyMem_mi_page_maybe_free(), use the page's heap tld to find the
correct thread state for QSBR list insertion instead of
PyThreadState_GET(). During stop-the-world pauses, the function may
process pages belonging to other threads, so the current thread
state is not necessarily the owner of the page.
2026-03-09 13:24:34 -04:00
Yashraj
171133aa84
gh-141617: clarify concurrent.futures.ThreadPoolExecutor deadlock example ( #141620 )
...
---------
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2026-03-09 16:30:00 +00:00
Maciej Olko
fc03cdccc0
gh-139588: Docs: fix PDF build ( #145480 )
2026-03-09 18:19:02 +02:00
Mark Shannon
27c49707df
GH-144688: Fix refleaks in JIT when optimization fails (GH-145420)
2026-03-09 15:21:33 +00:00
Victor Stinner
0dfe649400
gh-141510: Optimize frozendict(frozendict) ( #145592 )
...
Return the same object unmodified if it's exactly the frozendict
type.
Optimize also PyFrozenDict_New(frozendict).
2026-03-09 15:47:02 +01:00
Daan De Meyer
1564e231aa
gh-145541: Fix InvalidStateError in BaseSubprocessTransport._call_connection_lost() ( #145554 )
2026-03-09 19:37:23 +05:30
Petr Viktorin
d64f83d07b
gh-78773: Improve ctypes dynamic library loading docs (GH-145313)
2026-03-09 15:02:06 +01:00
Victor Stinner
39aa415296
gh-145376: Fix _cursesmodule.c build on FreeBSD/macOS ( #145669 )
2026-03-09 14:53:52 +01:00
Petr Viktorin
44855458a4
Document that PyType_GetModule returns a borrowed ref (GH-145612)
2026-03-09 14:32:28 +01:00
Filipe Laíns
3a0c716ad4
GH-145278: freeze encodings (partially) and linecache ( #145279 )
2026-03-09 13:28:00 +00:00
Pieter Eendebak
886bc6e14b
gh-145376: Fix various reference leaks in Objects/ and Modules/ ( #145385 )
...
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
2026-03-09 14:19:36 +01:00
Pieter Eendebak
8060aa5d7d
gh-145376: Fix various refleaks in Objects/ ( #145609 )
2026-03-09 14:17:27 +01:00
Pieter Eendebak
201e18312c
gh-145376: Fix reference leaks in _lprof.c ( #145539 )
2026-03-09 13:50:45 +01:00
Chris Eibl
b4460925a4
Fix intermittent test_ci_fuzz_stdlib failures (GH-145641)
2026-03-09 10:23:34 +01:00
Hood Chatham
015613384f
gh-145219: Add Emscripten cross-build and clean configurability ( #145581 )
...
Modifies the Emscripten build script to allow for custom cross-build directory
names, and to only clean Emscripten-specific paths (optionally including the
build python).
Co-authored-by: Russell Keith-Magee <russell@keith-magee.com>
2026-03-09 02:25:21 +00:00
James
5a15a52dd1
gh-145642: Docs: Avoid warning for invalid escape sequence in tutorial ( #145643 )
...
* Match tutorial output to real interpreter output
* Avoid invalid escape sequence in example
Co-authored-by: Ned Batchelder <ned@nedbatchelder.com>
---------
Co-authored-by: Ned Batchelder <ned@nedbatchelder.com>
2026-03-08 18:41:47 -04:00
Hugo van Kemenade
149c465750
Fix bug notifier for issues with no body text ( #145603 )
2026-03-07 16:53:13 +02:00
Ramin Farajpour Cami
2cf6b2caad
gh-145623: Fix crashes on uninitialized struct.Struct objects (gh-145624)
2026-03-07 22:31:45 +09:00
Pieter Eendebak
0aeaaafac4
gh-145376: Fix refleak in queuemodule.c out-of-memory path ( #145543 )
2026-03-07 14:35:08 +05:30
AN Long
46761c9760
gh-116738: Make mmap.set_name thread-safe ( #145555 )
...
* Add critical section around mmap.set_name to make it thread-safe
* Add news entry
* Apply suggestion from @aisk
2026-03-07 17:14:44 +09:00