summaryrefslogtreecommitdiffstats
path: root/Modules
Commit message (Collapse)AuthorAgeFilesLines
* gh-90501: Add PyErr_GetHandledException and PyErr_SetHandledException (GH-30531)Irit Katriel2022-04-151-0/+11
|
* gh-69093: improve sqlite3.Connection.blobopen() error handling (GH-91571)Erlend Egeberg Aasland2022-04-151-1/+5
| | | | | Unless sqlite3_blob_open() returns SQLITE_MISUSE, the error code and message are available on the connection object. This means we have to handle SQLITE_MISUSE error messages explicitly.
* gh-91404: Use computed gotos and reduce indirection in re (#91495)Brandt Bucher2022-04-152-343/+452
|
* gh-69093: Don't allow instantiation of sqlite3.Blob objects (GH-91570)Erlend Egeberg Aasland2022-04-151-1/+1
|
* gh-69093: Expose sqlite3.Blob as a class (GH-91550)Jelle Zijlstra2022-04-151-0/+1
| | | | I noticed this was missing while writing typeshed stubs. It's useful to expose it for use in annotations and for exploration.
* Remove usage of _Py_IDENTIFIER from unicodedata module. (GH-91532)Dong-hee Na2022-04-151-14/+8
|
* gh-69093: Support basic incremental I/O to blobs in `sqlite3` (GH-30680)Erlend Egeberg Aasland2022-04-158-6/+739
| | | | | | | Authored-by: Aviv Palivoda <palaviv@gmail.com> Co-authored-by: Erlend E. Aasland <erlend.aasland@innova.no> Co-authored-by: palaviv <palaviv@gmail.com> Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com> Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* gh-91353: Fix void return type handling in ctypes (GH-32246)Hood Chatham2022-04-142-2/+7
|
* gh-91156: Fix `encoding="locale"` in UTF-8 mode (GH-70056)Inada Naoki2022-04-144-15/+23
|
* gh-90699: Remove usage of _Py_IDENTIFIER from bisect module. (GH-91522)Dong-hee Na2022-04-141-5/+2
|
* bpo-47152: Automatically regenerate sre_constants.h (GH-91439)Serhiy Storchaka2022-04-121-2/+2
| | | | | | | * Move the code for generating Modules/_sre/sre_constants.h from Lib/re/_constants.py into a separate script Tools/scripts/generate_sre_constants.py. * Add target `regen-sre` in the makefile. * Make target `regen-all` depending on `regen-sre`.
* gh-79097: Add support for aggregate window functions in sqlite3 (GH-20903)Erlend Egeberg Aasland2022-04-124-8/+230
|
* bpo-45995: add "z" format specifer to coerce negative 0 to zero (GH-30049)John Belmonte2022-04-111-7/+119
| | | | | | | | Add "z" format specifier to coerce negative 0 to zero. See https://github.com/python/cpython/issues/90153 (originally https://bugs.python.org/issue45995) for discussion. This covers `str.format()` and f-strings. Old-style string interpolation is not supported. Co-authored-by: Mark Dickinson <dickinsm@gmail.com>
* bpo-47000: Add `locale.getencoding()` (GH-32068)Inada Naoki2022-04-093-13/+19
|
* Add new PyFrame_GetLasti C-API function (GH-32413)Mark Shannon2022-04-081-0/+16
|
* bpo-47177: Replace `f_lasti` with `prev_instr` (GH-32208)Brandt Bucher2022-04-071-1/+1
|
* Deprecate audioop (GH-32392)Brett Cannon2022-04-071-0/+7
|
* Remove micro-optimization that no longer shows a benefit. (GH-32397)Raymond Hettinger2022-04-071-21/+1
|
* Change parameter name from *x* for reals to *n* for integers. (GH-32377)Raymond Hettinger2022-04-062-6/+6
|
* bpo-26579: Add object.__getstate__(). (GH-2821)Serhiy Storchaka2022-04-062-35/+10
| | | | | | | Copying and pickling instances of subclasses of builtin types bytearray, set, frozenset, collections.OrderedDict, collections.deque, weakref.WeakSet, and datetime.tzinfo now copies and pickles instance attributes implemented as slots.
* bpo-47211: Remove function re.template() and flag re.TEMPLATE (GH-32300)Serhiy Storchaka2022-04-062-2/+0
| | | They were undocumented and never working.
* bpo-41930: Add support for SQLite serialise/deserialise API (GH-26728)Erlend Egeberg Aasland2022-04-052-1/+280
| | | | Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com> Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
* bpo-46890: Fix setting of sys._base_executable with framework builds on ↵Ronald Oussoren2022-04-052-2/+19
| | | | | | | | | macOS (GH-31958) The side effect of this bug was that venv environments directly used the main interpreter instead of the intermediate stub executable, which can cause problems when a script uses system APIs that require the use of an application bundle.
* bpo-47208: Allow vendors to override CTYPES_MAX_ARGCOUNT (GH-32297)Christian Heimes2022-04-042-1/+4
|
* bpo-47152: Move sources of the _sre module into a subdirectory (GH-32290)Serhiy Storchaka2022-04-046-5/+5
|
* bpo-47000: Make `io.text_encoding()` respects UTF-8 mode (GH-32003)Inada Naoki2022-04-042-7/+16
| | | Co-authored-by: Eric Snow <ericsnowcurrently@gmail.com>
* bpo-47176: Interrupt handling for wasm32-emscripten builds without pthreads ↵Hood Chatham2022-04-031-0/+2
| | | | | | (GH-32209) Co-authored-by: Christian Heimes <christian@python.org> Co-authored-by: Brett Cannon <brett@python.org>
* bpo-23689: re module, fix memory leak when a match is terminated by a signal ↵Ma Lin2022-04-035-46/+83
| | | | or memory allocation failure (GH-32283)
* bpo-47196: Fix one more PyInit function signature (GH-32280)Hood Chatham2022-04-031-1/+1
| | | | | I missed one PyInit function in #32244. Automerge-Triggered-By: GH:tiran
* bpo-47152: Convert the re module into a package (GH-32177)Serhiy Storchaka2022-04-021-2/+2
| | | The sre_* modules are now deprecated.
* bpo-47196: Fix function pointer cast in test_imp (GH-32244)Hood Chatham2022-04-021-24/+24
| | | | | | | The function PyInit_imp_dummy is declared as void f(PyObject* spec) but called as void f(void). On wasm targets without the call trampolines this causes a fatal error. Automerge-Triggered-By: GH:tiran
* bpo-46023: makesetup: skip all duplicate modules (GH-32234)Christian Heimes2022-04-011-6/+12
|
* bpo-47167: Allow overriding a future compliance check in asyncio.Task (GH-32197)Andrew Svetlov2022-04-012-8/+102
|
* bpo-47151: Fallback to fork when vfork fails in subprocess. (GH-32186)Gregory P. Smith2022-03-311-0/+6
| | | bpo-47151: Fallback to fork when vfork fails in subprocess. An OS kernel can specifically decide to disallow vfork() in a process. No need for that to prevent us from launching subprocesses.
* bpo-40421: Add missing getters for frame object attributes to C-API. (GH-32114)Mark Shannon2022-03-311-0/+44
|
* bpo-45847: Port _tkinter to PY_STDLIB_MOD (GH-31698)Erlend Egeberg Aasland2022-03-311-3/+2
| | | | | - Remove ``--with-tclk-*`` options from `configure` - Use pkg-config to detect `_tkinter` dependencies (Tcl/Tk, X11) - Manual override via environment variables `TCLTK_CFLAGS` and `TCLTK_LIBS`
* bpo-47164: Add _PyASCIIObject_CAST() macro (GH-32191)Victor Stinner2022-03-311-1/+1
| | | | | | | | | | | | Add macros to cast objects to PyASCIIObject*, PyCompactUnicodeObject* and PyUnicodeObject*: _PyASCIIObject_CAST(), _PyCompactUnicodeObject_CAST() and _PyUnicodeObject_CAST(). Using these new macros make the code more readable and check their argument with: assert(PyUnicode_Check(op)). Remove redundant assert(PyUnicode_Check(op)) in macros using directly or indirectly these new CAST macros. Replacing existing casts with these macros.
* asyncio.Task: rename internal nested variable to don't hide another ↵Andrew Svetlov2022-03-291-13/+13
| | | | declaration from outer scope (GH-32181)
* bpo-35859: Fix a few long-standing bugs in re engine (GH-12427)Ma Lin2022-03-292-19/+76
| | | | | | | | In rare cases, capturing group could get wrong result. Regular expression engines in Perl and Java have similar bugs. The new behavior now matches the behavior of more modern RE engines: in the regex module and in PHP, Ruby and Node.js.
* bpo-47070: Add _PyBytes_Repeat() (GH-31999)Pieter Eendebak2022-03-281-31/+18
| | | Use it where appropriate: the repeat functions of `array.array`, `bytes`, `bytearray`, and `str`.
* bpo-44493: Add missing terminated NUL in sockaddr_un's length (GH-26866)ty2022-03-271-1/+6
| | | | | | | Add missing terminated NUL in sockaddr_un's length - Linux: https://man7.org/linux/man-pages/man7/unix.7.html - *BSD: SUN_LEN
* bpo-47098: Replace Keccak Code Package with tiny_sha3 (GH-32060)Christian Heimes2022-03-2622-5632/+335
|
* bpo-47095: Use libb2 to provide blake2 implementation (GH-32059)Christian Heimes2022-03-2612-17786/+27
|
* bpo-47101: list only activated algorithms in hashlib.algorithms_available ↵Christian Heimes2022-03-231-1/+12
| | | | (GH-32076)
* bpo-46829: Deprecate passing a message into Future.cancel() and ↵Andrew Svetlov2022-03-231-0/+20
| | | | | Task.cancel() (GH-31840) After a long deliberation we ended up feeling that the message argument for Future.cancel(), added in 3.9, was a bad idea, so we're deprecating it in 3.11 and plan to remove it in 3.13.
* bpo-42885: Optimize search for regular expressions starting with "\A" or "^" ↵Serhiy Storchaka2022-03-221-0/+7
| | | | | | | (GH-32021) Affected functions are re.search(), re.split(), re.findall(), re.finditer() and re.sub().
* bpo-47045: Remove `f_state` field (GH-31963)Mark Shannon2022-03-221-4/+1
| | | | | * Remove the f_state field from _PyInterpreterFrame * Make ownership of the frame explicit, replacing the is_generator field with an owner field.
* bpo-433030: Add support of atomic grouping in regular expressions (GH-31982)Serhiy Storchaka2022-03-213-16/+237
| | | | | | | | * Atomic grouping: (?>...). * Possessive quantifiers: x++, x*+, x?+, x{m,n}+. Equivalent to (?>x+), (?>x*), (?>x?), (?>x{m,n}). Co-authored-by: Jeffrey C. Jacobs <timehorse@users.sourceforge.net>
* bpo-23691: Protect the re.finditer() iterator from re-entering (GH-32012)Serhiy Storchaka2022-03-212-4/+41
|
* bpo-38256: Fix binascii.crc32() when inputs are 4+GiB (GH-32000)Gregory P. Smith2022-03-203-31/+63
| | | | | | | When compiled with `USE_ZLIB_CRC32` defined (`configure` sets this on POSIX systems), `binascii.crc32(...)` failed to compute the correct value when the input data was >= 4GiB. Because the zlib crc32 API is limited to a 32-bit length. This lines it up with the `zlib.crc32(...)` implementation that doesn't have that flaw. **Performance:** This also adopts the same GIL releasing for larger inputs logic that `zlib.crc32` has, and causes the Windows build to always use zlib's crc32 instead of our slow C code as zlib is a required build dependency on Windows.