Serhiy Storchaka
e18829a8ad
gh-132629: Deprecate accepting out-of-range values for unsigned integers in PyArg_Parse (GH-132630)
...
For unsigned integer formats in the PyArg_Parse* functions,
accepting Python integers with value that is larger than
the maximal value the corresponding C type or less than
the minimal value for the corresponding signed integer type
is now deprecated.
2025-07-13 12:44:54 +03:00
Bénédikt Tran
9e5cebd56d
gh-136547: allow to temporarily disable hash algorithms in tests ( #136570 )
2025-07-13 10:58:15 +02:00
Sachin Shah
171de05b48
gh-136523: Fix wave.Wave_write emitting an unraisable when open raises (GH-136529)
2025-07-13 08:49:12 +03:00
Serhiy Storchaka
be2c3d284e
gh-136549: Fix signature of threading.excepthook() (GH-136559)
2025-07-12 18:54:26 +03:00
Bast
5e1e21dee3
gh-91153: prevent a crash in bytearray.__setitem__(ind, ...) when ind.__index__ has side-effects ( #132379 )
...
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2025-07-12 13:37:52 +00:00
Kliment Lamonov
25335d297b
gh-134759: fix UnboundLocalError in email.message.Message.get_payload ( #136071 )
...
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2025-07-12 13:30:09 +00:00
Illia Volochii
5a20e79725
gh-99813: Start using SSL_sendfile when available ( #99907 )
...
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
2025-07-12 12:42:35 +00:00
Furkan Onder
dda70fa771
gh-99631: Add custom loads and dumps support for the shelve module ( #118065 )
...
Co-authored-by: Pieter Eendebak <pieter.eendebak@gmail.com>
Co-authored-by: Petr Viktorin <encukou@gmail.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2025-07-12 14:27:32 +02:00
Weilin Du
c564847e98
gh-89083: Add CLI tests for UUIDv{6,7,8} ( #136548 )
...
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2025-07-12 14:06:15 +02:00
Bénédikt Tran
2301cdb559
gh-135853: add math.fmax and math.fmin ( #135888 )
2025-07-12 11:31:10 +00:00
Bénédikt Tran
83d04a29a6
gh-136565: Improve and amend hashlib.__doc__ ( #136566 )
2025-07-12 11:02:27 +00:00
Petr Viktorin
c7d24b81c3
gh-111506: Add _Py_OPAQUE_PYOBJECT to hide PyObject layout & related API (GH-136505)
...
Allow Py_LIMITED_API for (Py_GIL_DISABLED && _Py_OPAQUE_PYOBJECT)
API that's removed when _Py_OPAQUE_PYOBJECT is defined:
- PyObject_HEAD
- _PyObject_EXTRA_INIT
- PyObject_HEAD_INIT
- PyObject_VAR_HEAD
- struct _object (i.e. PyObject) (opaque)
- struct PyVarObject (opaque)
- Py_SIZE
- Py_SET_TYPE
- Py_SET_SIZE
- PyModuleDef_Base (opaque)
- PyModuleDef_HEAD_INIT
- PyModuleDef (opaque)
- _Py_IsImmortal
- _Py_IsStaticImmortal
Note that the `_Py_IsImmortal` removal (and a few other issues)
means _Py_OPAQUE_PYOBJECT only works with limited
API 3.14+ now.
Co-authored-by: Victor Stinner <vstinner@python.org>
2025-07-12 09:55:12 +02:00
Raymond Hettinger
7f1e66ae0e
Minor edit: Improve comment readability and ordering (gh-136557)
2025-07-11 12:36:17 -07:00
Weilin Du
561212a033
Doc: More duplicate word fixes (GH-136299)
2025-07-11 21:18:47 +03:00
Victor Stinner
2c9a8011c6
gh-135906: Test the internal C API in test_cext ( #136247 )
...
Remove duplicated definition: atexit_datacallbackfunc type
is already defined by Include/cpython/pylifecycle.h.
2025-07-11 16:48:43 +02:00
Victor Stinner
cbf007beeb
gh-136156: Remove tempfile test_link_tmpfile() ( #136534 )
...
It's not always possible to guarantee that the file was opened with
O_TMPFILE even if tempfile._O_TMPFILE_WORKS is true.
2025-07-11 16:45:31 +02:00
sobolevn
3343fce05a
gh-136434: Fix docs generation of UnboundItem in subinterpreters ( #136435 )
2025-07-11 15:31:59 +03:00
Ethan Furman
49365bd110
gh-107538: [Enum] fix handling of inverted/negative values (GH-132273)
...
* Fix flag mask inversion when unnamed flags exist.
For example:
class Flag(enum.Flag):
A = 0x01
B = 0x02
MASK = 0xff
~Flag.MASK is Flag(0)
* EJECT and KEEP flags (IntEnum is KEEP) use direct value.
* correct Flag inversion to only flip flag bits
IntFlag will flip all bits -- this only makes a difference in flag sets with
missing values.
* correct negative assigned values in flags
negative values are no longer used as-is, but become inverted; i.e.
class Y(self.enum_type):
A = auto()
B = auto()
C = ~A # aka ~1 aka 0b1 110 (from enum.bin()) aka 6
D = auto()
assert Y.C. is Y.B|Y.D
2025-07-10 16:49:09 -07:00
Sergey Miryanov
c560df9658
gh-136517: Print uncollectable objects if DEBUG_UNCOLLECTABLE mode was set ( #136518 )
2025-07-10 22:13:23 +01:00
László Kiss Kollár
59acdba820
gh-135953: Implement sampling tool under profile.sample ( #135998 )
...
Implement a statistical sampling profiler that can profile external
Python processes by PID. Uses the _remote_debugging module and converts
the results to pstats-compatible format for analysis.
Co-authored-by: Pablo Galindo <pablogsal@gmail.com>
2025-07-10 18:44:24 +01:00
Stan Ulbrych
35e2c35970
gh-52876: Implement missing parameter in codecs.StreamReaderWriter functions ( #136498 )
...
Closes #52876
2025-07-10 17:42:14 +02:00
Dave Peck
f1b8d01c80
gh-132661: Add default value (of "") for Interpolation.expression ( #136441 )
2025-07-10 16:27:41 +02:00
Rogdham
f519918ec6
gh-136394: Fix race condition in test_zstd (GH-136432)
2025-07-10 08:47:27 -04:00
sobolevn
c176543349
gh-136438: Make sure test_builtins pass with all optimization levels ( #136474 )
2025-07-10 11:57:29 +03:00
Pablo Galindo Salgado
ea45a2f97c
gh-136476: Show the full stack in get_async_stack_trace in _remote_debugging ( #136483 )
2025-07-09 23:11:17 +00:00
Victor Stinner
92b33c9590
gh-136156: Skip test_tempfile.test_link_tmpfile() on Android ( #136430 )
...
Adds a test skip on platforms where hard links are not available (which includes Android).
2025-07-10 06:17:21 +08:00
Raymond Hettinger
798f791daf
Minor edit: Move comments closer to the code they describe (gh-136477)
2025-07-09 10:23:46 -07:00
Justin Su
77fa7a4dcc
gh-136447: Use self.loop instead of global loop variable in asyncio REPL ( #136448 )
2025-07-09 14:27:20 +05:30
Jelle Zijlstra
797abd1f7f
gh-134657: Remove newly added private names from asyncio.__all__ ( #134665 )
2025-07-09 13:25:46 +05:30
Neil Schemenauer
b6b99bf7f1
GH-91636: Clear weakrefs created by finalizers. (GH-136401)
...
Weakrefs to unreachable garbage that are created during running of
finalizers need to be cleared. This avoids exposing objects that
have `tp_clear` called on them to Python-level code.
2025-07-08 12:19:57 -07:00
Hugo van Kemenade
bc9bc078df
Update bytecode magic number in tests for the 3.14 release candidate ( #136427 )
2025-07-08 20:11:48 +03:00
Victor Stinner
6c81e8c57a
gh-136156: Allow using linkat() with TemporaryFile ( #136281 )
...
tempfile.TemporaryFile() no longer uses os.O_EXCL with os.O_TMPFILE,
so it's possible to use linkat() on the file descriptor.
2025-07-08 18:39:47 +02:00
AN Long
490eea0281
gh-136380: Fix import behavior for concurrent.futures.InterpreterPoolExecutor ( #136381 )
...
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
Co-authored-by: sobolevn <mail@sobolevn.me>
2025-07-08 13:32:14 +00:00
Pablo Galindo Salgado
ba9c198630
gh-136186: Fix race condition in test_external_inspection.test_only_active_thread ( #136347 )
2025-07-08 13:23:31 +01:00
sobolevn
db699db99d
gh-136297: Fix hypothesis and subTest usage in test_zoneinfo_property.py ( #136384 )
2025-07-08 07:51:36 +00:00
Kumar Aditya
51934000ba
gh-117657: enable test_capi under TSAN ( #136269 )
2025-07-08 13:05:24 +05:30
Kumar Aditya
0240ef4705
gh-98388: add tests for happy eyeballs ( #136368 )
2025-07-07 23:30:27 +05:30
Serhiy Storchaka
b7aa2a4b4d
gh-124486: Fix test_whichdb_ndbm in test_dbm on NetBSD (GH-136335)
...
On NetBSD, ndbm.open() does not fail for empty file.
2025-07-07 15:14:17 +03:00
Sergey B Kirpichev
3e849d75f4
gh-87790: support thousands separators for formatting fractional part of Fraction ( #132204 )
2025-07-07 11:16:31 +03:00
Sergey B Kirpichev
90a5b4402b
gh-87790: support thousands separators for formatting fractional part of Decimal ( #132202 )
...
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2025-07-07 11:16:27 +03:00
Serhiy Storchaka
85b817da94
gh-136289: Fix test_sqlite3 on platforms with strict UTF-8 filesystem (GH-136326)
2025-07-07 06:29:00 +00:00
Jelle Zijlstra
9312702d2e
gh-136316: Make typing.evaluate_forward_ref better at evaluating nested forwardrefs ( #136319 )
2025-07-06 16:44:20 -07:00
sobolevn
c89f76e6c4
gh-136021: Make type_params a required parameter for typing._eval_type ( #136332 )
2025-07-06 22:11:13 +03:00
sobolevn
06e347b846
gh-136285: Improve pickle protocol testing in test_interpreters ( #136286 )
2025-07-06 07:35:30 +00:00
Emma Smith
5dac137b9f
gh-136315: Fix skipped multithreading test in test_zstd ( #136320 )
...
Fix skipped test in test_zstd
2025-07-05 17:32:28 +00:00
Jeong, YunWon
887e5c8646
gh-136047: Allow typing._allow_reckless_class_checks to check _py_abc ( #136115 )
2025-07-05 14:24:33 +00:00
Victorien
5b56daa9d7
gh-130870: Preserve GenericAlias subclasses in typing.get_type_hints() ( #131583 )
2025-07-05 06:55:39 -07:00
sobolevn
5de7e3f973
gh-136297: Test all pickle protocols in test_zoneinfo_property.py ( #136298 )
2025-07-05 09:14:40 +03:00
Richard Levasseur
93263d4314
gh-135773: have pyvenv.cfg without home key anchor a venv and deduce home ( #135831 )
...
This is still formally undefined behaviour, but we may as well
keep the *same* undefined behaviour as previous versions.
PEP 796 proposes a cleaner and more consistent replacement for 3.15+
2025-07-04 23:44:37 +10:00
Serhiy Storchaka
8ac7613dc8
gh-102555: Fix comment parsing in HTMLParser according to the HTML5 standard (GH-135664)
...
* "--!>" now ends the comment.
* "-- >" no longer ends the comment.
* Support abnormally ended empty comments "<-->" and "<--->".
---------
Co-author: Kerim Kabirov <the.privat33r+gh@pm.me>
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
2025-07-04 07:00:23 +00:00