summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* bpo-40517: Implement syntax highlighting support for ASDL (GH-19967)Batuhan Taskaya2020-05-073-2/+54
|
* bpo-40548: Always run GitHub action, even on doc PRs (GH-19981)Victor Stinner2020-05-071-10/+3
| | | | | Always run GitHub action jobs, even on documentation-only pull requests. So it will be possible to make a GitHub action job, like the Windows (64-bit) job, mandatory.
* bpo-38787: Update structures.rst docs (PEP 573) (GH-19980)Hai Shi2020-05-072-12/+8
|
* bpo-32604: [_xxsubinterpreters] Propagate exceptions. (GH-19768)Eric Snow2020-05-072-123/+1317
| | | | | | | | | (Note: PEP 554 is not accepted and the implementation in the code base is a private one for use in the test suite.) If code running in a subinterpreter raises an uncaught exception then the "run" call in the calling interpreter fails. A RunFailedError is raised there that summarizes the original exception as a string. The actual exception type, __cause__, __context__, state, etc. are all discarded. This turned out to be functionally insufficient in practice. There is a more helpful solution (and PEP 554 has been updated appropriately). This change adds the exception propagation behavior described in PEP 554 to the _xxsubinterpreters module. With this change a copy of the original exception is set to __cause__ on the RunFailedError. For now we are using "pickle", which preserves the exception's state. We also preserve the original __cause__, __context__, and __traceback__ (since "pickle" does not preserve those). https://bugs.python.org/issue32604
* bpo-40545: Export _PyErr_GetTopmostException() function (GH-19978)Victor Stinner2020-05-072-1/+4
| | | | | | | Declare _PyErr_GetTopmostException() with PyAPI_FUNC() to properly export the function in the C API. The function remains private ("_Py") prefix. Co-Authored-By: Julien Danjou <julien@danjou.info>
* bpo-38787: C API for module state access from extension methods (PEP 573) ↵Petr Viktorin2020-05-0719-51/+797
| | | | | | | | | (GH-19936) Module C state is now accessible from C-defined heap type methods (PEP 573). Patch by Marcel Plch and Petr Viktorin. Co-authored-by: Marcel Plch <mplch@redhat.com> Co-authored-by: Victor Stinner <vstinner@python.org>
* bpo-40334: Error message for invalid default args in function call (GH-19973)Lysandros Nikolaou2020-05-074-159/+222
| | | | | When parsing something like `f(g()=2)`, where the name of a default arg is not a NAME, but an arbitrary expression, a specialised error message is emitted.
* bpo-40334: Fix error location upon parsing an invalid string literal (GH-19962)Lysandros Nikolaou2020-05-076-28/+34
| | | | | | | When parsing a string with an invalid escape, the old parser used to point to the beginning of the invalid string. This commit changes the new parser to match that behaviour, since it's currently pointing to the end of the string (or to be more precise, to the beginning of the next token).
* bpo-1635741: Port errno module to multiphase initialization (GH-19923)Dong-hee Na2020-05-072-310/+336
|
* bpo-40397: Refactor typing._GenericAlias (GH-19719)Serhiy Storchaka2020-05-071-191/+198
| | | | | | Make the design more object-oriented. Split _GenericAlias on two almost independent classes: for special generic aliases like List and for parametrized generic aliases like List[int]. Add specialized subclasses for Callable, Callable[...], Tuple and Union[...].
* bpo-40334: Generate comments in the parser code to improve debugging (GH-19966)Pablo Galindo2020-05-062-1074/+1088
|
* bpo-40334: Allow trailing comma in parenthesised context managers (GH-19964)Pablo Galindo2020-05-063-7/+79
|
* Fix typo in sqlite3 documentation (GH-19965)Naglis2020-05-061-1/+1
| | | *first* is repeated twice.
* bpo-40334: Add type to the assignment rule in the grammar file (GH-19963)Lysandros Nikolaou2020-05-062-5/+5
|
* bpo-40521: Disable list free list in subinterpreters (GH-19959)Victor Stinner2020-05-061-1/+8
| | | | | | When Python is built with experimental isolated interpreters, disable the list free list. Temporary workaround until this cache is made per-interpreter.
* bpo-40533: Disable GC in subinterpreters (GH-19961)Victor Stinner2020-05-061-0/+8
| | | | | | | When Python is built with experimental isolated interpreters, a garbage collection now does nothing in an isolated interpreter. Temporary workaround until subinterpreters stop sharing Python objects.
* bpo-40521: Disable method cache in subinterpreters (GH-19960)Victor Stinner2020-05-061-3/+19
| | | | | | When Python is built with experimental isolated interpreters, disable the type method cache. Temporary workaround until the cache is made per-interpreter.
* bpo-40528: Improve and clear several aspects of the ASDL definition code for ↵Batuhan Taskaya2020-05-066-101/+75
| | | | the AST (GH-19952)
* bpo-40527: Fix command line argument parsing (GH-19955)Victor Stinner2020-05-063-7/+29
|
* Revert "bpo-40517: Implement syntax highlighting support for ASDL (#19928)" ↵Raymond Hettinger2020-05-063-54/+2
| | | | | (#19950) This reverts commit d60040ba226bd2e3b6f58d074015aa2499dc1cb8.
* bpo-40517: Implement syntax highlighting support for ASDL (#19928)Batuhan Taskaya2020-05-063-2/+54
|
* bpo-40480 "fnmatch" exponential execution time (GH-19908)Tim Peters2020-05-063-7/+71
| | | | | bpo-40480: create different regexps in the presence of multiple `*` patterns to prevent fnmatch() from taking exponential time.
* bpo-40523: Add pass-throughs for hash() and reversed() to weakref.proxy ↵Pablo Galindo2020-05-053-1/+40
| | | | objects (GH-19946)
* bpo-40504: Allow weakrefs to lru_cache objects (GH-19938)Dennis Sweeney2020-05-053-1/+38
|
* bpo-40355: Improve error messages in ast.literal_eval with malformed Dict ↵Curtis Bucher2020-05-053-4/+15
| | | | | nodes (GH-19868) Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
* bpo-40513: _xxsubinterpreters.run_string() releases the GIL (GH-19944)Victor Stinner2020-05-051-0/+15
| | | | In the experimental isolated subinterpreters build mode, _xxsubinterpreters.run_string() now releases the GIL.
* bpo-40513: Per-interpreter GIL (GH-19943)Victor Stinner2020-05-056-5/+82
| | | | | | | | In the experimental isolated subinterpreters build mode, the GIL is now per-interpreter. Move gil from _PyRuntimeState.ceval to PyInterpreterState.ceval. new_interpreter() always get the config from the main interpreter.
* bpo-40513: new_interpreter() init GIL earlier (GH-19942)Victor Stinner2020-05-051-4/+4
| | | Fix also code to handle init_interp_main() failure.
* bpo-40522: _PyThreadState_Swap() sets autoTSSkey (GH-19939)Victor Stinner2020-05-053-2/+48
| | | | | | | | | | | | | | | | | | In the experimental isolated subinterpreters build mode, _PyThreadState_GET() gets the autoTSSkey variable and _PyThreadState_Swap() sets the autoTSSkey variable. * Add _PyThreadState_GetTSS() * _PyRuntimeState_GetThreadState() and _PyThreadState_GET() return _PyThreadState_GetTSS() * PyEval_SaveThread() sets the autoTSSkey variable to current Python thread state rather than NULL. * eval_frame_handle_pending() doesn't check that _PyThreadState_Swap() result is NULL. * _PyThreadState_Swap() gets the current Python thread state with _PyThreadState_GetTSS() rather than _PyRuntimeGILState_GetThreadState(). * PyGILState_Ensure() no longer checks _PyEval_ThreadsInitialized() since it cannot access the current interpreter.
* bpo-40521: Disable free lists in subinterpreters (GH-19937)Victor Stinner2020-05-053-80/+162
| | | | | | | | | When Python is built with experimental isolated interpreters, disable tuple, dict and free free lists. Temporary workaround until these caches are made per-interpreter. Add frame_alloc() and frame_get_builtins() subfunctions to simplify _PyFrame_New_NoTrack().
* bpo-40458: Increase reserved stack space to prevent overflow crash on ↵Steve Dower2020-05-053-0/+3
| | | | Windows (GH-19845)
* bpo-40521: Disable Unicode caches in isolated subinterpreters (GH-19933)Victor Stinner2020-05-052-15/+79
| | | | | | | When Python is built in the experimental isolated subinterpreters mode, disable Unicode singletons and Unicode interned strings since they are shared by all interpreters. Temporary workaround until these caches are made per-interpreter.
* Revert "bpo-40513: Per-interpreter signals pending (GH-19924)" (GH-19932)Victor Stinner2020-05-054-32/+42
| | | This reverts commit 4e01946cafca0cf49f796c3118e0d65237bcad69.
* bpo-40520: Remove redundant comment in pydebug.h (GH-19931)Hai Shi2020-05-051-2/+0
| | | Automerge-Triggered-By: @corona10
* bpo-29587: _PyErr_ChainExceptions() checks exception (GH-19902)Victor Stinner2020-05-054-24/+45
| | | | | | | | | | | | | | | | | | | _PyErr_ChainExceptions() now ensures that the first parameter is an exception type, as done by _PyErr_SetObject(). * The following function now check PyExceptionInstance_Check() in an assertion using a new _PyBaseExceptionObject_cast() helper function: * PyException_GetTraceback(), PyException_SetTraceback() * PyException_GetCause(), PyException_SetCause() * PyException_GetContext(), PyException_SetContext() * PyExceptionClass_Name() now checks PyExceptionClass_Check() with an assertion. * Remove XXX comment and add gi_exc_state variable to _gen_throw(). * Remove comment from test_generators
* bpo-40513: Per-interpreter recursion_limit (GH-19929)Victor Stinner2020-05-054-22/+28
| | | | | | | | | | | Move recursion_limit member from _PyRuntimeState.ceval to PyInterpreterState.ceval. * Py_SetRecursionLimit() now only sets _Py_CheckRecursionLimit of ceval.c if the current Python thread is part of the main interpreter. * Inline _Py_MakeEndRecCheck() into _Py_LeaveRecursiveCall(). * Convert _Py_RecursionLimitLowerWaterMark() macro into a static inline function.
* bpo-32117: Updated Simpsons names in docs (GH-19737)Javier Buzzi2020-05-051-2/+2
| | | | | `sally` is not a Simpsons character Automerge-Triggered-By: @gvanrossum
* bpo-40514: Add --with-experimental-isolated-subinterpreters (GH-19926)Victor Stinner2020-05-055-0/+60
| | | | | | | Add --with-experimental-isolated-subinterpreters build option to configure: better isolate subinterpreters, experimental build mode. When used, force the usage of the libc malloc() memory allocator, since pymalloc relies on the unique global interpreter lock (GIL).
* bpo-40513: Per-interpreter gil_drop_request (GH-19927)Victor Stinner2020-05-054-47/+45
| | | | Move gil_drop_request member from _PyRuntimeState.ceval to PyInterpreterState.ceval.
* bpo-40513: Per-interpreter signals pending (GH-19924)Victor Stinner2020-05-053-7/+7
| | | | Move signals_pending from _PyRuntime.ceval to PyInterpreterState.ceval.
* bpo-40286: Put methods in correct sections. Add security notice to use ↵Raymond Hettinger2020-05-051-10/+15
| | | | secrets for session tokens. (GH-19870)
* bpo-40459: Fix NameError in platform.py (GH-19855)Dennis Sweeney2020-05-052-3/+4
|
* bpo-1635741: Port syslog module to multiphase initialization (GH-19907)Dong-hee Na2020-05-052-59/+64
|
* bpo-40499: Mention that asyncio.wait() needs a non-empty aws set (GH-19900)Joel Rosdahl2020-05-043-0/+4
| | | | | A similar formulation was added in bpo-21596 (db74d982d43d98040e38665d843cbc8de4a082b1) but was lost in bpo-33649 (3faaa8857a42a36383bb18425444e597fc876797).
* bpo-39470: Indicate that ``os.makedirs`` is equivalent to ``Path.mkdir`` ↵Joannah Nanjekye2020-05-041-0/+1
| | | | | | | | | | | | (GH-18216) * Indicate os.makedirs is equivalent to Path.mkdir * 📜🤖 Added by blurb_it. * ignore news feed Co-authored-by: nanjekyejoannah <joannah.nanjekye@ibm.com> Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
* bpo-40360: Add a What's New entry for lib2to3 pending deprecation (GH-19898)Miro Hrončok2020-05-041-0/+10
|
* bpo-40275: test.support imports lazily locale import (GH-19761)Hai Shi2020-05-041-1/+1
|
* bpo-40489: Add test case for dict contain use after free (GH-19906)Dong-hee Na2020-05-041-0/+13
|
* bpo-40135: Fix multiprocessing test_shared_memory_across_processes() (GH-19892)Hai Shi2020-05-041-1/+3
| | | | Don't define shared memory block's name in test_shared_memory_across_processes(): use SharedMemory(create=True) instead.
* bpo-40455: Remove gcc10 warning about x_digits (#19852)Dong-hee Na2020-05-041-4/+3
| | | | | | | * bpo-40455: Remove gcc10 warning about x_digits * bpo-40455: nit * bpo-40455: fix logic error