Kumar Aditya
2925462411
gh-127945: change _ctypes_test.c
static globals to thread local ( #132575 )
2025-04-16 23:11:27 +05:30
Nadeshiko Manju
b9e88ff4cb
gh-131798: Use sym_new_type
instead of sym_new_not_null
for _BUILD_LIST
, _BUILD_SLICE
, and _BUILD_MAP
(GH-132434)
...
---------
Signed-off-by: Manjusaka <me@manjusaka.me>
2025-04-17 01:17:48 +08:00
Serhiy Storchaka
62ff86fa55
gh-130104: Call __rpow__ in ternary pow() if necessary (GH-130251)
...
Previously it was only called in binary pow() and the binary
power operator.
2025-04-16 18:32:41 +03:00
Jelle Zijlstra
72da4a4458
typing: Add missing test case for Protocol inheritance ( #132597 )
2025-04-16 08:21:27 -07:00
Felix Scherz
71af090e24
gh-132493: lazy evaluation of annotations in typing._proto_hook
( #132534 )
...
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Co-authored-by: sobolevn <mail@sobolevn.me>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2025-04-16 08:20:35 -07:00
Victor Stinner
014c7f9047
gh-130052: Fix search_map_for_section() error handling ( #132594 )
...
* Don't call close() if the file descriptor is negative.
* If close() fails, chain the existing exception.
2025-04-16 13:56:58 +00:00
Jelle Zijlstra
7dcaebfb21
annotationlib: Move ForwardRef tests to test_annotationlib ( #132571 )
...
I started with just moving ForwardRefTests to test_annotationlib,
but found that it contained a number of tests for no_type_check, which
I moved to a new class in test_typing, as well as a number of tests that
are more appropriately classified as tests for get_type_hints().
One test, test_forward_equality_namespace(), was somewhat accidentally
depending on a global class A in test_typing. I added a class A in the
annotationlib tests instead.
Also add a useful comment in annotationlib.
2025-04-16 13:40:29 +00:00
Hugo van Kemenade
10a77619f9
Use Windows ARM64 hosted runners ( #132546 )
...
Co-authored-by: Diego Russo <diego.russo@arm.com>
2025-04-16 16:27:20 +03:00
Jelle Zijlstra
a8ca26d250
annotationlib: Remove some unnecessary dict copies ( #132495 )
2025-04-16 06:16:13 -07:00
sobolevn
c35c7353eb
gh-130941: Fix configparser
parsing values with allow_no_value
and interpolation
set (GH-130949)
2025-04-16 12:39:11 +02:00
Serhiy Storchaka
8b7cb947c5
gh-127591: Fix altering environment in test_urllib2 (unsetting no_proxy) (GH-132584)
2025-04-16 13:05:54 +03:00
Serhiy Storchaka
8cb177d09b
gh-132099: Accept an integer as the address for BTPROTO_HCI on Linux (GH-132525)
...
Previously only an integer packed in a tuple was accepted, while
getsockname() could return a raw integer.
Now the result of getsockname() is always acceptable as an address.
2025-04-16 13:02:51 +03:00
Serhiy Storchaka
82f74eb234
gh-132535: Fix resource warnings in test_timeout (GH-132572)
...
They were emitted if internet connection was not available.
2025-04-16 10:20:07 +03:00
Kumar Aditya
4b15d105a2
gh-132070: add PyObject_Realloc
suppression in free-threading ( #132468 )
2025-04-16 06:10:56 +05:30
Tian Gao
d19af00b90
gh-132536: Do not disable PY_THROW event in bdb ( #132537 )
2025-04-15 18:31:52 -04:00
Adam Turner
4f10b93d1b
Docs: Synchronise `indexsidebar.html
` with docsbuild-scripts ( #132567 )
2025-04-15 23:27:01 +01:00
Jelle Zijlstra
11f6603845
gh-132491: Rename annotationlib.value_to_string to type_repr ( #132492 )
2025-04-15 20:10:53 +00:00
Jelle Zijlstra
5e80fee41a
gh-129463: Remove two attributes from ForwardRef equality ( #132283 )
2025-04-15 12:58:21 -07:00
Bogdan Romanyuk
884df116d7
gh-114713: Handle case of an empty string passed to zoneinfo.ZoneInfo
( #114731 )
...
Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
Co-authored-by: Kirill Podoprigora <kirill.bast9@mail.ru>
2025-04-15 18:41:52 +00:00
Barney Gale
f3192dac66
GH-90812: Add test for urlopen()
of file URI for UNC path ( #132489 )
2025-04-15 19:16:34 +01:00
Jelle Zijlstra
666eeda13d
gh-132493: Support deferred annotations in Protocols ( #132494 )
2025-04-15 10:14:27 -07:00
Raymond Hettinger
818b6a9ead
Fix argument order in multinomial() example (gh-132557)
2025-04-15 11:50:52 -05:00
Chris Eibl
e94d168473
GH-131296: fix clang-cl warning on Windows in pegen.h ( #131584 )
2025-04-15 17:01:42 +01:00
Kumar Aditya
2ff5eb8582
gh-127945: move initialization of field desc to module exec in ctypes ( #132552 )
2025-04-15 19:30:33 +05:30
sobolevn
b6c552f9e6
gh-132176: Fix crash on type()
when tuple
subclass passed as bases
( #132212 )
...
Co-authored-by: Victor Stinner <vstinner@python.org>
2025-04-15 14:13:51 +03:00
Sergey B Kirpichev
e10fe81cc6
gh-130664: support '_' (just as ',') in Decimal's formatting ( #132155 )
2025-04-15 12:38:03 +02:00
T. Wouters
c66ffcf8e3
gh-129987: Selectively re-enable SLP autovectorization of _PyEval_EvalFrameDefault ( #132530 )
...
Only disable SLP autovectorization of `_PyEval_EvalFrameDefault` on newer
GCCs, as the optimization bug seems to exist only on GCC 12 and later, and
before GCC 9 disabling the optimization has a dramatic performance impact.
2025-04-15 09:39:32 +00:00
Barney Gale
0879ebc953
GH-123599: Match file:
URL hostname against machine hostname in urllib ( #132523 )
...
In `_is_local_authority()`, return early if the authority matches the
machine hostname from `socket.gethostname()`, rather than resolving the
names and matching IP addresses.
2025-04-15 01:05:06 +01:00
Serhiy Storchaka
102f825c51
gh-124476: Fix decoding from the locale encoding in the C.UTF-8 locale (GH-132477)
2025-04-14 21:32:41 +03:00
Serhiy Storchaka
61638418a7
gh-70145: Add support for channels in Bluetooth HCI protocol (GH-132481)
2025-04-14 20:09:16 +03:00
Stan Ulbrych
d22604a6d1
gh-85702: Catch IsADirectoryError in zoneinfo ( #131333 )
...
Co-authored-by: Victor Stinner <vstinner@python.org>
2025-04-14 17:07:51 +00:00
Semyon Moroz
bd47ec954d
gh-131885: Document /
for codecs
functions ( #131992 )
2025-04-14 18:55:29 +02:00
Jeremy Fleischman
939476bbbb
gh-131803: Clarify that you must register signal handlers for set_wakeup_fd ( #131859 )
2025-04-14 18:46:11 +02:00
RUANG (James Roy)
8768df2fe9
gh-46236: Add missing PyUnicode_FromOrdinal() doc ( #132040 )
2025-04-14 18:40:39 +02:00
Tomasz Pytel
4c12a2db15
gh-131757: allow lru_cache functions to execute concurrently ( #131758 )
2025-04-14 18:31:19 +02:00
Bénédikt Tran
45c447bf91
gh-132515: de-duplicate test_dataclass_derived_generic_from_slotted_base
( #132516 )
2025-04-14 15:06:38 +00:00
Yongzi Li
4865c09cf3
Docs: fix some typos in Doc/library
( #132511 )
2025-04-14 13:24:46 +00:00
Mark Shannon
844596c09f
GH-131498: Cases generator: Allow input and 'peek' variables to be modified (GH-132506)
2025-04-14 12:19:53 +01:00
Kumar Aditya
be763e550e
gh-127945: fix thread safety and add lock held assertions to paramfunc in ctypes ( #132473 )
2025-04-14 14:05:06 +05:30
Serhiy Storchaka
522766aa23
gh-71339: Use new assertion methods in the email tests (GH-129055)
2025-04-14 09:25:58 +03:00
Serhiy Storchaka
7076d076c2
gh-71339: Use new assertion methods in the http tests (GH-129058)
2025-04-14 09:24:54 +03:00
Serhiy Storchaka
f98b9b4cbb
gh-71339: Use new assertion methods in the urllib tests (GH-129056)
2025-04-14 09:24:41 +03:00
Gregory P. Smith
7a29c9883f
GH-115322: fix ctypes call_function audit hook on 32-bit platforms (GH-132496)
...
* GH-115322: fix ctypes call_function audit hook on 32-bit platforms.
It was using a signed conversion to communicate the function id (pointer) value.
2025-04-14 06:22:29 +00:00
Serhiy Storchaka
f7b24ffefd
gh-124986: Fix test_no_leaking in test_subprocess on NetBSD and FreeBSD (GH-132476)
...
On platforms where the file descriptor limit is larger than FD_SETSIZE
that test was always skipped (FreeBSD) or always failing (NetBSD).
2025-04-14 09:15:12 +03:00
Serhiy Storchaka
1fc1df8dcc
gh-132099: Harmonize Bluetooth address handling (GH-132486)
...
Now all protocols always accept the Bluetooth address as string and
getsockname() always returns the Bluetooth address as string.
* BTPROTO_SCO now accepts not only bytes, but str.
* BTPROTO_SCO now checks address for embedded null.
* On *BSD, BTPROTO_HCI now accepts str instead of bytes.
* On FreeBSD, getsockname() for BTPROTO_HCI now returns str instead of bytes.
* On NetBSD and DragonFly BDS, BTPROTO_HCI now checks address for embedded null.
2025-04-14 08:58:56 +03:00
Barney Gale
ccad61e35d
GH-125866: Support complete "file:" URLs in urllib ( #132378 )
...
Add optional *add_scheme* argument to `urllib.request.pathname2url()`; when
set to true, a complete URL is returned. Likewise add optional
*require_scheme* argument to `url2pathname()`; when set to true, a complete
URL is accepted.
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2025-04-14 01:49:02 +01:00
Jelle Zijlstra
4d3ad0467e
gh-132064: Make annotationlib use __annotate__ if only it is present ( #132195 )
2025-04-13 16:32:44 -07:00
abhi-jha
a1cd4ca7f4
gh-132388: fix typos in Lib/test/test_hmac.py
( #132480 )
...
Fix typos that slipped in GH-132389 (commit 9634085af3
).
2025-04-13 22:26:58 +00:00
Tian Gao
084d6dc122
gh-120144: Refactor bdb monitoring backend to match settrace behavior ( #132484 )
2025-04-13 17:49:35 -04:00
Robin Jadoul
2666a06d33
GH-115322: Add missing audit hooks (GH-115624)
...
Add extra audit hooks to catch C function calling from ctypes,
reading/writing files through readline and executing external
programs through _posixsubprocess.
* Make audit-tests for open pass when readline.append_history_file is unavailable
* Less direct testing of _posixsubprocess for audit hooks
* Also remove the audit hook from call_cdeclfunction now that _ctypes_callproc does it instead.
* reword the NEWS entry.
* mention readline in NEWS
* add versionchanged markers
* fix audit_events.rst versionadded
* doc lint
---------
Co-authored-by: Gregory P. Smith <greg@krypto.org>
2025-04-13 21:46:20 +00:00