summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* bpo-44258: support PEP 515 for Fraction's initialization from string (GH-26422)Sergey B Kirpichev2021-06-075-11/+85
| | | | | | | | | | | | | | | | | | | * bpo-44258: support PEP 515 for Fraction's initialization from string * regexps's version * A different regexps version, which doesn't suffer from catastrophic backtracking * revert denom -> den * strip "_" from the decimal str, add few tests * drop redundant tests * Add versionchanged & whatsnew entry * Amend Fraction constructor docs * Change .. versionchanged:...
* bpo-37449: ensurepip uses importlib.resources.files() traversable APIs (#22659)wim glenn2021-06-073-5/+5
| | | | | | | | | | | | | * `ensurepip` now uses `importlib.resources.files()` traversable APIs * Update Lib/ensurepip/__init__.py Co-authored-by: Jason R. Coombs <jaraco@jaraco.com> * Update Misc/NEWS.d/next/Library/2020-10-11-20-23-48.bpo-37449.f-t3V6.rst Co-authored-by: Jason R. Coombs <jaraco@jaraco.com> Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
* bpo-44322: Document more SyntaxError details. (GH-26562)Terry Jan Reedy2021-06-072-2/+11
| | | | | | 1. SyntaxError args have a tuple of other attributes. 2. Attributes are adjusted for errors in f-string field expressions. 3. Compile() can raise SyntaxErrors.
* bpo-44326: Remove unused members from pysqlite_Statement (GH-26564)Erlend Egeberg Aasland2021-06-062-16/+2
| | | | | * Remove unused db member of pysqlite_Statement * Remove unused sql method from statement object
* bpo-44327: Remove unused members from pysqlite_Connection (GH-26565)Erlend Egeberg Aasland2021-06-062-8/+0
| | | | | * Remove timeout_started * Remove timeout member
* Update bisect docstrings (GH-26548)hrchu2021-06-062-11/+11
|
* bpo-44320: Fix markup for W3C C14N test suite (GH-26556)NAKAMURA Osamu2021-06-061-1/+1
|
* bpo-44304: Ensure the sqlite3 destructor callback is always called with the ↵Pablo Galindo2021-06-052-0/+7
| | | | GIL held (GH-26551)
* bpo-44304: Fix crash in the sqlite3 module when the GC clears Statement ↵Pablo Galindo2021-06-053-7/+23
| | | | objects (GH-26545)
* bpo-38323: Skip SubprocessMultiLoopWatcherTest as they can hang the test ↵Pablo Galindo2021-06-041-0/+2
| | | | suite (GH-26542)
* Update nonstandard variable names (GH-26540)Raymond Hettinger2021-06-041-5/+5
|
* bpo-44279: revert 'exceptions are raised' back to 'exceptions occur' (GH-26492)Irit Katriel2021-06-041-1/+1
|
* Align comment for better readability. (GH-26192)Kazantcev Andrey2021-06-041-5/+5
|
* bpo-44315: Remove unused connection argument from pysqlite_step() (GH-26535)Erlend Egeberg Aasland2021-06-044-7/+8
|
* bpo-43853: Handle sqlite3_value_text() errors (GH-25422)Erlend Egeberg Aasland2021-06-043-13/+21
|
* bpo-44041: Add test for sqlite3 column count (GH-25907)Erlend Egeberg Aasland2021-06-041-0/+11
|
* bpo-43693: Revert commits 2c1e2583fdc4db6b43d163239ea42b0e8394171f and ↵Pablo Galindo2021-06-0423-6026/+5705
| | | | | | | | | | | | | b2bf2bc1ece673d387341e06c8d3c2bc6e259747 (GH-26530) * Revert "bpo-43693: Compute deref offsets in compiler (gh-25152)" This reverts commit b2bf2bc1ece673d387341e06c8d3c2bc6e259747. * Revert "bpo-43693: Add new internal code objects fields: co_fastlocalnames and co_fastlocalkinds. (gh-26388)" This reverts commit 2c1e2583fdc4db6b43d163239ea42b0e8394171f. These two commits are breaking the refleak buildbots.
* bpo-44048: Fix two hashlib test cases under FIPS mode (GH-26470)stratakis2021-06-041-2/+10
| | | | | test_disallow_instantiation and test_readonly_types try to test all the available digests, however under FIPS mode, while the algorithms are available, trying to use them will fail with a ValueError.
* Removing myself from ssl code ownership (GH-26529)Christian Heimes2021-06-041-3/+3
| | | | | I'm taking a break. Signed-off-by: Christian Heimes <christian@python.org>
* bpo-43693: Compute deref offsets in compiler (gh-25152)Mark Shannon2021-06-0411-209/+222
| | | | | | Merges locals and cells into a single array. Saves a pointer in the interpreter and means that we don't need the LOAD_CLOSURE opcode any more https://bugs.python.org/issue43693
* bpo-32280: Store _PyRuntime in a named section (GH-4802)Max Bélanger2021-06-031-2/+28
| | | | | This commit stores the _PyRuntime structure in a section of the same name. This allows a debugging or crash reporting tool to quickly locate this structure at runtime without requiring the symbol table. Co-authored-by: Pablo Galindo <pablogsal@gmail.com>
* bpo-44305: Improve syntax error for try blocks without except or finally ↵Pablo Galindo2021-06-035-269/+383
| | | | (GH-26523)
* bpo-44042: Optimize sqlite3 begin transaction (GH-25908)Erlend Egeberg Aasland2021-06-033-46/+38
|
* bpo-43921: Cleanup test_ssl.test_wrong_cert_tls13() (GH-26520)Victor Stinner2021-06-031-12/+5
| | | Don't catch OSError, and check the SSLError message.
* bpo-11105: Do not crash when compiling recursive ASTs (GH-20594)Batuhan Taskaya2021-06-034-4/+840
| | | | | | | When compiling an AST object with a direct / indirect reference cycles, on the conversion phase because of exceeding amount of calls, a segfault was raised. This patch adds recursion guards to places for preventing user inputs to not to crash AST but instead raise a RecursionError.
* bpo-42862: Use functools.lru_cache iso. _sqlite.Cache in sqlite3 module ↵Erlend Egeberg Aasland2021-06-0312-438/+77
| | | | | (GH-24203) Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
* bpo-39573: Py_TYPE becomes a static inline function (GH-26493)Victor Stinner2021-06-035-9/+52
| | | | | Convert the Py_TYPE() and Py_SIZE() macros to static inline functions. The Py_SET_TYPE() and Py_SET_SIZE() functions must now be used to set an object type and size.
* bpo-42213: Remove redundant cyclic GC hack in sqlite3 (GH-26517)Erlend Egeberg Aasland2021-06-035-39/+37
| | | | | | | | | | The sqlite3 module now fully implements the GC protocol, so there's no need for this workaround anymore. - Add and use managed resource helper for connections using TESTFN - Sort test imports - Split open-tests into their own test case Automerge-Triggered-By: GH:vstinner
* bpo-43693: Add new internal code objects fields: co_fastlocalnames and ↵Eric Snow2021-06-0321-5659/+5967
| | | | | | | | | | | | | | | | | co_fastlocalkinds. (gh-26388) A number of places in the code base (notably ceval.c and frameobject.c) rely on mapping variable names to indices in the frame "locals plus" array (AKA fast locals), and thus opargs. Currently the compiler indirectly encodes that information on the code object as the tuples co_varnames, co_cellvars, and co_freevars. At runtime the dependent code must calculate the proper mapping from those, which isn't ideal and impacts performance-sensitive sections. This is something we can easily address in the compiler instead. This change addresses the situation by replacing internal use of co_varnames, etc. with a single combined tuple of names in locals-plus order, along with a minimal array mapping each to its kind (local vs. cell vs. free). These two new PyCodeObject fields, co_fastlocalnames and co_fastllocalkinds, are not exposed to Python code for now, but co_varnames, etc. are still available with the same values as before (though computed lazily). Aside from the (mild) performance impact, there are a number of other benefits: * there's now a clear, direct relationship between locals-plus and variables * code that relies on the locals-plus-to-name mapping is simpler * marshaled code objects are smaller and serialize/de-serialize faster Also note that we can take this approach further by expanding the possible values in co_fastlocalkinds to include specific argument types (e.g. positional-only, kwargs). Doing so would allow further speed-ups in _PyEval_MakeFrameVector(), which is where args get unpacked into the locals-plus array. It would also allow us to shrink marshaled code objects even further. https://bugs.python.org/issue43693
* bpo-43921: Fix test_ssl.test_wrong_cert_tls13() on Windows (GH-26502)Victor Stinner2021-06-032-14/+9
| | | | Fix test_ssl.test_wrong_cert_tls13(): use suppress_ragged_eofs=False, since read() can raise ssl.SSLEOFError on Windows.
* bpo-42213: Check connection in sqlite3.Connection.__enter__ (GH-26512)Erlend Egeberg Aasland2021-06-032-16/+35
| | | | | | | | | Try to harden connection close: - add tests that exercise stuff against a closed database - add wrapper for sqlite3_close_v2() - check connection on __enter__ - explicitly free pending statements before close() - sqlite3_close_v2() always returns SQLITE_OK
* bpo-44298: Fix line numbers for early exits in with statements. (GH-26513)Mark Shannon2021-06-034-2971/+3027
|
* bpo-39560: Document PyUnicode_FromKindAndData() kind transformation (GH-23848)Zackery Spytz2021-06-031-0/+6
|
* bpo-43858: Add logging.getLevelNamesMapping() (GH-26459)andrei kulakov2021-06-034-1/+21
| | | Added a function that returns a copy of a dict of logging levels.
* Add bpo-42914 to What's New (GH-25124)Wm. Keith van der Meulen2021-06-032-0/+4
| | | | | BPO-42914 was not added to the What's New in #24864. This includes it in the "Improved Modules" section. Automerge-Triggered-By: GH:gpshead
* bpo-44022: Improve the regression test. (GH-26503)Gregory P. Smith2021-06-031-1/+6
| | | | It wasn't actually detecting the regression due to the assertion being too lenient.
* bpo-44282: Fix occasional test_incremental_editing failures on buildbots ↵Tal Einat2021-06-023-43/+49
| | | | | (GH-26491) Signed-off-by: Tal Einat <532281+taleinat@users.noreply.github.com>
* bpo-43921: Fix test_ssl.test_pha_required_nocert() (GH-26489)Victor Stinner2021-06-022-2/+11
| | | | Fix test_pha_required_nocert() of test_ssl: catch two more EOF cases (when the recv() method returns an empty string).
* build(deps): bump actions/cache from 2.1.5 to 2.1.6 (GH-26476)dependabot[bot]2021-06-021-2/+2
| | | | | | | | | Bumps [actions/cache](https://github.com/actions/cache) from 2.1.5 to 2.1.6. - [Release notes](https://github.com/actions/cache/releases) - [Commits](https://github.com/actions/cache/compare/v2.1.5...v2.1.6) Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Typo fix in asyncio-eventloop.rst (GH-26482)Zac Bentley2021-06-021-1/+1
|
* bpo-44285: getpath.c: Assert that env_file is NULL during an error check ↵stratakis2021-06-021-0/+1
| | | | | (GH-26486) This was flagged by a static analyzer, but the logic of why this is NULL on error is hard to follow for humans as well.
* bpo-44165: pysqlite_statement_create now returns a Py object, not an int ↵Erlend Egeberg Aasland2021-06-021-1/+1
| | | | | (GH-26484) GH-26206 was broken by GH-26475.
* bpo-17792: more accurate error message for unbound variable access ↵Irit Katriel2021-06-022-3/+4
| | | | exceptions (GH-24976)
* Remove duplicate address in CommonTestMixin_v4.test_leading_zeros() (GH-26326)Mariusz Felisiak2021-06-021-1/+0
|
* bpo-44165: Optimise sqlite3 statement preparation by passing string size ↵Erlend Egeberg Aasland2021-06-023-7/+25
| | | | (GH-26206)
* bpo-44263: Py_TPFLAGS_HAVE_GC requires tp_traverse (GH-26463)Victor Stinner2021-06-013-3/+40
| | | | | The PyType_Ready() function now raises an error if a type is defined with the Py_TPFLAGS_HAVE_GC flag set but has no traverse function (PyTypeObject.tp_traverse).
* Fix typo in block comment in Include/internal/pycore_condvar.h (GH-26457)Rishi2021-06-011-1/+1
|
* bpo-44279: [doc] reword contextlib.suppress documentation (GH-26428)MapleCCC2021-06-011-2/+3
|
* bpo-44273: Improve syntax error message for assigning to "..." (GH-26477)Serhiy Storchaka2021-06-012-2/+2
| | | Use "ellipsis" instead of "Ellipsis" in syntax error messages to eliminate confusion with built-in variable Ellipsis.
* bpo-42972: Track sqlite3 statement objects (GH-26475)Erlend Egeberg Aasland2021-06-014-48/+40
| | | | | | | | | | | Allocate and track statement objects in pysqlite_statement_create. By allocating and tracking creation of statement object in pysqlite_statement_create(), the caller does not need to worry about GC syncronization, and eliminates the possibility of getting a badly created object. All related fault handling is moved to pysqlite_statement_create(). Co-authored-by: Victor Stinner <vstinner@python.org>