Skip to content

bpo-40275: Use new test.support helper submodules in tests #21450

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
94 commits
Select commit Hold shift + click to select a range
e1d4001
Use new test.support helper submodules in tests
shihai1991 Jul 12, 2020
104060d
remove unused module
shihai1991 Jul 12, 2020
62a6061
Merge branch 'master' into bpo_40275_helper_replace_13
shihai1991 Jul 12, 2020
bc385bc
bpo-20181: Convert the readline module to the Argument Clinic (#14326)
ZackerySpytz Jul 12, 2020
bc3d804
bpo-20175: Convert Modules/_multiprocessing to the Argument Clinic (G…
ZackerySpytz Jul 12, 2020
c2819d3
bpo-41146: Convert signal.default_int_handler() to Argument Clinic (G…
serhiy-storchaka Jul 12, 2020
26c9c70
bpo-41288: Fix a crash in unpickling invalid NEWOBJ_EX. (GH-21458)
serhiy-storchaka Jul 13, 2020
56c4331
bpo-32192: A basic lazy importer example (GH-21330)
nanjekyejoannah Jul 13, 2020
170a8a8
Fix repeated words in Classes tutorial (GH-21455)
PaulMcMillan Jul 14, 2020
b3aef83
bpo-32528: Document the change in inheritance of asyncio.CancelledErr…
JustAnotherArchivist Jul 14, 2020
a2d9d5d
bpo-41273: asyncio's proactor read transport's better performance by …
tontinton Jul 14, 2020
0675e5f
bpo-20183: Convert _locale to the Argument Clinic (GH-14201)
ZackerySpytz Jul 15, 2020
3c3411b
bpo-39017: Avoid infinite loop in the tarfile module (GH-21454)
rishi93 Jul 15, 2020
f25bfa2
bpo-41302: Fix build with system libmpdec (GH-21481)
felixonmars Jul 15, 2020
bde9b72
Fix -Wstrict-prototypes warning in thread_pthread.h. (GH-21477)
benjaminp Jul 15, 2020
cddbe8e
Fix -Wstring-prototypes warnings in _zoneinfo.c. (GH-21478)
benjaminp Jul 15, 2020
6d537b4
bpo-40150: Fix mismatched argument in RegisterWaitForSingleObject() c…
ZackerySpytz Jul 15, 2020
9f11bcc
bpo-41304: Ensure python3x._pth is loaded on Windows (GH-21495)
zooba Jul 15, 2020
5303bf8
bpo-31844: Remove _markupbase.ParserBase.error() (GH-8562)
berkerpeksag Jul 16, 2020
6ecd55a
bpo-31844: Move whatsnew note to 3.10.rst (GH-21504)
berkerpeksag Jul 16, 2020
4b9dfef
Remove unnecessary spaces in code blocks in urllib.parse.rst (GH-21500)
chrisyeh96 Jul 16, 2020
f2197cb
Fix possibly-unitialized warning in string_parser.c. (GH-21503)
benjaminp Jul 16, 2020
e57f75d
Fix trivial typo in the PEG string parser (GH-21508)
ericvsmith Jul 16, 2020
1349c97
bpo-41300: IDLE - save files with non-ascii chars (GH-21512)
terryjreedy Jul 16, 2020
ee26dc3
bpo-41195: Add getter for Openssl security level (GH-21282)
matthewhughes934 Jul 17, 2020
4134617
bpo-40941: Unify implicit and explicit state in the frame and generat…
markshannon Jul 17, 2020
d9f6d8b
bpo-43104: Update NEWS to include CVE-2020-15801 reference (GH-21521)
zooba Jul 17, 2020
19141a1
Fix a small grammatical mistake in a comment (GH-21526)
brettcannon Jul 17, 2020
61feac4
bpo-41288: Refactor of unpickling NEWOBJ and NEWOBJ_EX opcodes. (GH-2…
serhiy-storchaka Jul 18, 2020
77c28b1
bpo-41262: Convert memoryview to Argument Clinic. (GH-21421)
serhiy-storchaka Jul 18, 2020
5837652
bpo-41325: Add version note for args and kwargs property in call obje…
uSpike Jul 18, 2020
d6258af
bpo-39603: Prevent header injection in http methods (GH-18485)
amiremohamadi Jul 18, 2020
f0d0237
bpo-41295: Reimplement the Carlo Verre "hackcheck" (GH-21528)
scoder Jul 18, 2020
6f297a3
bpo-41333: Convert OrderedDict.pop() to Argument Clinic (GH-21534)
serhiy-storchaka Jul 19, 2020
de846a1
bpo-41205: Document Decimal power 0 to the 0 (GH-21386)
srinivasreddy Jul 19, 2020
ebbe4cf
bpo-38169: Increase code coverage for SharedMemory and ShareableList …
vinay0410 Jul 19, 2020
36a8204
bpo-41338: Fix DeprecationWarning in tests (GH-21542)
methane Jul 20, 2020
fed528f
bpo-40741: Update macOS installer to use SQLite 3.32.3 (GH-20979)
Jul 20, 2020
9264f19
Doc: fix import of asdl.py when called from outside Doc/. (GH-21529)
JulienPalard Jul 20, 2020
a2425a2
bpo-37703: improve asyncio.gather documentation regarding cancellatio…
vinay0410 Jul 20, 2020
833cd79
Simple Documentation fix: Missing link to return type class. (GH-21291)
Volker-Weissmann Jul 20, 2020
185ac7d
bpo-41336: Fix the error handling in zoneinfo_new_instance() (GH-21546)
ZackerySpytz Jul 20, 2020
ca8d63e
bpo-41343: Convert methods of complex to Argument Clinic (GH-21550)
corona10 Jul 20, 2020
93ccf70
bpo-41334: Convert constructors of str, bytes and bytearray to Argume…
serhiy-storchaka Jul 20, 2020
a597f0a
bpo-41342: Convert int.__round__ to Argument Clinic (GH-21549)
serhiy-storchaka Jul 20, 2020
ccbc2bc
bpo-40741: Update Windows build to include SQLite 3.32.3 (GH-21570)
zooba Jul 20, 2020
1bf47e5
bpo-41283: Fix mismatched argument name for imghdr.what (GH-21501)
ammaraskar Jul 21, 2020
808203d
bpo-41364: Reduce import overhead of uuid module (GH-21586)
zooba Jul 21, 2020
f766adc
bpo-41341: Recursive evaluation of ForwardRef in get_type_hints (#21553)
wyfo Jul 22, 2020
4ce1885
bpo-41369 Update to libmpdec-2.5.1: new features (GH-21593)
skrah Jul 22, 2020
e45c083
Stick with the phrase "default parameter value" (GH-21590)
andresdelfino Jul 22, 2020
b1bac9c
bpo-41182 selector: use DefaultSelector based upon implementation (GH…
Akasurde Jul 23, 2020
b5ffc5c
bpo-4630: Fix errors in Lib/idlelib/NEWS.txt (GH-21594)
ZackerySpytz Jul 23, 2020
5a7e588
bpo-41366: Fix clang warning for sign conversion (GH-21592)
henryiii Jul 23, 2020
e89752d
bpo-41317: Remove reader on cancellation in asyncio.loop.sock_accept(…
agronholm Jul 23, 2020
aaac3b5
bpo-41373: IDLE: Fix saving files loaded with no newlines or mixed ne…
serhiy-storchaka Jul 25, 2020
0454fd7
bpo-37309: NEWS for #41373 (GH-21612)
terryjreedy Jul 25, 2020
b9063e5
bpo-38731: Add --quiet option to py_compile CLI (GH-17134)
gvsheva Jul 25, 2020
1ca7578
bpo-41314: fixed annotations __future__ version (GH-21616)
YoSTEALTH Jul 25, 2020
004e82b
bpo-39868: Add documentation for Assignment Expressions (walrus, PEP …
shankarj67 Jul 25, 2020
d481884
bpo-41385: Fix test_executable_without_cwd on Windows (GH-21608)
serhiy-storchaka Jul 26, 2020
3b83635
Delete remaining references to Grammar/Grammar from docs (#21624)
gvanrossum Jul 26, 2020
505d16d
Fix atexitmodule doc (GH-21456)
linchiwei123 Jul 26, 2020
36457bb
bpo-41384: Raise TclError in tkinter.OptionMenu (GH-21601)
Akuli Jul 27, 2020
e93448a
bpo-41340: Removed fallback implementation for strdup (GH-21634)
Jul 27, 2020
d2b0cab
bpo-31904: Fix test_ftplib failures for VxWorks RTOS (GH-19447)
pxinwr Jul 27, 2020
aa7c22e
bpo-41401: Fix test_fspath_support in test_io. (GH-21640)
serhiy-storchaka Jul 27, 2020
ae085b1
bpo-40939: Use the new grammar for the grammar specification document…
pablogsal Jul 27, 2020
dbdeaa2
bpo-40939: Remove even more references to the old parser (GH-21642)
lysnikolaou Jul 27, 2020
68732c1
bpo-41045: Document debug feature of f-strings ('=') (GH-21509)
amaajemyfren Jul 27, 2020
d00400d
Validate the AST produced by the parser in debug mode (GH-21643)
pablogsal Jul 27, 2020
f45a004
bpo-35328: Set VIRTUAL_ENV_PROMPT at venv activation (GH-21587)
ZackerySpytz Jul 28, 2020
7655ae8
bpo-41328: Replace mention of Hudson CI with Travis CI and AppVeyor (…
Jul 28, 2020
97ac216
bpo-41412 and bpo-40948: Windows installer updates (GH-21656)
zooba Jul 28, 2020
7fff0da
Fix `List_Append` description, list is extracted at TOS1[-i] (GH-21465)
zhangyangyu Jul 28, 2020
fa966e2
Remove incorrect mention of method.__class__ in descriptor docs (GH-2…
Jongy Jul 28, 2020
744a9c5
closes bpo-38156: Always handle interrupts in PyOS_StdioReadline. (GH…
benjaminp Jul 29, 2020
953733b
bpo-41426 Fix grammar in curses.getmouse() documentation (GH-21677)
s3bw Jul 29, 2020
2c6db7b
bpo-41323: Perform 'peephole' optimizations directly on the CFG. (GH-…
markshannon Jul 30, 2020
88c59f6
bpo-40360: Handle PendingDeprecationWarning in test_lib2to3. (GH-21694)
tirkarthi Jul 31, 2020
b9c5c17
bpo-41421: Algebraic simplification for random.paretovariate() (GH-21…
rhettinger Aug 1, 2020
577fbbd
random module: Convert a "while 1" to "while True (GH-21700)
rhettinger Aug 2, 2020
51a9b9e
bpo-40979: refactored typing.rst; (mostly) same content, new sub-sect…
ramalho Aug 2, 2020
dd7378e
bpo-41424: Remove extra words in Tkinter-Packer documentation (GH-21707)
nmaynes Aug 3, 2020
78aeea9
bpo-41425: Make tkinter doc example runnable (GH-21706)
nerandell Aug 3, 2020
2edc37a
A (very) slight speed improvement for iterating over bytes (#21705)
gvanrossum Aug 3, 2020
d23a13f
bpo-40275: Use new test.support helper submodules in tests (GH-21449)
shihai1991 Aug 3, 2020
f491296
bpo-40275: Use new test.support helper submodules in tests (GH-21451)
shihai1991 Aug 3, 2020
7ad643a
bpo-40275: Use new test.support helper submodules in tests (GH-21448)
shihai1991 Aug 3, 2020
4c461ad
bpo-38912: regrtest logs unraisable exception into sys.__stderr__ (GH…
vstinner Aug 3, 2020
587f073
bpo-38156: Fix compiler warning in PyOS_StdioReadline() (GH-21721)
vstinner Aug 4, 2020
11c2ff2
bpo-41467: Fix asyncio recv_into() on Windows (GH-21720)
vstinner Aug 4, 2020
58220f0
bpo-41431: Optimize dict_merge for copy (GH-21674)
methane Aug 4, 2020
b568ebb
bpo-36982: Add support for extended color functions in ncurses 6.1 (G…
hpjansson Aug 4, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

extensions = ['sphinx.ext.coverage', 'sphinx.ext.doctest',
'pyspecific', 'c_annotations', 'escape4chm',
'asdl_highlight']
'asdl_highlight', 'peg_highlight']


doctest_global_setup = '''
Expand Down
6 changes: 2 additions & 4 deletions Doc/howto/descriptor.rst
Original file line number Diff line number Diff line change
Expand Up @@ -312,14 +312,12 @@ Running the interpreter shows how the function descriptor works in practice::
>>> d.f
<bound method D.f of <__main__.D object at 0x00B18C90>>

# Internally, the bound method stores the underlying function,
# the bound instance, and the class of the bound instance.
# Internally, the bound method stores the underlying function and
# the bound instance.
>>> d.f.__func__
<function D.f at 0x1012e5ae8>
>>> d.f.__self__
<__main__.D object at 0x1012e1f98>
>>> d.f.__class__
<class 'method'>


Static Methods and Class Methods
Expand Down
2 changes: 1 addition & 1 deletion Doc/library/__future__.rst
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ language using this mechanism:
| generator_stop | 3.5.0b1 | 3.7 | :pep:`479`: |
| | | | *StopIteration handling inside generators* |
+------------------+-------------+--------------+---------------------------------------------+
| annotations | 3.7.0b1 | 4.0 | :pep:`563`: |
| annotations | 3.7.0b1 | 3.10 | :pep:`563`: |
| | | | *Postponed evaluation of annotations* |
+------------------+-------------+--------------+---------------------------------------------+

Expand Down
8 changes: 8 additions & 0 deletions Doc/library/asyncio-task.rst
Original file line number Diff line number Diff line change
Expand Up @@ -387,6 +387,14 @@ Running Tasks Concurrently
# Task C: Compute factorial(4)...
# Task C: factorial(4) = 24

.. note::
If *return_exceptions* is False, cancelling gather() after it
has been marked done won't cancel any submitted awaitables.
For instance, gather can be marked done after propagating an
exception to the caller, therefore, calling ``gather.cancel()``
after catching an exception (raised by one of the awaitables) from
gather won't cancel any other awaitables.

.. versionchanged:: 3.7
If the *gather* itself is cancelled, the cancellation is
propagated regardless of *return_exceptions*.
Expand Down
11 changes: 10 additions & 1 deletion Doc/library/curses.rst
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ The module :mod:`curses` defines the following functions:
.. function:: getmouse()

After :meth:`~window.getch` returns :const:`KEY_MOUSE` to signal a mouse event, this
method should be call to retrieve the queued mouse event, represented as a
method should be called to retrieve the queued mouse event, represented as a
5-tuple ``(id, x, y, z, bstate)``. *id* is an ID value used to distinguish
multiple devices, and *x*, *y*, *z* are the event's coordinates. (*z* is
currently unused.) *bstate* is an integer value whose bits will be set to
Expand Down Expand Up @@ -242,6 +242,15 @@ The module :mod:`curses` defines the following functions:

Return ``True`` if the terminal can display colors; otherwise, return ``False``.

.. function:: has_extended_color_support()

Return ``True`` if the module supports extended colors; otherwise, return
``False``. Extended color support allows more than 256 color pairs for
terminals that support more than 16 colors (e.g. xterm-256color).

Extended color support requires ncurses version 6.1 or later.

.. versionadded:: 3.10

.. function:: has_ic()

Expand Down
3 changes: 3 additions & 0 deletions Doc/library/decimal.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1357,6 +1357,9 @@ In addition to the three supplied contexts, new contexts can be created with the
The rounding mode of the context is used. Results are always correctly-rounded
in the Python version.

``Decimal(0) ** Decimal(0)`` results in ``InvalidOperation``, and if ``InvalidOperation``
is not trapped, then results in ``Decimal('NaN')``.

.. versionchanged:: 3.3
The C module computes :meth:`power` in terms of the correctly-rounded
:meth:`exp` and :meth:`ln` functions. The result is well-defined but
Expand Down
2 changes: 1 addition & 1 deletion Doc/library/dis.rst
Original file line number Diff line number Diff line change
Expand Up @@ -640,7 +640,7 @@ the original TOS1.

.. opcode:: LIST_APPEND (i)

Calls ``list.append(TOS[-i], TOS)``. Used to implement list comprehensions.
Calls ``list.append(TOS1[-i], TOS)``. Used to implement list comprehensions.


.. opcode:: MAP_ADD (i)
Expand Down
8 changes: 4 additions & 4 deletions Doc/library/imghdr.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ byte stream.
The :mod:`imghdr` module defines the following function:


.. function:: what(filename, h=None)
.. function:: what(file, h=None)

Tests the image data contained in the file named by *filename*, and returns a
string describing the image type. If optional *h* is provided, the *filename*
is ignored and *h* is assumed to contain the byte stream to test.
Tests the image data contained in the file named by *file*, and returns a
string describing the image type. If optional *h* is provided, the *file*
argument is ignored and *h* is assumed to contain the byte stream to test.

.. versionchanged:: 3.6
Accepts a :term:`path-like object`.
Expand Down
23 changes: 23 additions & 0 deletions Doc/library/importlib.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1719,6 +1719,29 @@ To import a Python source file directly, use the following recipe
spec.loader.exec_module(module)


Implementing lazy imports
'''''''''''''''''''''''''

The example below shows how to implement lazy imports::

>>> import importlib.util
>>> import sys
>>> def lazy_import(name):
... spec = importlib.util.find_spec(name)
... loader = importlib.util.LazyLoader(spec.loader)
... spec.loader = loader
... module = importlib.util.module_from_spec(spec)
... sys.modules[name] = module
... loader.exec_module(module)
... return module
...
>>> lazy_typing = lazy_import("typing")
>>> #lazy_typing is a real module object,
>>> #but it is not loaded in memory yet.
>>> lazy_typing.TYPE_CHECKING
False



Setting up an importer
''''''''''''''''''''''
Expand Down
2 changes: 0 additions & 2 deletions Doc/library/language.rst
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,8 @@ These modules include:

.. toctree::

parser.rst
ast.rst
symtable.rst
symbol.rst
token.rst
keyword.rst
tokenize.rst
Expand Down
6 changes: 4 additions & 2 deletions Doc/library/multiprocessing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2173,7 +2173,8 @@ with the :class:`Pool` class.

.. method:: apply_async(func[, args[, kwds[, callback[, error_callback]]]])

A variant of the :meth:`apply` method which returns a result object.
A variant of the :meth:`apply` method which returns a
:class:`~multiprocessing.pool.AsyncResult` object.

If *callback* is specified then it should be a callable which accepts a
single argument. When the result becomes ready *callback* is applied to
Expand Down Expand Up @@ -2203,7 +2204,8 @@ with the :class:`Pool` class.

.. method:: map_async(func, iterable[, chunksize[, callback[, error_callback]]])

A variant of the :meth:`.map` method which returns a result object.
A variant of the :meth:`.map` method which returns a
:class:`~multiprocessing.pool.AsyncResult` object.

If *callback* is specified then it should be a callable which accepts a
single argument. When the result becomes ready *callback* is applied to
Expand Down
Loading