summaryrefslogtreecommitdiffstats
path: root/Lib
Commit message (Collapse)AuthorAgeFilesLines
* bpo-32323: urllib.parse.urlsplit() must not lowercase() IPv6 scope value (#4867)Коренберг Марк2017-12-212-4/+15
|
* bpo-15873: Implement [date][time].fromisoformat (#4699)Paul Ganssle2017-12-212-31/+586
| | | Closes bpo-15873.
* bpo-15216: io: TextIOWrapper.reconfigure() accepts encoding, errors and ↵INADA Naoki2017-12-212-20/+173
| | | | newline (GH-2343)
* bpo-29970: Make ssh_handshake_timeout None by default (#4939)Andrew Svetlov2017-12-209-16/+100
| | | | | * Make ssh_handshake_timeout None by default. * Raise ValueError if ssl_handshake_timeout is used without ssl. * Raise ValueError if ssl_handshake_timeout is not positive.
* bpo-32379: Faster MRO computation for single inheritance (#4932)Antoine Pitrou2017-12-201-0/+6
| | | | * bpo-32379: Faster MRO computation for single inheritance
* bpo-31901: atexit callbacks should be run at subinterpreter shutdown (#4611)Marcel Plch2017-12-201-0/+19
| | | | Change atexit behavior and PEP-489 multiphase init support.
* bpo-29970: Add timeout for SSL handshake in asyncioNeil Aspinall2017-12-199-80/+173
| | | | 10 seconds by default.
* bpo-26439 Fix ctypes.util.find_library failure on AIX (#4507)Michael Felt2017-12-193-0/+364
| | | | | Implement find_library() support in ctypes/util for AIX. Add some AIX specific tests.
* bpo-29711: Fix stop_serving in proactor loop kill all listening servers (#431)Julien Duponchelle2017-12-192-5/+18
|
* bpo-32355: Optimize asyncio.gather() (#4913)Yury Selivanov2017-12-192-47/+67
|
* bpo-32357: Optimize asyncio.iscoroutine() for non-native coroutines (#4915)Yury Selivanov2017-12-192-5/+59
|
* bpo-27456: Simplify sock type checks (#4922)Yury Selivanov2017-12-193-29/+9
| | | | Recent sock.type fix (see bug 32331) makes sock.type checks simpler in asyncio.
* Improve test coverage (#4924)Andrew Svetlov2017-12-191-0/+1
|
* bpo-32331: Fix socket.type when SOCK_NONBLOCK is available (#4877)Yury Selivanov2017-12-193-18/+39
|
* bpo-32356: idempotent pause_/resume_reading; new is_reading method. (#4914)Yury Selivanov2017-12-187-24/+71
|
* bpo-32369: test_subprocess: Fix pass_fds check in test_close_fds() (#4920)izbyshev2017-12-181-2/+2
| | | | | | | | | | The last part of test_close_fds() doesn't match its own comment. The following assertion always holds because fds_to_keep and open_fds are disjoint by construction. self.assertFalse(remaining_fds & fds_to_keep & open_fds, "Some fds not in pass_fds were left open") Fix the code to match the message in the assertion.
* bpo-19764: Implemented support for subprocess.Popen(close_fds=True) on ↵Segev Finer2017-12-182-24/+107
| | | | | | | | | | | | | | | | | Windows (#1218) Even though Python marks any handles it opens as non-inheritable there is still a race when using `subprocess.Popen` since creating a process with redirected stdio requires temporarily creating inheritable handles. By implementing support for `subprocess.Popen(close_fds=True)` we fix this race. In order to implement this we use PROC_THREAD_ATTRIBUTE_HANDLE_LIST which is available since Windows Vista. Which allows to pass an explicit list of handles to inherit when creating a process. This commit also adds `STARTUPINFO.lpAttributeList["handle_list"]` which can be used to control PROC_THREAD_ATTRIBUTE_HANDLE_LIST directly.
* bpo-30050: Allow disabling full buffer warnings in signal.set_wakeup_fd (#4792)Nathaniel J. Smith2017-12-181-0/+92
|
* bpo-32348: Optimize asyncio.Future schedule/add/remove callback. (#4907)Yury Selivanov2017-12-182-27/+175
|
* bpo-32351: Use fastpath in asyncio.sleep if delay<0 (#4908)Andrew Svetlov2017-12-171-1/+1
| | | | | | * Use fastpath in asyncio.sleep if delay<0 * Add NEWS entry
* bpo-32250: Implement asyncio.current_task() and asyncio.all_tasks() (#4799)Andrew Svetlov2017-12-162-37/+270
|
* Add tests for using PEP560 with classes implemented in C. (#4883)Serhiy Storchaka2017-12-161-0/+18
| | | Based on tests from #4878
* bpo-32002: Refactor C locale coercion tests (GH-4369)Nick Coghlan2017-12-161-54/+82
| | | | | | | | | | Exactly which locale requests will end up giving you the "C" locale is actually platform dependent. A blank locale and "POSIX" will translate to "C" on most Linux distros, but may not do so on other platforms, so this adjusts the way the tests are structured to better account for that. This is an initial step towards fixing the current test failure on Cygwin (hence the issue reference)
* bpo-29240, bpo-32030: Py_Main() re-reads config if encoding changes (#4899)Victor Stinner2017-12-163-7/+30
| | | | | | | | | | | | | | | | | | bpo-29240, bpo-32030: If the encoding change (C locale coerced or UTF-8 Mode changed), Py_Main() now reads again the configuration with the new encoding. Changes: * Add _Py_UnixMain() called by main(). * Rename pymain_free_pymain() to pymain_clear_pymain(), it can now be called multipled times. * Rename pymain_parse_cmdline_envvars() to pymain_read_conf(). * Py_Main() now clears orig_argc and orig_argv at exit. * Remove argv_copy2, Py_Main() doesn't modify argv anymore. There is no need anymore to get two copies of the wchar_t** argv. * _PyCoreConfig: add coerce_c_locale and coerce_c_locale_warn. * Py_UTF8Mode is now initialized to -1. * Locale coercion (PEP 538) now respects -I and -E options.
* bpo-27456: Ensure TCP_NODELAY is set on linux (#4231)Yury Selivanov2017-12-165-31/+52
|
* bpo-32248: Implement importlib.abc.ResourceReader (GH-4892)Brett Cannon2017-12-162-0/+77
|
* bpo-32294: Fix multiprocessing test_semaphore_tracker() (#4885)Victor Stinner2017-12-151-1/+1
| | | | Run the child process with -E option to ignore the PYTHONWARNINGS environment variable.
* bpo-32265: Classify class and static methods of builtin types. (#4776)Serhiy Storchaka2017-12-154-3/+21
| | | | Add types.ClassMethodDescriptorType for unbound class methods.
* bpo-30416: Protect the optimizer during constant folding. (#4860)Serhiy Storchaka2017-12-152-2/+10
| | | | | | | | It no longer spends much time doing complex calculations and no longer consumes much memory for creating large constants that will be dropped later. This fixes also bpo-21074.
* bpo-27169: The __debug__ constant is now optimized out at compile time. (#4880)Serhiy Storchaka2017-12-152-8/+9
| | | This fixes also bpo-22091.
* bpo-32311: Implement asyncio.create_task() shortcut (#4848)Andrew Svetlov2017-12-159-90/+151
| | | | | * Implement functionality * Add documentation
* bpo-32327: Convert asyncio functions documented as coroutines to coroutines. ↵Yury Selivanov2017-12-159-165/+143
| | | | (#4872)
* bpo-32329: Fix -R option for hash randomization (#4873)Victor Stinner2017-12-141-2/+10
| | | | | | | | | | | | bpo-32329, bpo-32030: * The -R option now turns on hash randomization when the PYTHONHASHSEED environment variable is set to 0 Previously, the option was ignored. * sys.flags.hash_randomization is now properly set to 0 when hash randomization is turned off by PYTHONHASHSEED=0. * _PyCoreConfig_ReadEnv() now reads the PYTHONHASHSEED environment variable. _Py_HashRandomization_Init() now only apply the configuration, it doesn't read PYTHONHASHSEED anymore.
* bpo-32143: add f_fsid to os.statvfs() (#4571)Giuseppe Scrivano2017-12-141-0/+5
| | | Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
* bpo-32226: Implementation of PEP 560 (core components) (#4732)Ivan Levkivskyi2017-12-143-2/+362
| | | | | This part of the PEP implementation adds support for __mro_entries__ and __class_getitem__ by updating __build_class__ and PyObject_GetItem.
* bpo-32314: Implement asyncio.run() (#4852)Yury Selivanov2017-12-143-0/+150
|
* bpo-32297: Few misspellings found in Python source code comments. (#4803)Mike2017-12-1434-66/+66
| | | | | | | | * Fix multiple typos in code comments * Add spacing in comments (test_logging.py, test_math.py) * Fix spaces at the beginning of comments in test_logging.py
* bpo-32225: Implementation of PEP 562 (#4731)Ivan Levkivskyi2017-12-145-0/+78
| | | | | Implement PEP 562: module __getattr__ and __dir__. The implementation simply updates module_getattro and module_dir.
* bpo-32302: Fix distutils bdist_wininst for CRT v142 (#4851)Victor Stinner2017-12-141-2/+2
| | | CRT v142 is binary compatible with CRT v140.
* bpo-30241: implement contextlib.AbstractAsyncContextManager (#1412)Jelle Zijlstra2017-12-142-3/+73
|
* bpo-32296: Unbreak tests on Windows (#4850)Yury Selivanov2017-12-131-4/+7
|
* bpo-32296: Implement asyncio.get_event_loop and _get_running_loop in C. (#4827)Yury Selivanov2017-12-132-20/+140
| | | | | | | | asyncio.get_event_loop(), and, subsequently asyncio._get_running_loop() are one of the most frequently executed functions in asyncio. They also can't be sped up by third-party event loops like uvloop. When implemented in C they become 4x faster.
* pythoninfo: Add builtins, test.support, ... (#4840)Victor Stinner2017-12-131-1/+50
| | | | | | Collect more info from builtins, resource, test.test_socket and test.support modules. Co-Authored-By: Christian Heimes <christian@python.org>
* Fix couple typos (#4839)Andrew Svetlov2017-12-132-2/+2
|
* bpo-29240: PEP 540: Add a new UTF-8 Mode (#855)Victor Stinner2017-12-1310-15/+233
| | | | | | | | | | | | | | | | | | | | | | * Add -X utf8 command line option, PYTHONUTF8 environment variable and a new sys.flags.utf8_mode flag. * If the LC_CTYPE locale is "C" at startup: enable automatically the UTF-8 mode. * Add _winapi.GetACP(). encodings._alias_mbcs() now calls _winapi.GetACP() to get the ANSI code page * locale.getpreferredencoding() now returns 'UTF-8' in the UTF-8 mode. As a side effect, open() now uses the UTF-8 encoding by default in this mode. * Py_DecodeLocale() and Py_EncodeLocale() now use the UTF-8 encoding in the UTF-8 Mode. * Update subprocess._args_from_interpreter_flags() to handle -X utf8 * Skip some tests relying on the current locale if the UTF-8 mode is enabled. * Add test_utf8mode.py. * _Py_DecodeUTF8_surrogateescape() gets a new optional parameter to return also the length (number of wide characters). * pymain_get_global_config() and pymain_set_global_config() now always copy flag values, rather than only copying if the new value is greater than the old value.
* Test atexit shutdown mechanism in a subprocess (#4828)Antoine Pitrou2017-12-131-0/+16
| | | | * Test atexit shutdown mechanism in a subprocess
* bpo-17852: Revert incorrect fix based on misunderstanding of _Py_PyAtExit() ↵Antoine Pitrou2017-12-131-24/+0
| | | | semantics (#4826)
* bpo-32101: Fix tests for PYTHONDEVMODE=1 (#4821)Victor Stinner2017-12-123-17/+16
| | | | test_asycio: remove also aio_path which was used when asyncio was developed outside the stdlib.
* bpo-32230: Set sys.warnoptions with -X dev (#4820)Victor Stinner2017-12-125-60/+91
| | | | | | | | | | | | | | Rather than supporting dev mode directly in the warnings module, this instead adjusts the initialisation code to add an extra 'default' entry to sys.warnoptions when dev mode is enabled. This ensures that dev mode behaves *exactly* as if `-Wdefault` had been passed on the command line, including in the way it interacts with `sys.warnoptions`, and with other command line flags like `-bb`. Fix also bpo-20361: have -b & -bb options take precedence over any other warnings options. Patch written by Nick Coghlan, with minor modifications of Victor Stinner.
* Fix improper use of re.escape() in tests. (#4814)Serhiy Storchaka2017-12-121-1/+1
|