summaryrefslogtreecommitdiffstats
path: root/Misc
Commit message (Collapse)AuthorAgeFilesLines
* bpo-37028: asyncio REPL; activated via 'python -m asyncio'. (GH-13472)Yury Selivanov2019-05-271-0/+1
| | | | | This makes it easy to play with asyncio APIs with simply using async/await in the REPL.
* bpo-36772 Allow lru_cache to be used as decorator without making a function ↵Raymond Hettinger2019-05-261-0/+2
| | | | call (GH-13048)
* bpo-37053: handle strings like u"bar" correctly in Tools/parser/unparse.py ↵Chih-Hsuan Yen2019-05-261-0/+1
| | | | | | | | | | | | (GH-13583) Constant.kind is added in https://bugs.python.org/issue36280. Current possible values for Constant.kind are "u" or None. For r'bar' and b'bar', Constant.kind value is None, so there's no need for special handling. https://bugs.python.org/issue37053
* bpo-36785: PEP 574 implementation (GH-7076)Antoine Pitrou2019-05-261-0/+1
|
* bpo-28866: No type cache for types with specialized mro, invalidation is ↵Julien Palard2019-05-261-0/+2
| | | | | | | | | | | | | | | | | | hard. (#13157) * No type cache for types with specialized mro, invalidation is hard. * FIX: Don't disable method cache custom types that do not implement mro(). * fixing implem. * Avoid storing error flags, also decref. * news entry * Clear as soon as we're getting an error. * FIX: Reference leak.
* bpo-37049: PEP 589: Add TypedDict to typing module (GH-13573)Ivan Levkivskyi2019-05-261-0/+1
| | | | The implementation is straightforward and essentially is just copied from `typing_extensions`.
* bpo-37046: PEP 586: Add Literal to typing module (#13572)Ivan Levkivskyi2019-05-261-0/+1
| | | | The implementation is straightforward and essentially is just copied from `typing_extensions`.
* bpo-37045: PEP 591: Add final qualifiers to typing module (GH-13571)Ivan Levkivskyi2019-05-261-0/+1
| | | | The implementation is straightforward, it just mimics `ClassVar` (since the latter is also a name/access qualifier, not really a type). Also it is essentially copied from `typing_extensions`.
* bpo-37017: PyObject_CallMethodObjArgs uses LOAD_METHOD optimization (GH-13516)Michael J. Sullivan2019-05-261-0/+4
| | | | | | | | | Update PyObject_CallMethodObjArgs and _PyObject_CallMethodIdObjArgs to use _PyObject_GetMethod to avoid creating a bound method object in many cases. On a microbenchmark of PyObject_CallMethodObjArgs calling a method on an interpreted Python class, this optimization resulted in a 1.7x speedup.
* bpo-37038: Make idlelib.run runnable; add test clause (GH-13560)Terry Jan Reedy2019-05-251-0/+1
|
* bpo-34632: Add importlib.metadata (GH-12547)Jason R. Coombs2019-05-241-0/+1
| | | Add importlib.metadata module as forward port of the standalone importlib_metadata.
* bpo-37032: Add CodeType.replace() method (GH-13542)Victor Stinner2019-05-241-0/+1
|
* bpo-35907: Fix typo in the NEWS entry (GH-13559)Victor Stinner2019-05-241-1/+1
|
* bpo-36969: Make PDB args command display positional only arguments (GH-13459)Rémi Lapeyre2019-05-241-0/+2
|
* bpo-35907: Clarify the NEWS entry (GH-13523)Victor Stinner2019-05-241-2/+3
|
* bpo-8138: Initialize wsgiref's SimpleServer as single-threaded (GH-12977)Berker Peksag2019-05-241-0/+2
|
* bpo-21536: On Cygwin, C extensions must be linked with libpython (GH-13549)E. M. Bray2019-05-241-1/+2
| | | | | | | | | | It is also possible to link against a library or executable with a statically linked libpython, but not both with the same DLL. In fact building a statically linked python is currently broken on Cygwin for other (related) reasons. The same problem applies to other POSIX-like layers over Windows (MinGW, MSYS) but Python's build system does not seem to attempt to support those platforms at the moment.
* bpo-36045: builtins.help() now prefixes `async` for async functions (GH-12010)Dan Rose2019-05-241-0/+1
| | | | | | Previously, it was hard to tell whether a function should be awaited. It was also incorrect (per PEP 484) to put this in the type hint for coroutine functions. Added this info to the output of builtins.help and pydoc. https://bugs.python.org/issue36045
* bpo-20285: Improve help docs for object (GH-4759)Cheryl Sabella2019-05-241-0/+3
|
* bpo-23395: Fix PyErr_SetInterrupt if the SIGINT signal is ignored or not ↵Matěj Cepl2019-05-232-1/+3
| | | | | handled (GH-7778) ``_thread.interrupt_main()`` now avoids setting the Python error status if the ``SIGINT`` signal is ignored or not handled by Python.
* bpo-36842: Implement PEP 578 (GH-12613)Steve Dower2019-05-231-0/+1
| | | Adds sys.audit, sys.addaudithook, io.open_code, and associated C APIs.
* bpo-37008: make mock_open handle able to honor next() (GH-13492)Damien Nadé2019-05-231-0/+2
| | | | | | | | I've reported the issue on https://bugs.python.org/issue37008 and now I'm trying to bring a solution to this minor issue. I think it could be trivially backported to 3.7 branch. https://bugs.python.org/issue37008
* bpo-33164: update blake2 implementation (GH-6286)David Carlier2019-05-231-0/+1
|
* bpo-36721: Add --embed option to python-config (GH-13500)Victor Stinner2019-05-235-6/+50
| | | | | | | | | | | | | | | | | | | | | To embed Python into an application, a new --embed option must be passed to "python3-config --libs --embed" to get "-lpython3.8" (link the application to libpython). To support both 3.8 and older, try "python3-config --libs --embed" first and fallback to "python3-config --libs" (without --embed) if the previous command fails. Add a pkg-config "python-3.8-embed" module to embed Python into an application: "pkg-config python-3.8-embed --libs" includes "-lpython3.8". To support both 3.8 and older, try "pkg-config python-X.Y-embed --libs" first and fallback to "pkg-config python-X.Y --libs" (without --embed) if the previous command fails (replace "X.Y" with the Python version). On the other hand, "pkg-config python3.8 --libs" no longer contains "-lpython3.8". C extensions must not be linked to libpython (except on Android, case handled by the script); this change is backward incompatible on purpose. "make install" now also installs "python-3.8-embed.pc".
* bpo-27737: Allow whitespace only headers encoding (#13478)Batuhan Taşkaya2019-05-231-0/+2
|
* bpo-36829: PyErr_WriteUnraisable() normalizes exception (GH-13507)Victor Stinner2019-05-221-0/+4
| | | | | | PyErr_WriteUnraisable() now creates a traceback object if there is no current traceback. Moreover, call PyErr_NormalizeException() and PyException_SetTraceback() to normalize the exception value. Ignore silently any error.
* bpo-36829: Add test.support.catch_unraisable_exception() (GH-13490)Victor Stinner2019-05-221-0/+2
| | | | | | * Copy test_exceptions.test_unraisable() to test_sys.UnraisableHookTest(). * Use catch_unraisable_exception() in test_coroutines, test_exceptions, test_generators.
* bpo-24882: Let ThreadPoolExecutor reuse idle threads before creating new ↵Sean2019-05-221-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | thread (#6375) * Fixes issue 24882 * Add news file entry for change. * Change test_concurrent_futures.ThreadPoolShutdownTest Adjust the shutdown test so that, after submitting three jobs to the executor, the test checks for less than three threads, instead of looking for exactly three threads. If idle threads are being recycled properly, then we should have less than three threads. * Switched idle count to semaphor, Updated tests As suggested by reviewer tomMoral, swapped lock-protected counter with a semaphore to track the number of unused threads. Adjusted test_threads_terminate to wait for completiton of the previous future before submitting a new one (and checking the number of threads used). Also added a new test to confirm the thread pool can be saturated. * Updates tests as requested by pitrou. * Correct minor whitespace error. * Make test_saturation faster
* bpo-33110: Catch errors raised when running add_done_callback on already ↵Sam Martin2019-05-221-0/+1
| | | | | | completed futures (GH-13141) Wrap the callback call within the `add_done_callback` function within concurrent.futures, in order to behave in an identical manner to callbacks added to a running future are triggered once it has completed.
* bpo-36878: Only allow text after `# type: ignore` if first character ASCII ↵Michael J. Sullivan2019-05-221-0/+2
| | | | | | | | | | | (GH-13504) This disallows things like `# type: ignoreé`, which seems wrong. Also switch to using Py_ISALNUM for the alnum check, for consistency with other code (and maybe correctness re: locale issues?). https://bugs.python.org/issue36878
* bpo-35907, CVE-2019-9948: urllib rejects local_file:// scheme (GH-13474)Victor Stinner2019-05-221-0/+2
| | | | | | | CVE-2019-9948: Avoid file reading as disallowing the unnecessary URL scheme in URLopener().open() and URLopener().retrieve() of urllib.request. Co-Authored-By: SH <push0ebp@gmail.com>
* bpo-36084: Add native thread ID (TID) to threading.Thread (GH-13463)Jake Tesler2019-05-221-0/+1
| | | | Add native thread ID (TID) to threading.Thread objects (supported platforms: Windows, FreeBSD, Linux, macOS).
* bpo-33482: fix codecs.StreamRecoder.writelines (GH-6779)Jelle Zijlstra2019-05-221-0/+1
| | | | | | A very simple fix. I found this while writing typeshed stubs for StreamRecoder. https://bugs.python.org/issue33482
* bpo-36878: Track extra text added to 'type: ignore' in the AST (GH-13479)Michael J. Sullivan2019-05-222-0/+4
| | | | | GH-13238 made extra text after a # type: ignore accepted by the parser. This finishes the job and actually plumbs the extra text through the parser and makes it available in the AST.
* bpo-36972: Add SupportsIndex (GH-13448)Paul Dagnelie2019-05-222-0/+2
| | | | In order to support typing checks calling hex(), oct() and bin() on user-defined classes, a SupportIndex protocol is required. The ability to check these at runtime would be good to add for completeness sake. This is pretty much just a copy of SupportsInt with the names tweaked.
* bpo-31862: Port binascii to PEP 489 multiphase initialization (GH-4108)Marcel Plch2019-05-221-0/+2
|
* bpo-36907: fix refcount bug in _PyStack_UnpackDict() (GH-13381)Jeroen Demeyer2019-05-221-0/+2
|
* bpo-36829: Add sys.unraisablehook() (GH-13187)Victor Stinner2019-05-221-0/+5
| | | | | | | | | | | | | | | | | | | Add new sys.unraisablehook() function which can be overridden to control how "unraisable exceptions" are handled. It is called when an exception has occurred but there is no way for Python to handle it. For example, when a destructor raises an exception or during garbage collection (gc.collect()). Changes: * Add an internal UnraisableHookArgs type used to pass arguments to sys.unraisablehook. * Add _PyErr_WriteUnraisableDefaultHook(). * The default hook now ignores exception on writing the traceback. * test_sys now uses unittest.main() to automatically discover tests: remove test_main(). * Add _PyErr_Init(). * Fix PyErr_WriteUnraisable(): hold a strong reference to sys.stderr while using it
* bpo-25652: Fix __rmod__ of UserString (GH-13326)Batuhan Taşkaya2019-05-211-0/+1
| | | | | | The ``__rmod__`` method of ``collections.UserString`` class had a bug that made it unusable. https://bugs.python.org/issue25652
* bpo-34616: Add PyCF_ALLOW_TOP_LEVEL_AWAIT to allow top-level await (GH-13148)Matthias Bussonnier2019-05-211-0/+1
| | | Co-Authored-By: Yury Selivanov <yury@magic.io>
* bpo-23378: Add an extend action to argparse (GH-13305)Batuhan Taşkaya2019-05-211-0/+1
| | | | | | Add an extend action to argparse https://bugs.python.org/issue23378
* bpo-36035: fix Path.rglob for broken links (GH-11988)Jörg Stucke2019-05-211-0/+1
| | | Links creating an infinite symlink loop would raise an exception.
* bpo-36929: Modify io/re tests to allow for missing mod name (#13392)Max Bernstein2019-05-211-0/+1
| | | | | | | | | | | | | | | | | | * bpo-36929: Modify io/re tests to allow for missing mod name For a vanishingly small number of internal types, CPython sets the tp_name slot to mod_name.type_name, either in the PyTypeObject or the PyType_Spec. There are a few minor places where this surfaces: * Custom repr functions for those types (some of which ignore the tp_name in favor of using a string literal, such as _io.TextIOWrapper) * Pickling error messages The test suite only tests the former. This commit modifies the test suite to allow Python implementations to omit the module prefix. https://bugs.python.org/issue36929
* bpo-36648: fix mmap issue for VxWorks (GH-12394)Lihua Zhao2019-05-211-0/+1
| | | | | The mmap module set MAP_SHARED flag when map anonymous memory, however VxWorks only support MAP_PRIVATE when map anonymous memory, this commit clear MAP_SHARED and set MAP_PRIVATE.
* bpo-31904: Add posix module support for VxWorks (GH-12118)pxinwr2019-05-211-0/+1
|
* Revert "bpo-36084: Add native thread ID to threading.Thread objects ↵Victor Stinner2019-05-211-1/+0
| | | | | (GH-11993)" (GH-13458) This reverts commit 4959c33d2555b89b494c678d99be81a65ee864b0.
* bpo-36965: Fix includes in main.c on Windows with non-MSC compilers (GH-13421)Erik Janssens2019-05-211-0/+1
| | | | Include windows.h rather than crtdbg.h to get STATUS_CONTROL_C_EXIT constant. Moreover, include windows.h on Windows, not only when MSC is used.
* bpo-36969: Make PDB args command display keyword only arguments (GH-13452)Rémi Lapeyre2019-05-201-0/+2
|
* bpo-36952: Remove the bufsize parameter in fileinput.input(). (GH-13400)Matthias Bussonnier2019-05-201-0/+4
| | | | | This parameter is marked as deprecated since 3.6 and for removal in 3.8. It already had no effects.
* bpo-23896: Add a grammar where exec isn't a stmt (#13272)Batuhan Taşkaya2019-05-202-0/+3
| | | https://bugs.python.org/issue23896