summaryrefslogtreecommitdiff
path: root/Lib/test
Commit message (Collapse)AuthorAgeFilesLines
...
* bpo-39991: uuid._netstat_getnode() ignores IPv6 addresses (GH-19043)Victor Stinner2020-03-171-9/+45
| | | | uuid.getnode() now skips IPv6 addresses with the same string length than a MAC address (17 characters): only use MAC addresses.
* bpo-39638: Keep ASDL signatures in the AST nodes (GH-18515)Batuhan Taşkaya2020-03-162-4/+14
|
* bpo-38870: Implement support for ast.FunctionType in ast.unparse (GH-19016)Batuhan Taşkaya2020-03-151-3/+11
|
* bpo-39360: Ensure all workers exit when finalizing a multiprocessing Pool ↵Batuhan Taşkaya2020-03-151-0/+18
| | | | | | | | | (GH-19009) When the pull is not used via the context manager or terminate() is called, there is a system in multiprocessing.util that handles finalization of all pools via an atexit handler (the Finalize) class. This class registers the _terminate_pool handler in the registry of finalizers of the module, and that registry is called on interpreter exit via _exit_function. The problem is that the "happy" path with the context manager or manual call to finalize() does some extra steps that _terminate_pool does not. The step that is not executed when the atexit() handler calls _terminate_pool is pinging the _change_notifier queue to unblock the maintenance threads. This commit moves the notification to the _terminate_pool function so is called from both code paths. Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
* bpo-39507: Add HTTP status 418 "I'm a Teapot" (GH-18291)Ross2020-03-151-0/+1
|
* bpo-39965: Correctly raise SyntaxError if await is used outside async ↵Pablo Galindo2020-03-151-0/+38
| | | | functions when PyCF_ALLOW_TOP_LEVEL_AWAIT is set (GH-19010)
* bpo-38576: Disallow control characters in hostnames in http.client (GH-18995)Ashwin Ramaswami2020-03-142-3/+46
| | | | Add host validation for control characters for more CVE-2019-18348 protection.
* bpo-39509: Update HTTP status code to follow IANA (GH-18294)Dong-hee Na2020-03-141-0/+2
| | | Add status codes 103 EARLY_HINTS and 425 TOO_EARLY.
* bpo-39871: Fix possible SystemError in atan2, copysign and remainder (GH-18806)Zackery Spytz2020-03-141-0/+16
| | | | | | In math_2(), the first PyFloat_AsDouble() call should be checked for failure before the second call. Co-authored-by: Mark Dickinson <dickinsm@gmail.com>
* Revert "bpo-39087: Add _PyUnicode_GetUTF8Buffer()" (GH-18985)Inada Naoki2020-03-141-22/+0
| | | | | | | * Revert "bpo-39087: Add _PyUnicode_GetUTF8Buffer() (GH-17659)" This reverts commit c7ad974d341d3edb6b9d2a2dcae4d3d4794ada6b. * Update unicodeobject.h
* bpo-39087: Add _PyUnicode_GetUTF8Buffer() (GH-17659)Inada Naoki2020-03-141-0/+22
| | | Co-authored-by: Victor Stinner <vstinner@python.org>
* bpo-36144: OrderedDict Union (PEP 584) (#18967)Brandt Bucher2020-03-131-0/+43
|
* bpo-36144: Update os.environ and os.environb for PEP 584 (#18911)Charles Burkland2020-03-131-0/+90
|
* bpo-39947: Move get_recursion_depth() to _testinternalcapi (GH-18974)Victor Stinner2020-03-132-2/+2
| | | | | Move get_recursion_depth() function from _testcapi to _testinternalcapi to avoid accessing PyThreadState attributes directly in _testcapi.
* bpo-39689: Do not test undefined casts to _Bool (GH-18964)Stefan Krah2020-03-121-0/+4
| | | - When casting to _Bool, arrays should only contain zeros or ones.
* bpo-39926: Update unicodedata checksum tests for Unicode 13.0 update. (GH-18913)Benjamin Peterson2020-03-101-2/+2
| | | I forget these tests required the cpu resource.
* Update some www.unicode.org URLs to use HTTPS. (GH-18912)Benjamin Peterson2020-03-102-2/+2
|
* closes bpo-39926: Update Unicode to 13.0.0. (GH-18910)Benjamin Peterson2020-03-101-0/+1
|
* bpo-34822: Simplify AST for subscription. (GH-9605)Serhiy Storchaka2020-03-102-11/+15
| | | | | | | | | * Remove the slice type. * Make Slice a kind of the expr type instead of the slice type. * Replace ExtSlice(slices) with Tuple(slices, Load()). * Replace Index(value) with a value itself. All non-terminal nodes in AST for expressions are now of the expr type.
* bpo-38075: Fix random_seed(): use PyObject_CallOneArg() (GH-18897)Victor Stinner2020-03-101-1/+1
| | | | | | Fix the random.Random.seed() method when a bool is passed as the seed. PyObject_Vectorcall() was misused: use PyObject_CallOneArg() instead.
* bpo-1294959: Add sys.platlibdir attribute (GH-18381)Victor Stinner2020-03-102-6/+13
| | | | | | | | | | | | | Add --with-platlibdir option to the configure script: name of the platform-specific library directory, stored in the new sys.platlitdir attribute. It is used to build the path of platform-specific dynamic libraries and the path of the standard library. It is equal to "lib" on most platforms. On Fedora and SuSE, it is equal to "lib64" on 64-bit systems. Co-Authored-By: Jan Matějek <jmatejek@suse.com> Co-Authored-By: Matěj Cepl <mcepl@cepl.eu> Co-Authored-By: Charalampos Stratakis <cstratak@redhat.com>
* bpo-39828: Fix json.tool to catch BrokenPipeError (GH-18779)Dong-hee Na2020-03-101-0/+13
|
* bpo-19466: Py_Finalize() clears daemon threads earlier (GH-18848)Victor Stinner2020-03-091-0/+45
| | | | | | | | Clear the frames of daemon threads earlier during the Python shutdown to call objects destructors. So "unclosed file" resource warnings are now emitted for daemon threads in a more reliable way. Cleanup _PyThreadState_DeleteExcept() code: rename "garbage" to "list".
* bpo-28577: Special case added to IP v4 and v6 hosts for /32 and /128 ↵Pete Wicken2020-03-091-4/+13
| | | | | | networks (GH-18757) The `.hosts()` method now returns the single address present in a /32 or /128 network.
* bpo-36287: Make ast.dump() not output optional fields and attributes with ↵Serhiy Storchaka2020-03-101-14/+15
| | | | | | | default values. (GH-18843) The default values for optional fields and attributes of AST nodes are now set as class attributes (e.g. Constant.kind is set to None).
* bpo-38870: Simplify sequence interleaves in ast.unparse (GH-17892)Batuhan Taşkaya2020-03-091-14/+20
|
* bpo-39877: Remove useless PyEval_InitThreads() calls (GH-18883)Victor Stinner2020-03-091-3/+2
| | | | Py_Initialize() calls PyEval_InitThreads() since Python 3.7. It's no longer needed to call it explicitly.
* bpo-38643: Raise SystemError instead of crashing when PyNumber_ToBase is ↵Serhiy Storchaka2020-03-091-0/+14
| | | | called with invalid base. (GH-18863)
* bpo-39850: Add support for abstract sockets in multiprocessing (GH-18866)Pablo Galindo2020-03-091-0/+13
|
* bpo-38691: importlib ignores PYTHONCASEOK if -E is used (GH-18627)idomic2020-03-092-1/+7
| | | | | The importlib module now ignores the PYTHONCASEOK environment variable when the -E or -I command line options are being used.
* bpo-39517: Allow runpy.run_path() to accept path-like objects (GH-18699)Maor Kleinberger2020-03-081-0/+9
|
* bpo-36144: Update MappingProxyType with PEP 584's operators (#18814)Brandt Bucher2020-03-071-0/+19
| | | We make `|=` raise TypeError, since it would be surprising if `C.__dict__ |= {'x': 0}` silently did nothing, while `C.__dict__.update({'x': 0})` is an error.
* bpo-38894: Fix pathlib.Path.glob in the presence of symlinks and ↵Pablo Galindo2020-03-071-0/+36
| | | | | insufficient permissions (GH-18815) Co-authored-by: Matt Wozniski <mwozniski@bloomberg.net>
* bpo-39889: Fix ast.unparse() for subscript. (GH-18824)Serhiy Storchaka2020-03-071-0/+14
|
* bpo-39882: Py_FatalError() logs the function name (GH-18819)Victor Stinner2020-03-075-14/+26
| | | | | | | | | | | | The Py_FatalError() function is replaced with a macro which logs automatically the name of the current function, unless the Py_LIMITED_API macro is defined. Changes: * Add _Py_FatalErrorFunc() function. * Remove the function name from the message of Py_FatalError() calls which included the function name. * Update tests.
* bpo-36144: Implement defaultdict union (GH-18729)Brandt Bucher2020-03-061-0/+38
| | | For PEP 585 (this isn't in the PEP but is an obvious follow-up).
* bpo-39855: Fix test_subprocess if nobody user doesn't exist (GH-18781)Victor Stinner2020-03-051-2/+7
| | | | | test_subprocess.test_user() now skips the test on an user name if the user name doesn't exist. For example, skip the test if the user "nobody" doesn't exist on Linux.
* bpo-39674: Revert "bpo-37330: open() no longer accept 'U' in file mode ↵Victor Stinner2020-03-043-27/+30
| | | | | | | (GH-16959)" (GH-18767) This reverts commit e471e72977c83664f13d041c78549140c86c92de. The mode will be removed from Python 3.10.
* bpo-39639: Remove the AST "Suite" node and associated code (GH-18513)Batuhan Taşkaya2020-03-041-1/+1
| | | | | | | | The AST "Suite" node is no longer used and it can be removed from the ASDL definition and related structures (compiler, visitors, ...). Co-Authored-By: Victor Stinner <vstinner@python.org> Co-authored-by: Brett Cannon <54418+brettcannon@users.noreply.github.com> Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
* bpo-39702: Relax grammar restrictions on decorators (PEP 614) (GH-18570)Brandt Bucher2020-03-033-15/+89
|
* bpo-35712: Make using NotImplemented in a boolean context issue a ↵MojoVampire2020-03-033-4/+18
| | | | deprecation warning (GH-13195)
* bpo-12915: Skip test_pkgutil.test_name_resolution() non-encodable filenames ↵Michael Felt2020-03-031-1/+5
| | | | | | (GH-18720) When filesystem encoding cannot encode the Unicode string used for a filename continue testing with the next example.
* bpo-38091: Import deadlock detection causes deadlock (GH-17518)Armin Rigo2020-03-021-0/+8
| | | Automerge-Triggered-By: @brettcannon
* bpo-39778: Don't traverse weak-reference lists OrderedDict's tp_traverse and ↵Pablo Galindo2020-03-021-0/+20
| | | | | | tp_clear (GH-18749) Objects do not own weak references to them directly through the __weakref__ list so these do not need to be traversed by the GC.
* bpo-38870: Add docstring support to ast.unparse (GH-17760)Batuhan Taşkaya2020-03-021-70/+126
| | | | | | Allow ast.unparse to detect docstrings in functions, modules and classes and produce nicely formatted unparsed output for said docstrings. Co-Authored-By: Pablo Galindo <Pablogsal@gmail.com>
* bpo-39764: Make Task.get_stack accept ag_frame (#18669)Lidi Zheng2020-03-021-0/+15
| | | | Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
* bpo-38971: Open file in codecs.open() closes if exception raised. (GH-17666)Chris A2020-03-021-0/+9
| | | | | | Open issue in the BPO indicated a desire to make the implementation of codecs.open() at parity with io.open(), which implements a try/except to assure file stream gets closed before an exception is raised.
* bpo-39495: Remove default value from C impl of TreeBuilder.start (GH-18275)Shantanu2020-03-021-0/+4
|
* bpo-39678: refactor queue manager thread (GH-18551)Thomas Moreau2020-03-011-8/+8
|
* bpo-38870: Implement a precedence algorithm in ast.unparse (GH-17377)Batuhan Taşkaya2020-03-012-1/+49
| | | | Implement a simple precedence algorithm for ast.unparse in order to avoid redundant parenthesis for nested structures in the final output.