summaryrefslogtreecommitdiffstats
path: root/Modules
Commit message (Collapse)AuthorAgeFilesLines
* [3.12] gh-126876: Fix socket internal_select() for large timeout (GH-126968) ↵Miss Islington (bot)2024-12-031-1/+4
| | | | | | | | | | | | | (#127003) gh-126876: Fix socket internal_select() for large timeout (GH-126968) If the timeout is larger than INT_MAX, replace it with INT_MAX, in the poll() code path. Add an unit test. (cherry picked from commit b3687ad454c4ac54c8599a10f3ace8a13ca48915) Co-authored-by: Victor Stinner <vstinner@python.org>
* [3.12] gh-126618: fix repr(itertools.count(sys.maxsize)) (GH-127048) (#127510)Sergey B Kirpichev2024-12-021-6/+3
| | | | | (cherry picked from commit 930ba0ce605eee9e3b992fa368b00a3f2b7dc4c1) Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
* [3.12] gh-127190: Fix local_setattro() error handling (GH-127366) (#127368)Miss Islington (bot)2024-11-281-1/+1
| | | | | | | | | gh-127190: Fix local_setattro() error handling (GH-127366) Don't make the assumption that the 'name' argument is a string. Use repr() to format the 'name' argument instead. (cherry picked from commit 20657fbdb14d50ca4ec115da0cbef155871d8d33) Co-authored-by: Victor Stinner <vstinner@python.org>
* [3.12] gh-124008: Fix calculation of the number of written bytes for the ↵Miss Islington (bot)2024-11-271-28/+90
| | | | | | | | | | | | | | | Windows console (GH-124059) (GH-127326) Since MultiByteToWideChar()/WideCharToMultiByte() is not reversible if the data contains invalid UTF-8 sequences, use binary search to calculate the number of written bytes from the number of written characters. Also fix writing incomplete UTF-8 sequences. Also fix handling of memory allocation failures. (cherry picked from commit 3cf83d91a5baf3600dd60f7aaaf4fb6d73c4b8a9) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* [3.12] gh-127182: Fix `io.StringIO.__setstate__` crash when `None` is the ↵Miss Islington (bot)2024-11-251-14/+16
| | | | | | | | | first value (GH-127219) (#127263) gh-127182: Fix `io.StringIO.__setstate__` crash when `None` is the first value (GH-127219) (cherry picked from commit a2ee89968299fc4f0da4b5a4165025b941213ba5) Co-authored-by: sobolevn <mail@sobolevn.me> Co-authored-by: Victor Stinner <vstinner@python.org>
* [3.12] gh-109746: Make _thread.start_new_thread delete state of new thread ↵Serhiy Storchaka2024-11-221-0/+1
| | | | | | | | | | | | on its startup failure (GH-109761) (GH-127173) If Python fails to start newly created thread due to failure of underlying PyThread_start_new_thread() call, its state should be removed from interpreter' thread states list to avoid its double cleanup. (cherry picked from commit ca3ea9ad05c3d876a58463595e5b4228fda06936) Co-authored-by: Radislav Chugunov <52372310+chgnrdv@users.noreply.github.com>
* [3.12] gh-126727: Fix locale.nl_langinfo(locale.ERA) (GH-126730) (GH-127098)Serhiy Storchaka2024-11-211-24/+41
| | | | | It now returns multiple era description segments separated by semicolons. Previously it only returned the first segment on platforms with Glibc. (cherry picked from commit 4803cd0244847f286641c85591fda08b513cea52)
* [3.12] gh-126991: Fix reference leak in loading pickle's opcode BUILD ↵Miss Islington (bot)2024-11-191-0/+1
| | | | | | | | (GH-126990) (GH-127019) If PyObject_SetItem() fails in the `load_build()` function of _pickle.c, no DECREF for the `dict` variable. (cherry picked from commit 29cbcbd73bbfd8c953c0b213fb33682c289934ff) Co-authored-by: Justin Applegate <70449145+Legoclones@users.noreply.github.com>
* [3.12] gh-101955: Fix SystemError in possesive quantifier with alternative ↵Miss Islington (bot)2024-11-181-0/+18
| | | | | | | and group (GH-111362) (GH-126963) (cherry picked from commit f9c5573dedcb2f2e9ae152672ce157987cdea612) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* [3.12] gh-67877: Fix memory leaks in terminated RE matching (GH-126840) ↵Serhiy Storchaka2024-11-184-14/+205
| | | | | | | | | (GH-126961) If SRE(match) function terminates abruptly, either because of a signal or because memory allocation fails, allocated SRE_REPEAT blocks might be never released. (cherry picked from commit 7538e7f5696408fa0aa02fce8a413a7dfac76a04)
* [3.12] gh-126623: Update libexpat to 2.6.4, make future updates easier ↵Miss Islington (bot)2024-11-134-11/+79
| | | | | | | | | | (GH-126792) (GH-126797) gh-126623: Update libexpat to 2.6.4, make future updates easier (GH-126792) Update libexpat to 2.6.4, make future updates easier. (cherry picked from commit 3c9996909402fadc98e6ca2a64e75a71a7427352) Co-authored-by: Seth Michael Larson <seth@python.org>
* [3.12] gh-126595: fix a crash when calling `itertools.count(sys.maxsize)` ↵Bénédikt Tran2024-11-121-0/+3
| | | | | (GH-126617) (#126740) gh-126595: fix a crash when calling `itertools.count(sys.maxsize)` (#126617)
* [3.12] gh-126405: fix use-after-free in ↵Miss Islington (bot)2024-11-121-0/+2
| | | | | | | | `_asyncio.Future.remove_done_callback` (GH-126733) (#126737) gh-126405: fix use-after-free in `_asyncio.Future.remove_done_callback` (GH-126733) (cherry picked from commit 37c57dfad12744608091653fd753a1f770e2479b) Co-authored-by: Kumar Aditya <kumaraditya@python.org>
* [3.12] gh-126461: Fix _Unpickler_ReadFromFile() error handling (GH-126485) ↵Miss Islington (bot)2024-11-061-0/+4
| | | | | | | | | | (#126496) gh-126461: Fix _Unpickler_ReadFromFile() error handling (GH-126485) Handle _Unpickler_SetStringInput() failure. (cherry picked from commit a1c57bcfd2bcbc55ff858407e09c1d8d8cee44e6) Co-authored-by: Victor Stinner <vstinner@python.org>
* [3.12] gh-126455: Disallow _ssl.SSLSocket instantiation (GH-126481) (#126487)Miss Islington (bot)2024-11-061-1/+1
| | | | | | | | | gh-126455: Disallow _ssl.SSLSocket instantiation (GH-126481) Prevent creation of incomplete/invalid _ssl.SSLSocket objects when created directly. (cherry picked from commit b1c4ffc20573befb4db66bbbdd569b9bd13bb127) Co-authored-by: Victor Stinner <vstinner@python.org>
* [3.12] gh-126425: Refactor `_lsprof_Profiler_enable` (GH-126426) (#126443)Miss Islington (bot)2024-11-051-12/+25
| | | | | | | | | gh-126425: Refactor `_lsprof_Profiler_enable` (GH-126426) - Explicit memory management for `None` objects (since we still try to treat immortal objects as regular objects) - Respect possible errors of `sys.monitoring.register_callback` call (cherry picked from commit 75872605aa78dbdfc5c4f025b0f90a7f37ba10c3) Co-authored-by: sobolevn <mail@sobolevn.me>
* [3.12] gh-126303: Fix pickling and copying of os.sched_param objects ↵Serhiy Storchaka2024-11-051-0/+17
| | | | | (GH-126336) (GH-126424) (cherry picked from commit d3840503b0f590ee574fbdf3c96626ff8b3c45f6)
* [3.12] gh-126138: Fix use-after-free in `_asyncio.Task` by evil ↵Miss Islington (bot)2024-11-021-2/+20
| | | | | | | | | `__getattribute__` (GH-126305) (#126325) gh-126138: Fix use-after-free in `_asyncio.Task` by evil `__getattribute__` (GH-126305) (cherry picked from commit f032f6ba8fec6fab35edeec0eb40cd73e9d58928) Co-authored-by: Nico-Posada <102486290+Nico-Posada@users.noreply.github.com> Co-authored-by: Carol Willing <carolcode@willingconsulting.com>
* [3.12] gh-126220: Fix crash on calls to `_lsprof.Profiler` methods with 0 ↵Miss Islington (bot)2024-11-011-0/+24
| | | | | | | | | args (backportable) (GH-126271) (#126311) gh-126220: Fix crash on calls to `_lsprof.Profiler` methods with 0 args (backportable) (GH-126271) (cherry picked from commit 28b148fb32e4548b461137d18d1ab6d366395d36) Co-authored-by: sobolevn <mail@sobolevn.me> Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* [3.12] gh-126080: fix UAF on `task->task_context` in `task_call_step_soon` ↵Miss Islington (bot)2024-10-311-1/+5
| | | | | | | | due to an evil `loop.__getattribute__` (GH-126120) (#126251) gh-126080: fix UAF on `task->task_context` in `task_call_step_soon` due to an evil `loop.__getattribute__` (GH-126120) (cherry picked from commit 0e8665554b2f1334e530fd6de5b3a4e908405419) Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
* [3.12] gh-126083: Fix a reference leak in `asyncio.Task` when reinitializing ↵Miss Islington (bot)2024-10-311-1/+1
| | | | | | | | with new non-`None` context (GH-126103) (#126230) gh-126083: Fix a reference leak in `asyncio.Task` when reinitializing with new non-`None` context (GH-126103) (cherry picked from commit d07dcce6935364cab807e0df931ed09b088ade69) Co-authored-by: Nico-Posada <102486290+Nico-Posada@users.noreply.github.com>
* [3.12] gh-126106: Fix `NULL` possible derefrence in `Modules/_ssl.c` ↵Miss Islington (bot)2024-10-291-3/+3
| | | | | | | | | (GH-126111) (#126117) gh-126106: Fix `NULL` possible derefrence in `Modules/_ssl.c` (GH-126111) (cherry picked from commit a64a1c920660b0c1e4dd5a9573004cd527e15184) Co-authored-by: sobolevn <mail@sobolevn.me> Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
* [3.12] Align functools.reduce() docstring with PEP-257 (GH-126045) (#126114)Miss Islington (bot)2024-10-291-6/+8
| | | | | | | Yak-shave in preparation for Argument Clinic adaption in gh-125999. (cherry picked from commit 9b14083497f50213f908c1359eeaf47c97161347) Co-authored-by: Sergey B Kirpichev <skirpichev@gmail.com>
* [3.12] gh-126035: add missing whitespace to *Py_EnterRecursiveCall() ↵Miss Islington (bot)2024-10-272-3/+3
| | | | | | | messages (GH-126036) (#126059) (cherry picked from commit 19e93e2e269889ecb3c4c039091abff489f247c2) Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
* [3.12] gh-125966: fix use-after-free on `fut->fut_callback0` due to an evil ↵Miss Islington (bot)2024-10-271-1/+6
| | | | | | | | callback's `__eq__` in asyncio (GH-125967) (#126048) gh-125966: fix use-after-free on `fut->fut_callback0` due to an evil callback's `__eq__` in asyncio (GH-125967) (cherry picked from commit ed5059eeb1aa50b481957307db5a34b937497382) Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
* [3.12] gh-125984: fix use-after-free on `fut->fut_{callback,context}0` due ↵Miss Islington (bot)2024-10-271-6/+13
| | | | | | | | to an evil `loop.__getattribute__` (GH-126003) (#126044) gh-125984: fix use-after-free on `fut->fut_{callback,context}0` due to an evil `loop.__getattribute__` (GH-126003) (cherry picked from commit f819d4301d7c75f02be1187fda017f0e7b608816) Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
* [3.12] gh-125969: fix OOB in `future_schedule_callbacks` due to an evil ↵Miss Islington (bot)2024-10-251-17/+12
| | | | | | | | | `call_soon` (GH-125970) (#125992) gh-125969: fix OOB in `future_schedule_callbacks` due to an evil `call_soon` (GH-125970) (cherry picked from commit c5b99f5c2c5347d66b9da362773969c531fb6c85) Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com> Co-authored-by: Andrew Svetlov <andrew.svetlov@gmail.com>
* [3.12] GH-125789: fix `fut._callbacks` to always return a copy of callbacks ↵Miss Islington (bot)2024-10-251-28/+25
| | | | | | | | | | | (GH-125922) (#125977) GH-125789: fix `fut._callbacks` to always return a copy of callbacks (GH-125922) Fix `asyncio.Future._callbacks` to always return a copy of the internal list of callbacks to avoid mutation from user code affecting the internal state. Co-authored-by: Kumar Aditya <kumaraditya@python.org> (cherry picked from commit cae853e3b44cd5cb033b904e163c490dd28bc30a)
* [3.12] gh-124969: Make locale.nl_langinfo(locale.ALT_DIGITS) returning a ↵Miss Islington (bot)2024-10-211-15/+23
| | | | | | | | | | | string again (GH-125774) (GH-125805) This is a follow up of GH-124974. Only Glibc needed a fix. Now the returned value is a string consisting of semicolon-separated symbols on all Posix platforms. (cherry picked from commit dcc4fb2c9068f60353f0c0978948b7681f7745e6) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* [3.12] gh-52551: Fix encoding issues in strftime() (GH-125193) (GH-125657) ↵Miss Islington (bot)2024-10-172-201/+203
| | | | | | | | | | | | | | | | | | | (GH-125661) Fix time.strftime(), the strftime() method and formatting of the datetime classes datetime, date and time. * Characters not encodable in the current locale are now acceptable in the format string. * Surrogate pairs and sequence of surrogatescape-encoded bytes are no longer recombinated. * Embedded null character no longer terminates the format string. This fixes also gh-78662 and gh-124531. (cherry picked from commit 08ccbb9b3f5e20a7a0c4cf9995e172b59fb6067b) (cherry picked from commit ad3eac1963a5f195ef9b2c1dbb5e44fa3cce4c72) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* [3.12] gh-124917: Allow keyword args to os.path.exists/lexists on Windows ↵Jelle Zijlstra2024-10-112-7/+36
| | | | | | | (GH-124918) (#125334) (cherry picked from commit cc2938a18967c9d462ebb18bc09f73e4364aa7d2)
* [3.12] [3.13] gh-124969: Fix locale.nl_langinfo(locale.ALT_DIGITS) ↵Miss Islington (bot)2024-10-111-1/+28
| | | | | | | | | | | | (GH-124974) (GH-125232) (GH-125284) (cherry picked from commit 26a93189e4c3674a9e0acbd7923b1f27ff01419e) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com> Returns a tuple of up to 100 strings for ALT_DIGITS lookup (an empty tuple on most locales). Previously it returned the first item of that tuple or an empty string. (cherry picked from commit 21c04e1a972bd1b6285e0ea41fa107d635bbe43a) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* [3.12] gh-125118: don't copy arbitrary values to _Bool in the struct module ↵Sergey B Kirpichev2024-10-101-3/+2
| | | | | | | | | | | | | | | (GH-125169) (#125265) memcopy'ing arbitrary values to _Bool variable triggers undefined behaviour. Avoid this. We assume that `false` is represented by all zero bytes. Credits to Alex Gaynor. (cherry picked from commit 87d7315ac57250046372b0d9ae4619ba619c8c87) Co-authored-by: Sam Gross <colesbury@gmail.com> Co-authored-by: Victor Stinner <vstinner@python.org> Co-authored-by: Petr Viktorin <encukou@gmail.com>
* [3.12] Tee of tee was not producing n independent iterators (gh-123884) ↵Raymond Hettinger2024-10-081-27/+10
| | | | (gh-125153)
* [3.12] gh-120378: Fix crash caused by integer overflow in `curses` ↵Peter Bierma2024-10-022-27/+87
| | | | | | | | | | | | | (GH-124555) (#124911) This is actually an upstream problem in curses, and has been reported to them already: https://lists.gnu.org/archive/html/bug-ncurses/2024-09/msg00101.html This is a nice workaround in the meantime to prevent the segfault. (cherry picked from commit c2ba931318280796a6dcc33d1a5c5c02ad4d035b) Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
* [3.12] gh-123978: Remove broken time.thread_time() on NetBSD (GH-124116) ↵Serhiy Storchaka2024-10-021-3/+16
| | | | | (GH-124427) (cherry picked from commit e670a113b5e1fcc3ce3bb9b5b4b1f126264ae21b)
* [3.12] gh-116810: fix memory leak in ssl module (GH-123249) (GH-124801)Miss Islington (bot)2024-09-301-63/+13
| | | | | | | | | | | | | gh-116810: fix memory leak in ssl module (GH-123249) Resolve a memory leak introduced in CPython 3.10's :mod:`ssl` when the :attr:`ssl.SSLSocket.session` property was accessed. Speeds up read and write access to said property by no longer unnecessarily cloning session objects via serialization. (cherry picked from commit 7e7223e18f58ec48fb36a68fb75b5c5b7a45042a) Co-authored-by: Jeffrey R. Van Voorst <jeff.vanvoorst@gmail.com> Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com> Co-authored-by: Peter Bierma <zintensitydev@gmail.com> Co-authored-by: Gregory P. Smith <greg@krypto.org> Co-authored-by: Antoine Pitrou <antoine@python.org>
* [3.12] gh-113993: Make interned strings mortal (GH-120520, GH-121364, ↵Petr Viktorin2024-09-2713-56/+68
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | GH-121903, GH-122303) (#123065) This backports several PRs for gh-113993, making interned strings mortal so they can be garbage-collected when no longer needed. * Allow interned strings to be mortal, and fix related issues (GH-120520) * Add an InternalDocs file describing how interning should work and how to use it. * Add internal functions to *explicitly* request what kind of interning is done: - `_PyUnicode_InternMortal` - `_PyUnicode_InternImmortal` - `_PyUnicode_InternStatic` * Switch uses of `PyUnicode_InternInPlace` to those. * Disallow using `_Py_SetImmortal` on strings directly. You should use `_PyUnicode_InternImmortal` instead: - Strings should be interned before immortalization, otherwise you're possibly interning a immortalizing copy. - `_Py_SetImmortal` doesn't handle the `SSTATE_INTERNED_MORTAL` to `SSTATE_INTERNED_IMMORTAL` update, and those flags can't be changed in backports, as they are now part of public API and version-specific ABI. * Add private `_only_immortal` argument for `sys.getunicodeinternedsize`, used in refleak test machinery. Make sure the statically allocated string singletons are unique. This means these sets are now disjoint: - `_Py_ID` - `_Py_STR` (including the empty string) - one-character latin-1 singletons Now, when you intern a singleton, that exact singleton will be interned. * Add a `_Py_LATIN1_CHR` macro, use it instead of `_Py_ID`/`_Py_STR` for one-character latin-1 singletons everywhere (including Clinic). * Intern `_Py_STR` singletons at startup. * Beef up the tests. Cover internal details (marked with `@cpython_only`). * Add lots of assertions * Don't immortalize in PyUnicode_InternInPlace; keep immortalizing in other API (GH-121364) * Switch PyUnicode_InternInPlace to _PyUnicode_InternMortal, clarify docs * Document immortality in some functions that take `const char *` This is PyUnicode_InternFromString; PyDict_SetItemString, PyObject_SetAttrString; PyObject_DelAttrString; PyUnicode_InternFromString; and the PyModule_Add convenience functions. Always point out a non-immortalizing alternative. * Don't immortalize user-provided attr names in _ctypes * Immortalize names in code objects to avoid crash (GH-121903) * Intern latin-1 one-byte strings at startup (GH-122303) There are some 3.12-specific changes, mainly to allow statically allocated strings in deepfreeze. (In 3.13, deepfreeze switched to the general `_Py_ID`/`_Py_STR`.) Co-authored-by: Eric Snow <ericsnowcurrently@gmail.com>
* [3.12] gh-116510: Fix crash during sub-interpreter shutdown (gh-124536)Neil Schemenauer2024-09-271-3/+26
| | | | | Fix a bug that can cause a crash when sub-interpreters use "basic" single-phase extension modules. Shared objects could refer to PyGC_Head nodes that had been freed as part of interpreter shutdown.
* [3.12] gh-124248: Fix crash in struct when processing 0p fields (GH-124251) ↵Miss Islington (bot)2024-09-201-4/+15
| | | | | | | | (#124278) gh-124248: Fix crash in struct when processing 0p fields (GH-124251) (cherry picked from commit 63f196090f90cbfe5f698824655f74dea5cb2b29) Co-authored-by: Brian Schubert <brianm.schubert@gmail.com>
* [3.12] Revert "gh-123974: Fix time.get_clock_info() on NetBSD (GH-123975)" ↵Miss Islington (bot)2024-09-181-5/+1
| | | | | | | | (GH-124115) (GH-124200) This reverts commit b1d6f8a2ee04215c64aa8752cc515b7e98a08d28. (cherry picked from commit 79a74102362996bbd4ff5d410a0d57d43c236da4) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* [3.12] gh-123836: workaround fmod(x, y) bug on Windows (GH-124171) (#124186)Sergey B Kirpichev2024-09-171-0/+9
| | | | | | | | | | | | | | | | | | | Buildbot failure on Windows 10 with MSC v.1916 64 bit (AMD64): FAIL: testFmod (test.test_math.MathTests.testFmod) ---------------------------------------------------------------------- Traceback (most recent call last): File "D:\buildarea\3.x.bolen-windows10\build\Lib\test\test_math.py", line 605, in testFmod self.ftest('fmod(-10, 1)', math.fmod(-10, 1), -0.0) ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\buildarea\3.x.bolen-windows10\build\Lib\test\test_math.py", line 258, in ftest self.fail("{}: {}".format(name, failure)) ~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ AssertionError: fmod(-10, 1): expected -0.0, got 0.0 (zero has wrong sign) Here Windows loose sign of the result; if y is nonzero, the result should have the same sign as x. This amends commit 28aea5d07d. (cherry picked from commit f4dd4402108cc005d45acd4ca83c8530c36a93ca)
* [3.12] gh-121023: Improve `_xxtestfuzz/README.rst` (GH-121024) (#124141)Miss Islington (bot)2024-09-161-3/+5
| | | | | | | gh-121023: Improve `_xxtestfuzz/README.rst` (GH-121024) (cherry picked from commit a9c2bc16349c2be3005f97249f3ae9699988f218) Co-authored-by: sobolevn <mail@sobolevn.me> Co-authored-by: Illia Volochii <illia.volochii@gmail.com>
* [3.12] gh-123974: Fix time.get_clock_info() on NetBSD (GH-123975) (#124073)Miss Islington (bot)2024-09-131-1/+5
| | | | | | | | gh-123974: Fix time.get_clock_info() on NetBSD (GH-123975) Fix OSError for thread_time clock on NetBSD by setting default resolution. (cherry picked from commit b1d6f8a2ee04215c64aa8752cc515b7e98a08d28) Co-authored-by: Furkan Onder <furkanonder@protonmail.com>
* [3.12] gh-123431: Harmonize extension code checks in pickle (GH-123434) ↵Miss Islington (bot)2024-09-061-16/+8
| | | | | | | | | | | (#123460) This checks are redundant in normal circumstances and can only work if the extension registry was intentionally broken. (cherry picked from commit 0c3ea3023878f5ad5ca4680d5510da1fe208cbfa) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* [3.12] gh-123213: Fixed xml.etree.ElementTree.Element.extend and assignment ↵Miss Islington (bot)2024-09-061-10/+2
| | | | | | to no longer hide exceptions (GH-123214) (#123258) Co-authored-by: Bar Harel <bharel@barharel.com>
* [3.12] gh-111495: Add tests for PyNumber C API (GH-111996) (#123376)Sergey B Kirpichev2024-09-051-0/+161
| | | (cherry picked from commit 2f20f5a9bc7dafdb3c2ae723da90eca1727a95f7)
* [3.12] gh-111495: Add tests for PyTuple C API (GH-118757) (#123379)Sergey B Kirpichev2024-09-051-1/+227
| | | | | | | (cherry picked from commit dbc1752d4107532d312c78263212e807a3674eb1) Co-authored-by: kalyanr <kalyan.ben10@live.com> Co-authored-by: Serhiy Storchaka <storchaka@gmail.com> Co-authored-by: Victor Stinner <vstinner@python.org>
* [3.12] gh-123678: Upgrade libexpat 2.6.3 (GH-123689) (GH-123708)Miss Islington (bot)2024-09-043-15/+35
| | | | | | | | gh-123678: Upgrade libexpat 2.6.3 (GH-123689) Upgrade libexpat 2.6.3 (cherry picked from commit 40bdb0deee746e51c71c56329df21e5172fd8aa0) Co-authored-by: Seth Michael Larson <seth@python.org>
* [3.12] gh-112182: Replace StopIteration with RuntimeError for future ↵Miss Islington (bot)2024-08-151-5/+20
| | | | | | | | | | | (GH-113220) (GH-123033) When an `StopIteration` raises into `asyncio.Future`, this will cause a thread to hang. This commit address this by not raising an exception and silently transforming the `StopIteration` with a `RuntimeError`, which the caller can reconstruct from `fut.exception().__cause__` (cherry picked from commit 4826d52338396758b2d6790a498c2a06eec19a86) Co-authored-by: Jamie Phan <jamie@ordinarylab.dev>