summaryrefslogtreecommitdiffstats
path: root/Modules
Commit message (Collapse)AuthorAgeFilesLines
...
* Revert "bpo-40521: Remove freelist from collections.deque() (GH-21073)" ↵Raymond Hettinger2021-03-251-2/+21
| | | | | | | | (GH-24944) This reverts commit 32f2eda85957365d208f499b730d30b7eb419741. It can be re-applied if the subinterpreter PEP is approved. Otherwise, the commit degraded performance with no offsetting benefit.
* Fix typo in fuzzer.c (GH-25013)Ikko Ashimine2021-03-241-2/+2
|
* bpo-43244: Remove ast.h, asdl.h, Python-ast.h headers (GH-24933)Victor Stinner2021-03-231-2/+0
| | | | | | | | | | | | | | | | These functions were undocumented and excluded from the limited C API. Most names defined by these header files were not prefixed by "Py" and so could create names conflicts. For example, Python-ast.h defined a "Yield" macro which was conflict with the "Yield" name used by the Windows <winbase.h> header. Use the Python ast module instead. * Move Include/asdl.h to Include/internal/pycore_asdl.h. * Move Include/Python-ast.h to Include/internal/pycore_ast.h. * Remove ast.h header file. * pycore_symtable.h no longer includes Python-ast.h.
* bpo-43422: Revert _decimal C API addition (GH-24960)Antoine Pitrou2021-03-215-529/+19
| | | | | | | | | Stefan Krah requested the reversal of these (unreleased) changes, quoting him: > The capsule API does not meet my testing standards, since I've focused on the upstream mpdecimal in the last couple of months. > Additionally, I'd like to refine the API, perhaps together with the Arrow community. Automerge-Triggered-By: GH:pitrou
* bpo-43577: Fix deadlock with SSLContext._msg_callback and sni_callback ↵Christian Heimes2021-03-212-0/+6
| | | | | | | | | | | | (GH-24957) OpenSSL copies the internal message callback from SSL_CTX->msg_callback to SSL->msg_callback. SSL_set_SSL_CTX() does not update SSL->msg_callback to use the callback value of the new context. PySSL_set_context() now resets the callback and _PySSL_msg_callback() resets thread state in error path. Signed-off-by: Christian Heimes <christian@python.org>
* bpo-43571: Add IPPROTO_MPTCP macro (GH-24946)Rui Cunha2021-03-201-0/+3
| | | Add IPPROTO_MPTCP constant when defined in the system headers.
* bpo-43244: Remove symtable.h header file (GH-24910)Victor Stinner2021-03-191-3/+2
| | | | | | | | | | | | | | | | | | Rename Include/symtable.h to to Include/internal/pycore_symtable.h, don't export symbols anymore (replace PyAPI_FUNC and PyAPI_DATA with extern) and rename functions: * PyST_GetScope() to _PyST_GetScope() * PySymtable_BuildObject() to _PySymtable_Build() * PySymtable_Free() to _PySymtable_Free() Remove PySymtable_Build(), Py_SymtableString() and Py_SymtableStringObject() functions. The Py_SymtableString() function was part the stable ABI by mistake but it could not be used, since the symtable.h header file was excluded from the limited C API. The Python symtable module remains available and is unchanged.
* bpo-39342: Expose X509_V_FLAG_ALLOW_PROXY_CERTS in ssl module (GH-18011)Chris Burr2021-03-181-0/+2
| | | Exposes the `X509_V_FLAG_ALLOW_PROXY_CERTS` constant as `ssl.VERIFY_ALLOW_PROXY_CERTS` to allow for proxy certificate validation as described in: https://www.openssl.org/docs/man1.1.1/man7/proxy-certificates.html
* bpo-41361: Optimized argument parsing for deque_rotate (GH-24796)Dennis Sweeney2021-03-161-1/+12
|
* bpo-43439: Wrapt the tuple in the audit events for the gc module (GH-24836)Pablo Galindo2021-03-141-2/+2
|
* bpo-43444: Move sqlite3 MODULE_NAME from setup.py to module.h (GH-24801)Erlend Egeberg Aasland2021-03-133-4/+3
|
* bpo-43356: Allow passing a signal number to interrupt_main() (GH-24755)Antoine Pitrou2021-03-112-37/+68
| | | | Also introduce a new C API ``PyErr_SetInterruptEx(int signum)``.
* bpo-43439: Add audit hooks for gc functions (GH-24794)Pablo Galindo2021-03-101-0/+11
|
* bpo-43406: Fix possible race condition where ``PyErr_CheckSignals`` tries to ↵Antoine Pitrou2021-03-051-1/+25
| | | | | | execute a non-Python signal handler (GH-24756) We can receive signals (at the C level, in `trip_signal()` in signalmodule.c) while `signal.signal` is being called to modify the corresponding handler. Later when `PyErr_CheckSignals()` is called to handle the given signal, the handler may be a non-callable object and would raise a cryptic asynchronous exception.
* bpo-43369: sqlite3_column_{text,blob} failures now raise MemoryError (GH-24723)Erlend Egeberg Aasland2021-03-041-10/+23
|
* bpo-43394: Fix -Wstrict-prototypes warnings (GH-24737)Brandt Bucher2021-03-042-6/+6
|
* bpo-43368: Fix fetching empty bytes in sqlite3 (GH-24706)Mariusz Felisiak2021-03-031-6/+2
| | | Regression introduced in 47feb1feb28631b6647699b7633109aa85340966.
* missing multiply symbol in the documentation (GH-24686)Alperen Serkan Aksöz2021-03-031-1/+1
|
* bpo-39523: Use do-while loop pysqlite_cursor_executescript() (GH-18305)Alex Henrie2021-03-021-3/+2
|
* bpo-29753: fix merging packed bitfields in ctypes struct/union (GH-19850)Filipe Laíns2021-02-281-8/+27
| | | | | | | | | | From the commit message: > When the structure is packed we should always expand when needed, > otherwise we will add some padding between the fields. This patch makes > sure we always merge bitfields together. It also changes the field merging > algorithm so that it handles bitfields correctly. Automerge-Triggered-By: GH:jaraco
* bpo-43251: sqlite3_column_name() failures now raise MemoryError (GH-24609)Erlend Egeberg Aasland2021-02-281-24/+29
|
* bpo-43335: Update macro to check gcc version (GH-24662)Dong-hee Na2021-02-281-2/+2
|
* bpo-43294: Remove unused variables in pysqlite_connection_*() (GH-24658)Erlend Egeberg Aasland2021-02-261-6/+4
|
* bpo-43314: Remove SQLITE_OPEN_URI ifdef (GH-24637)Erlend Egeberg Aasland2021-02-261-11/+0
| | | | | SQLite 3.7.15 is required as by GH-24106. SQLITE_OPEN_URI was added in SQLite 3.7.7.
* bpo-43290: Remove workaround from pysqlite_step() (GH-24638)Erlend Egeberg Aasland2021-02-251-9/+3
| | | | | | | | | From the SQLite 3.5.3 changelog: sqlite3_step() returns SQLITE_MISUSE instead of crashing when called with a NULL parameter. The workaround no longer needed because we no longer support SQLite releases older than 3.7.15.
* bpo-43260: io: Prevent large data remains in textio buffer. (GH-24592)Inada Naoki2021-02-211-3/+17
| | | | | | | | When very large data remains in TextIOWrapper, flush() may fail forever. So prevent that data larger than chunk_size is remained in TextIOWrapper internal buffer. Co-Authored-By: Eryk Sun
* bpo-43269: Remove redundant extern keywords (GH-24605)Erlend Egeberg Aasland2021-02-216-6/+12
|
* bpo-43269: Clean up sqlite3 file scope (GH-24578)Erlend Egeberg Aasland2021-02-216-19/+37
|
* bpo-43268: local_clear() uses _PyInterpreterState_GET() (GH-24583)Victor Stinner2021-02-191-15/+14
| | | Cleanup also the code.
* bpo-43268: Pass interp rather than tstate to internal functions (GH-24580)Victor Stinner2021-02-192-19/+19
| | | | | | | | | | | | | | | Pass the current interpreter (interp) rather than the current Python thread state (tstate) to internal functions which only use the interpreter. Modified functions: * _PyXXX_Fini() and _PyXXX_ClearFreeList() functions * _PyEval_SignalAsyncExc(), make_pending_calls() * _PySys_GetObject(), sys_set_object(), sys_set_object_id(), sys_set_object_str() * should_audit(), set_flags_from_config(), make_flags() * _PyAtExit_Call() * init_stdio_encoding() * etc.
* bpo-43268: Replace _PyThreadState_GET() with _PyInterpreterState_GET() ↵Victor Stinner2021-02-191-1/+2
| | | | | | | | | | | (GH-24576) Replace _PyThreadState_GET() with _PyInterpreterState_GET() in functions which only need the current interpreter, but don't need the current Python thread state. Replace also _PyThreadState_UncheckedGet() with _PyThreadState_GET() in faulthandler.c, since _PyThreadState_UncheckedGet() is just an alias to _PyThreadState_GET() in practice.
* bpo-43258: Make sqlite3 callback functions static (GH-24574)Erlend Egeberg Aasland2021-02-191-2/+4
|
* bpo-43258: Don't allocate sqlite3 aggregate context for empty queries (GH-24569)Erlend Egeberg Aasland2021-02-191-2/+6
|
* bpo-43249: Improve scoping in _pysqlite_fetch_one_row() (GH-24565)Erlend Egeberg Aasland2021-02-181-10/+9
|
* bpo-43249: sqlite3_column_bytes() must follow sqlite_column_blob() (GH-24562)Erlend Egeberg Aasland2021-02-181-4/+14
|
* bpo-42960: Add resource.RLIMIT_KQUEUES constant from FreeBSD (GH-24251)David CARLIER2021-02-181-0/+4
|
* bpo-35134, Include: Move pytime.h to cpython/pytime.h (GH-23988)Nicholas Sim2021-02-161-1/+0
| | | | This change is backward compatible since C extension modules must not include "pytime.h" directly, but only include "Python.h".
* bpo-42819, readline: Disable bracketed paste (GH-24108)Dustin Rodrigues2021-02-151-0/+23
|
* bpo-43210: Fix byteswap comment in sha512.module.c (GH-24518)Erlend Egeberg Aasland2021-02-141-1/+1
|
* bpo-43172: readline now passes its tests when built against libedit (GH-24499)Gregory P. Smith2021-02-122-12/+36
| | | | | | | bpo-43172: readline now passes its tests when built against libedit. Existing irreconcilable API differences remain in readline.get_begidx and readline.get_endidx behavior based on libreadline vs libedit use. A note about that has been documented.
* bpo-43204: Fix LibTomCrypt URL in md5module.c and sha*module.c comments ↵Erlend Egeberg Aasland2021-02-124-4/+4
| | | | | (GH-24507) Automerge-Triggered-By: GH:tiran
* bpo-40956: Fix segfault when Connection.backup is called without target ↵Erlend Egeberg Aasland2021-02-102-21/+12
| | | | (GH-24503)
* bpo-13501: allow choosing between readline and libedit (GH-24189)Roland Hieber2021-02-091-3/+7
| | | | | | | | | | | | | | | | | | | | | | | In contrast to macOS, libedit is available as its own include file and library on Linux systems to prevent file name clashes. So if both libraries are available on the system, readline is currently chosen by default; and if only libedit is available, it is not found at all. This patch adds a way to link against libedit by adding the following arguments to configure: --with-readline link against libreadline (the default) --with-readline=editline link against libeditline --with-readline=no disable building the readline module --without-readline (same) The runtime detection of libedit vs. readline was already done in commit 7105319ada2e66365902 (2019-12-04, serge-sans-paille: "bpo-38634: Allow non-apple build to cope with libedit (GH-16986)"). Fixes: GH-12076 ("bpo-13501 Build or disable readline with Editline") Fixes: bpo-13501 ("Make libedit support more generic; port readline / libedit to FreeBSD") Co-authored-by: Enji Cooper (ngie-eign) Co-authored-by: Martin Panter (vadmium) Co-authored-by: Robert Marshall (kellinm)
* bpo-43132: Fix incorrect handling of PyObject_RichCompareBool() in _zoneinfo ↵Zackery Spytz2021-02-051-6/+17
| | | | | | | (GH-24450) PyObject_RichCompareBool() returns -1 on error, but this case is not handled by the find_in_strong_cache() function. Any exception raised by PyObject_RichCompareBool() should be propagated.
* bpo-43106: Add os.O_EVTONLY/O_FSYNC/O_SYMLINK/O_NOFOLLOW_ANY (GH-24428)Dong-hee Na2021-02-031-1/+12
|
* bpo-43108: Fix a reference leak in the curses module (GH-24420)Pablo Galindo2021-02-021-1/+3
|
* bpo-42834: Fix _json internal caches for subinterpreters (GH-24121)Ken Jin2021-02-011-38/+39
| | | | Make internal caches of the _json extension module compatible with subinterpreters.
* bpo-41604: Don't decrement the reference count of the previous user_ptr when ↵Anonymous Maarten2021-01-311-1/+3
| | | | set_panel_usertpr fails (GH-21933)
* bpo-43083: Fix error handling in _sqlite3 (GH-24395)Serhiy Storchaka2021-01-312-7/+19
|
* bpo-42323: Fix math.nextafter() on AIX (GH-24381)Victor Stinner2021-01-291-2/+2
| | | math_nextafter_impl() must return a Python object, not a C double.