Chris Eibl
49fc1f215a
Fix warnings set but not used [-Wunused-but-set-variable]
in remote_debug.h ( #135290 )
2025-06-10 01:05:06 +01:00
Zanie Blue
2e1ad6eb26
Fix definition of _Py_RemoteDebug_
symbols for static linking ( #135146 )
2025-06-10 01:03:55 +01:00
Alper
a58026a5e3
gh-116738: Make _heapq module thread-safe ( #135036 )
...
Use critical sections to make heapq methods that update the heap thread-safe when the GIL is disabled.
---------
Co-authored-by: mpage <mpage@meta.com>
2025-06-09 10:57:29 -07:00
Chris Eibl
cc8e6d2703
GH-131296: Suppress clang-cl warnings in socketmodule.c (GH-131821)
2025-06-09 17:38:41 +01:00
Petr Viktorin
28d91d06f1
gh-127833: Reword and expand the Notation section (GH-134443)
...
Prepare the docs for using the notation used in the `python.gram`
file. If we want to sync the two, the meta-syntax should be the same.
Link the Full Grammar docs here; keep only a few extras.
Also, remove the distinction between lexical and syntactic rules,
except for whitespace handling.
With f- and t-strings, the line between the two is blurry.
Co-authored-by: Blaise Pabon <blaise@gmail.com>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
Co-authored-by: Colin Marquardt <cmarqu42@gmail.com>
2025-06-09 15:50:11 +02:00
Wulian233
f90483e13a
gh-135001: Explicitly specify the encoding parameter value of calendar.HTMLCalendar
as 'utf-8' ( #135002 )
2025-06-09 15:40:09 +02:00
Victor Stinner
aaad2e81ce
gh-133968: Update PyUnicodeWriter_WriteASCII() documentation ( #135297 )
...
The function was added to Python 3.14.
2025-06-09 14:47:02 +02:00
Chris Eibl
0045100ccb
GH-135287: clang-cl PGO builds on Windows fail with could not open '/GENPROFILE'
(GH-135289)
2025-06-09 12:52:38 +01:00
Noam Cohen
b150b6aca7
gh-131798: Optimize _UNARY_INVERT
(GH-135222)
2025-06-09 18:33:18 +08:00
Bénédikt Tran
c19e36cc4e
gh-131316: fix invalid DECREF
in _md5.md5.copy()
( #135291 )
...
This amends commit 261633bd3f48607478f50d12d8025cd4bb36f6f4.
2025-06-09 09:10:32 +00:00
Edward Z. Yang
8441b263af
bpo-45210: Document that error indicator may be set in tp_dealloc ( #28358 )
...
Signed-off-by: Edward Z. Yang <ezyang@fb.com>
Signed-off-by: Edward Z. Yang <ezyang@meta.com>
Co-authored-by: Victor Stinner <vstinner@python.org>
2025-06-09 08:56:32 +00:00
Bénédikt Tran
3cb109796d
gh-135004: rewrite and cleanup blake2module.c
( #135006 )
...
* Cleanup imports and update module docstring.
* Simplify detection of SIMD support.
* Correctly guard `update()` cases.
* Rewrite `py_blake2b_or_s_new` and rename it to `py_blake2_new`.
* Rewrite `blake2_blake2b_copy_locked` and `py_blake2_clear`.
* Refactor computations of `digest` and `hexdigest`.
* Simplify `py_blake2b_get_name` and `py_blake2b_get_block_size`.
* Add `hacl_get_blake2_info` to extract static BLAKE-2 information.
This new helper is used by `py_blake2b_get_digest_size`, but can
be later used to expose `key_length` more easily.
2025-06-09 09:17:43 +02:00
Bénédikt Tran
83b94e856e
gh-135234: improve _hashlib
exceptions when reporting an OpenSSL function failure ( #135250 )
...
- Refactor `get_openssl_evp_md_by_utf8name` error branches.
- Refactor `HASH.{digest,hexdigest}` computations.
- Refactor `_hashlib_HASH_copy_locked` and `locked_HMAC_CTX_copy`.
2025-06-09 09:13:29 +02:00
Ezio Melotti
2677dd017a
Use f-strings in csv docs example ( #135245 )
2025-06-08 15:28:37 -07:00
Vladyslav Lazoryk
8d17a412da
gh-135263: Fix typo in token.NAME documentation ( #135275 )
2025-06-08 22:59:26 +03:00
Jason R. Coombs
8d6eb0c262
gh-135276: Refresh zipfile.Path
from zipp 3.23 ( #135277 )
...
Apply changes from zipp 3.23
2025-06-08 19:20:20 +00:00
Alper
aac22ea212
Add compile_commands.json to .gitignore ( #135111 )
2025-06-08 17:55:12 +01:00
Stan Ulbrych
254bdac711
Update tutorial for new "Copy" button ( #135007 )
...
Co-authored-by: Sergey B Kirpichev <skirpichev@gmail.com>
2025-06-08 19:33:19 +03:00
Bénédikt Tran
aee45fd03f
gh-134531: refactor _hashlib
logic for handling NIDs and EVP_MDs ( #135254 )
2025-06-08 12:34:57 +00:00
Yongzi Li
158e5162bf
gh-134976: document the exception type that can be raised by s[i]
( #134977 )
2025-06-08 14:28:55 +02:00
LamentXU
1cb7163872
gh-135244: generate UUID random Node ID with a CSPRNG as per RFC 9562, §6.10.3 ( #135226 )
...
This aligns with the recommendations of RFC 9562, Section 6.10, paragraph 3 [1].
[1]: https://www.rfc-editor.org/rfc/rfc9562.html#section-6.10-3 .
---------
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2025-06-08 11:46:16 +00:00
Bénédikt Tran
4372011928
gh-134531: fix _hashlib
clinic directive post GH-134626 ( #135249 )
2025-06-08 07:43:32 +00:00
Jiucheng(Oliver)
bcb6b45cb8
gh-134151 Fix TypeError
in email.utils.decode_params
when sorting RFC 2231 continuations ( #134687 )
...
- Fix sorting logic in `email.utils.decode_params` to handle None values.
- Update tests for RFC 2231 continuation sorting.
2025-06-08 09:13:21 +02:00
Bénédikt Tran
d610f11d21
gh-133579: correctly report C curses errors in _curses_panel
( #134629 )
...
This is a follow-up to ee36db550076e5a9185444ffbc53eaf8157ef04c.
2025-06-08 09:10:52 +02:00
Amit Lavon
8fdbbf8b18
GH-131798: Type-propagate string/list/tuple slices (GH-134671)
2025-06-07 14:08:44 -07:00
Daniel Golding
ac9c3431cc
gh-134876: Add fallback for when process_vm_readv fails with ENOSYS ( #134878 )
2025-06-07 19:32:06 +01:00
Petr Viktorin
24069fbca8
Revert "gh-133390: Support SQL keyword completion for sqlite3 CLI ( #133393 )" temporarily (GH-135232)
...
This reverts commit 62b3d2d443785c4ea5262edb4f9f7040440f9463,
which broke buildbots
2025-06-07 08:56:43 +00:00
Tomas R.
46151648ca
GH-131798: Optimize away type(x) in the JIT when the result is known (GH-135194)
2025-06-06 16:44:43 -07:00
Yuki Kobayashi
f00512db20
Docs: Update PyExc_*
tables in the c-api documentation (GH-131640)
...
Add `PyExc_BaseExceptionGroup` and `PyExc_EncodingWarning`
2025-06-06 17:51:47 +02:00
Tan Long
62b3d2d443
gh-133390: Support SQL keyword completion for sqlite3 CLI ( #133393 )
2025-06-06 16:52:41 +02:00
Petr Viktorin
b22b964a5c
gh-57089: Note _layout_ in the bitfield docs (GH-134148)
...
Co-authored-by: Meador Inge <meadori@gmail.com>
Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
2025-06-06 16:51:40 +02:00
Petr Viktorin
1adca08d65
gh-134160: Use PyModuleDef.m_free in the example module xxlimited (GH-135174)
...
Co-authored-by: neonene <53406459+neonene@users.noreply.github.com>
2025-06-06 14:08:58 +00:00
Petr Viktorin
e413e26719
gh-134891: Add PyUnstable_Unicode_GET_CACHED_HASH (GH-134892)
2025-06-06 15:51:00 +02:00
Jean-Louis GUENEGO
343182853f
feat(docs): type fix - apply pep8 by using docstring instead of comment in the doc. ( #135181 )
...
Giving the right example incitates the tutorial readers to do the same in the future.
2025-06-06 15:16:12 +02:00
Rafael Fontenelle
39859fcac5
Fix versionadded directive rendering in c-api/arg.rst ( #135199 )
2025-06-06 14:23:07 +02:00
Victor Stinner
82415acf62
gh-134036: Update test_syntax for gh-133999 ( #135204 )
2025-06-06 12:22:14 +00:00
Victor Stinner
e004cf8fd5
gh-134993: Add os.lstat() to os.supports_dir_fd ( #135188 )
2025-06-06 14:11:49 +02:00
Serhiy Storchaka
6ef06fad84
gh-135120: Add test.support.subTests() (GH-135121)
2025-06-06 13:52:48 +02:00
sobolevn
0d9ccc87a2
gh-134036: Improve error messages for invalid raise
statements ( #134077 )
2025-06-06 01:51:06 +01:00
Weipeng Hong
a7d41e8aab
gh-135155: Added dependencies required for compiling the _zstd module (GH-135156)
2025-06-06 00:44:25 +00:00
Mark Shannon
b90ecea9e6
GH-132554: Fix tier2 FOR_ITER
implementation and optimizations (GH-135137)
2025-06-05 18:53:57 +01:00
Sergey Miryanov
d9cad074d5
gh-134155: fix AttributeError in email._header_value_parser.get_address ( #134194 )
...
Append the defect to defects instead of to the parse tree.
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
2025-06-05 13:28:11 -04:00
Weipeng Hong
1b55e12766
gh-135166: Fix exception type expected by test.test_zstd (GH-135167)
2025-06-05 17:00:07 +01:00
rialbat
8919cb4ad9
gh-135161: Remove redundant NULL check for 'exc' after dereference in ceval.c ( #135162 )
2025-06-05 17:08:48 +02:00
Victor Stinner
9258f3da91
gh-134989: Fix Py_RETURN_NONE in the limited C API (GH-135165)
...
Fix Py_RETURN_NONE, Py_RETURN_TRUE and Py_RETURN_FALSE macros in the
limited C API 3.11 and older:
Don't treat Py_None, Py_True and Py_False as immortal.
2025-06-05 14:43:47 +02:00
Emma Smith
4b44b3409a
gh-134938: Add set_pledged_input_size() to ZstdCompressor (GH-135010)
2025-06-05 14:31:49 +03:00
Victor Stinner
3d396ab759
gh-135124: Change stdout errors in regrtest worker process ( #135138 )
...
Set sys.stdout encoder error handler to backslashreplace in regrtest
workers to avoid UnicodeEncodeError when printing a traceback
or any other non-encodable character.
Move the code from the Regrtest class to setup_process().
Call setup_process() earlier, before displaying regrtest headers.
2025-06-05 11:17:03 +02:00
Malcolm Smith
2e1544fd2b
gh-131531: android.py enhancements to support cibuildwheel ( #132870 )
...
Modifies the environment handling and execution arguments of the Android management
script to support the compilation of third-party binaries, and the use of the testbed to
invoke third-party test code.
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
Co-authored-by: Russell Keith-Magee <russell@keith-magee.com>
2025-06-05 13:46:16 +08:00
mpage
6b77af257c
gh-134889: Fix handling of a few opcodes when optimizing LOAD_FAST
( #134958 )
...
We were incorrectly handling a few opcodes that leave their operands on the stack. Treat all of these conservatively; assume that they always leave operands on the stack.
2025-06-04 16:07:58 -07:00
T. Wouters
e598eecf4c
gh-135144: Add _remote_debugging
to the MSI (legacy) Windows installers. ( #135145 )
...
Add _remote_debugging to the MSI (legacy) installers.
2025-06-04 21:39:00 +02:00