Commit graph

125140 commits

Author SHA1 Message Date
Victor Stinner
31f149d5b3
gh-128679: Use _PyThreadState_GET() in tracemalloc.c (#129126)
Replace uncommon PyGILState_GetThisThreadState() with common
_PyThreadState_GET().
2025-01-21 14:43:31 +01:00
Bénédikt Tran
6a0f915aae
gh-129064: Fix RST markup for the NEWS and What's New entries (#129131)
This amends the NEWS and What's New entries introduced in 0a6412f9cc.
2025-01-21 12:43:09 +01:00
Victor Stinner
01de4af3e1
gh-126925: Make PyConfig.use_system_logger read-only (#129124)
The variable is only used once during early Python initialization, it
doesn't make sense to modify it at runtime.
2025-01-21 12:02:38 +01:00
Victor Stinner
80189ff647
Remove PyInit__imp() function (#129125)
This function was exposed by mistake to the public C API. It's the
only "PyInit" function which is exposed.
2025-01-21 11:58:43 +01:00
Bénédikt Tran
fafc618e2f
gh-111178: fix UBSan failures in Modules/_ctypes (#129071)
This fixes UBSan failures for the following objects:

- `DictRemoverObject` and `StructParamObject`,
- `CDataObject` and `CFieldObject`, and
- `PyCFuncPtrObject` and `PyCArgObject`.

On the default build, we convert the `LOCK_PTR` and `UNLOCK_PTR` macros to
functions with an unused parameter to ease "unused variable" compiler warnings
suppression. Finally, we also remove some redundant casts to `PyObject *`.
2025-01-21 11:50:13 +01:00
Bénédikt Tran
36f341ca3e
gh-127787: allow retrieving the clipped slice length in _PyUnicodeError_GetParams (GH-128980) 2025-01-21 11:45:53 +01:00
Petr Viktorin
bf150f61ad
gh-126349: test_turtle: Add cleanup to avoid reference leaks (GH-129079) 2025-01-21 11:28:34 +01:00
Mark Shannon
f5b6356a11
GH-128563: Add new frame owner type for interpreter entry frames (GH-129078)
Add new frame owner type for interpreter entry frames
2025-01-21 10:15:02 +00:00
Petr Viktorin
d3b1bb228c
gh-128156: Guard use of ffi_type_complex_double on macOS system libffi (GH-128680)
* Determine ffi complex support at runtime
* Also, generate SIMPLE_TYPE_CHARS once at runtime
2025-01-21 10:59:18 +01:00
Mark Shannon
7239da7559
GH-127953: Make line number lookup O(1) regardless of the size of the code object (GH-128350) 2025-01-21 09:33:23 +00:00
Serhiy Storchaka
f7cc7d296c
gh-71339: Use new assertion methods in test_import and test_importlib (GH-129052) 2025-01-21 11:24:19 +02:00
smelnikov
da310d209a
Docs: fix typo in Doc/howto/mro.rst (GH-129095) 2025-01-21 10:22:13 +01:00
Hugo van Kemenade
417f7a9ef7
gh-128595: Fix test__colorize unexpected keyword argument 'file' on buildbots (#129070) 2025-01-21 11:20:54 +02:00
Adam Turner
e65a1eb93a
Revert "doc: add social cards generation support in sphinxext-opengraph (#129085)" (#129106) 2025-01-20 23:53:33 +00:00
Adam Turner
e54ac3b69e
GH-121970: Extract `changes` into a new extension (#129105) 2025-01-20 23:53:08 +00:00
Adam Turner
f3980af38b
Add Adam Turner to CODEOWNERS (#129104)
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2025-01-20 22:32:31 +00:00
Filipe Laíns 🇵🇸
e52ab564da
GH-92897: schedule the check_home deprecation to 3.15 (#129102) 2025-01-20 21:25:14 +00:00
Bénédikt Tran
5ed5572cac
gh-111178: fix UBSan failures in Modules/_multiprocessing/semaphore.c (#129084)
fix UBSan failures for `SemLockObject`
2025-01-20 20:43:55 +00:00
Filipe Laíns 🇵🇸
382340d559
doc: add social cards generation support in sphinxext-opengraph (#129085) 2025-01-20 20:41:27 +00:00
Filipe Laíns 🇵🇸
da36bccdac
doc: fix venv creating for the local Python using uv (#129094) 2025-01-20 21:04:05 +02:00
Wulian
5d57959d7d
gh-91279: ZipFile.writestr now respect SOURCE_DATE_EPOCH (#124435) 2025-01-20 13:12:29 -05:00
5ec1cff
dda02eb7be
GH-128131: Completely support random read access of uncompressed unencrypted files in ZipFile (#128143)
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2025-01-20 13:04:43 -05:00
Thomas Grainger
ed6934e71e
gh-128588: gh-128550: remove eager tasks optimization that missed and introduced incorrect cancellations (#129063)
Co-authored-by: Kumar Aditya <kumaraditya@python.org>
2025-01-20 17:13:01 +00:00
Mark Shannon
ab61d3f430
GH-128914: Remove conditional stack effects from bytecodes.c and the code generators (GH-128918) 2025-01-20 17:09:23 +00:00
Filipe Laíns 🇵🇸
0a6412f9cc
GH-129064: deprecate sysconfig.expand_makefile_vars (#129082) 2025-01-20 17:03:44 +00:00
Thomas Grainger
38a9956876
gh-128308: pass **kwargs to asyncio task_factory (#128768)
Co-authored-by: Kumar Aditya <kumaraditya@python.org>
2025-01-20 22:23:55 +05:30
Diego Russo
6c914bf85c
Move to public Linux arm64 hosted runners (#128964)
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2025-01-20 18:51:09 +02:00
Peter Bierma
6e02096e2f
gh-118915: C API: Document compiler flag macros (GH-129028) 2025-01-20 17:45:08 +01:00
Peter Bierma
e792f4bc2e
Docs C API: Clarify what happens when null bytes are passed to PyUnicode_AsUTF8 (#127458)
Co-authored-by: Stan U. <89152624+StanFromIreland@users.noreply.github.com>
Co-authored-by: Tomas R. <tomas.roun8@gmail.com>
Co-authored-by: Victor Stinner <vstinner@python.org>
2025-01-20 16:54:29 +01:00
Mark Shannon
f0f7b978be
GH-128939: Refactor JIT optimize structs (GH-128940) 2025-01-20 15:49:15 +00:00
nikalinov
e1fa2fcc7c
gh-129044: Update glossary entry for 'loader' to reflect current import system (#129073)
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2025-01-20 15:46:09 +00:00
Victor Stinner
8ceb6cb117
gh-129033: Remove _PyInterpreterState_SetConfig() function (#129048)
Remove _PyInterpreterState_GetConfigCopy() and
_PyInterpreterState_SetConfig() private functions. PEP 741 "Python
Configuration C API" added a better public C API: PyConfig_Get() and
PyConfig_Set().
2025-01-20 16:31:33 +01:00
Victor Stinner
573c181502
Add Configuration Options table to PyInitConfig API doc (#129062)
Document PyConfig members:

* dump_refs_file
* stdlib_dir
* use_frozen_modules
* _pystats
2025-01-20 15:46:45 +01:00
Serhiy Storchaka
38c3cf6320
gh-71339: Use new assertion methods in test_ctypes (GH-129054) 2025-01-20 13:30:00 +00:00
Bénédikt Tran
df66ff14b4
gh-128978: Fix a NameError in sysconfig.expand_makefile_vars (#128979)
This fixes a regression introduced by 4a53a397c3.
2025-01-20 13:27:14 +00:00
Bénédikt Tran
59fcae793f
Remove duplicated dict keys in test_{embed,long}.py fixtures (#128727) 2025-01-20 13:50:10 +01:00
Erlend E. Aasland
da0f47ceab
gh-111178: Regen clinic and fix exceptions.c post gh-128447 (#129060) 2025-01-20 12:46:30 +00:00
Serhiy Storchaka
a30277a06a
gh-71339: Use new assertion methods in test_capi (GH-129053) 2025-01-20 14:32:27 +02:00
Erlend E. Aasland
537296cdcd
gh-111178: Generate correct signature for most self converters (#128447) 2025-01-20 12:40:18 +01:00
Peter Bierma
4d0a6595a0
gh-128360: Add _Py_AssertHoldsTstate as assertion for holding a thread state (#128361)
Co-authored-by: Kumar Aditya <kumaraditya@python.org>
2025-01-20 17:04:35 +05:30
Serhiy Storchaka
c6b570e5e3
gh-71339: Use new assertion methods in test_asyncio (#129051) 2025-01-20 17:02:39 +05:30
Hugo van Kemenade
6f167d7134
gh-128595: Default to stdout isatty for colour detection instead of stderr (#128498)
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Co-authored-by: Victor Stinner <vstinner@python.org>
2025-01-20 12:52:42 +02:00
Victor Stinner
a429159797
Reorganize the PyInitConfig documentation (#129047)
Document the new PyInitConfig API before the old PyConfig API.
2025-01-20 11:42:04 +01:00
Tomas R.
9b1c1817af
Fix a typo in syslog's error message (#129029) 2025-01-20 10:11:08 +00:00
Victor Stinner
07c3518ffb
gh-129033: Remove _Py_InitializeMain() function (#129034)
Co-authored-by: Alyssa Coghlan <ncoghlan@gmail.com>
2025-01-20 10:03:22 +00:00
Serhiy Storchaka
c463270c73
gh-71339: Use new assertion methods in test_traceback (GH-128848) 2025-01-20 11:22:33 +02:00
Serhiy Storchaka
485d2e831e
gh-71339: Use assertIsSubclass() and assertNotIsSubclass() in test_decimal (GH-128827) 2025-01-20 11:20:49 +02:00
Serhiy Storchaka
36aaf4137d
gh-71339: Use new assertion methods in test_abc (GH-128826) 2025-01-20 11:19:43 +02:00
Serhiy Storchaka
da122b5fac
gh-71339: Improve error report for types in assertHasAttr() and assertNotHasAttr() (GH-128818) 2025-01-20 11:17:49 +02:00
Serhiy Storchaka
89c401fb9a
gh-71339: Use new assertion methods in test_functools (GH-128829) 2025-01-20 11:17:04 +02:00