[doc] Fix a few margins due to bad markup (GH-23619)
This commit is contained in:
parent
bf353f3c2d
commit
96a09df644
|
@ -198,7 +198,7 @@ These do not emulate the native look-and-feel of the platform.
|
||||||
A subclass of FileDialog that creates a dialog window for selecting a
|
A subclass of FileDialog that creates a dialog window for selecting a
|
||||||
destination file.
|
destination file.
|
||||||
|
|
||||||
.. method:: ok_command()
|
.. method:: ok_command()
|
||||||
|
|
||||||
Test whether or not the selection points to a valid file that is not a
|
Test whether or not the selection points to a valid file that is not a
|
||||||
directory. Confirmation is required if an already existing file is
|
directory. Confirmation is required if an already existing file is
|
||||||
|
|
|
@ -61,7 +61,7 @@ helper, :class:`auto`.
|
||||||
the bitwise operations without losing their :class:`Flag` membership.
|
the bitwise operations without losing their :class:`Flag` membership.
|
||||||
|
|
||||||
.. function:: unique
|
.. function:: unique
|
||||||
:noindex:
|
:noindex:
|
||||||
|
|
||||||
Enum class decorator that ensures only one name is bound to any one value.
|
Enum class decorator that ensures only one name is bound to any one value.
|
||||||
|
|
||||||
|
|
|
@ -35,45 +35,45 @@ in :mod:`logging` itself) and defining handlers which are declared either in
|
||||||
|
|
||||||
.. function:: dictConfig(config)
|
.. function:: dictConfig(config)
|
||||||
|
|
||||||
Takes the logging configuration from a dictionary. The contents of
|
Takes the logging configuration from a dictionary. The contents of
|
||||||
this dictionary are described in :ref:`logging-config-dictschema`
|
this dictionary are described in :ref:`logging-config-dictschema`
|
||||||
below.
|
below.
|
||||||
|
|
||||||
If an error is encountered during configuration, this function will
|
If an error is encountered during configuration, this function will
|
||||||
raise a :exc:`ValueError`, :exc:`TypeError`, :exc:`AttributeError`
|
raise a :exc:`ValueError`, :exc:`TypeError`, :exc:`AttributeError`
|
||||||
or :exc:`ImportError` with a suitably descriptive message. The
|
or :exc:`ImportError` with a suitably descriptive message. The
|
||||||
following is a (possibly incomplete) list of conditions which will
|
following is a (possibly incomplete) list of conditions which will
|
||||||
raise an error:
|
raise an error:
|
||||||
|
|
||||||
* A ``level`` which is not a string or which is a string not
|
* A ``level`` which is not a string or which is a string not
|
||||||
corresponding to an actual logging level.
|
corresponding to an actual logging level.
|
||||||
* A ``propagate`` value which is not a boolean.
|
* A ``propagate`` value which is not a boolean.
|
||||||
* An id which does not have a corresponding destination.
|
* An id which does not have a corresponding destination.
|
||||||
* A non-existent handler id found during an incremental call.
|
* A non-existent handler id found during an incremental call.
|
||||||
* An invalid logger name.
|
* An invalid logger name.
|
||||||
* Inability to resolve to an internal or external object.
|
* Inability to resolve to an internal or external object.
|
||||||
|
|
||||||
Parsing is performed by the :class:`DictConfigurator` class, whose
|
Parsing is performed by the :class:`DictConfigurator` class, whose
|
||||||
constructor is passed the dictionary used for configuration, and
|
constructor is passed the dictionary used for configuration, and
|
||||||
has a :meth:`configure` method. The :mod:`logging.config` module
|
has a :meth:`configure` method. The :mod:`logging.config` module
|
||||||
has a callable attribute :attr:`dictConfigClass`
|
has a callable attribute :attr:`dictConfigClass`
|
||||||
which is initially set to :class:`DictConfigurator`.
|
which is initially set to :class:`DictConfigurator`.
|
||||||
You can replace the value of :attr:`dictConfigClass` with a
|
You can replace the value of :attr:`dictConfigClass` with a
|
||||||
suitable implementation of your own.
|
suitable implementation of your own.
|
||||||
|
|
||||||
:func:`dictConfig` calls :attr:`dictConfigClass` passing
|
:func:`dictConfig` calls :attr:`dictConfigClass` passing
|
||||||
the specified dictionary, and then calls the :meth:`configure` method on
|
the specified dictionary, and then calls the :meth:`configure` method on
|
||||||
the returned object to put the configuration into effect::
|
the returned object to put the configuration into effect::
|
||||||
|
|
||||||
def dictConfig(config):
|
def dictConfig(config):
|
||||||
dictConfigClass(config).configure()
|
dictConfigClass(config).configure()
|
||||||
|
|
||||||
For example, a subclass of :class:`DictConfigurator` could call
|
For example, a subclass of :class:`DictConfigurator` could call
|
||||||
``DictConfigurator.__init__()`` in its own :meth:`__init__()`, then
|
``DictConfigurator.__init__()`` in its own :meth:`__init__()`, then
|
||||||
set up custom prefixes which would be usable in the subsequent
|
set up custom prefixes which would be usable in the subsequent
|
||||||
:meth:`configure` call. :attr:`dictConfigClass` would be bound to
|
:meth:`configure` call. :attr:`dictConfigClass` would be bound to
|
||||||
this new subclass, and then :func:`dictConfig` could be called exactly as
|
this new subclass, and then :func:`dictConfig` could be called exactly as
|
||||||
in the default, uncustomized state.
|
in the default, uncustomized state.
|
||||||
|
|
||||||
.. versionadded:: 3.2
|
.. versionadded:: 3.2
|
||||||
|
|
||||||
|
|
|
@ -1323,12 +1323,12 @@ or `the MSDN <https://msdn.microsoft.com/en-us/library/z0kc8e3z.aspx>`_ on Windo
|
||||||
|
|
||||||
.. data:: RWF_APPEND
|
.. data:: RWF_APPEND
|
||||||
|
|
||||||
Provide a per-write equivalent of the :data:`O_APPEND` :func:`os.open`
|
Provide a per-write equivalent of the :data:`O_APPEND` :func:`os.open`
|
||||||
flag. This flag is meaningful only for :func:`os.pwritev`, and its
|
flag. This flag is meaningful only for :func:`os.pwritev`, and its
|
||||||
effect applies only to the data range written by the system call. The
|
effect applies only to the data range written by the system call. The
|
||||||
*offset* argument does not affect the write operation; the data is always
|
*offset* argument does not affect the write operation; the data is always
|
||||||
appended to the end of the file. However, if the *offset* argument is
|
appended to the end of the file. However, if the *offset* argument is
|
||||||
``-1``, the current file *offset* is updated.
|
``-1``, the current file *offset* is updated.
|
||||||
|
|
||||||
.. availability:: Linux 4.16 and newer.
|
.. availability:: Linux 4.16 and newer.
|
||||||
|
|
||||||
|
|
|
@ -290,4 +290,4 @@ Linux Platforms
|
||||||
ids.extend(info["ID_LIKE"].split())
|
ids.extend(info["ID_LIKE"].split())
|
||||||
return ids
|
return ids
|
||||||
|
|
||||||
.. versionadded:: 3.10
|
.. versionadded:: 3.10
|
||||||
|
|
|
@ -532,9 +532,9 @@ Analysis of the profiler data is done using the :class:`~pstats.Stats` class.
|
||||||
instance holds information related to the function's profile such as how
|
instance holds information related to the function's profile such as how
|
||||||
long the function took to run, how many times it was called, etc...
|
long the function took to run, how many times it was called, etc...
|
||||||
|
|
||||||
.. versionadded:: 3.9
|
.. versionadded:: 3.9
|
||||||
Added the following dataclasses: StatsProfile, FunctionProfile.
|
Added the following dataclasses: StatsProfile, FunctionProfile.
|
||||||
Added the following function: get_stats_profile.
|
Added the following function: get_stats_profile.
|
||||||
|
|
||||||
.. _deterministic-profiling:
|
.. _deterministic-profiling:
|
||||||
|
|
||||||
|
|
|
@ -56,12 +56,12 @@ created. Socket addresses are represented as follows:
|
||||||
bytes-like object can be used for either type of address when
|
bytes-like object can be used for either type of address when
|
||||||
passing it as an argument.
|
passing it as an argument.
|
||||||
|
|
||||||
.. versionchanged:: 3.3
|
.. versionchanged:: 3.3
|
||||||
Previously, :const:`AF_UNIX` socket paths were assumed to use UTF-8
|
Previously, :const:`AF_UNIX` socket paths were assumed to use UTF-8
|
||||||
encoding.
|
encoding.
|
||||||
|
|
||||||
.. versionchanged:: 3.5
|
.. versionchanged:: 3.5
|
||||||
Writable :term:`bytes-like object` is now accepted.
|
Writable :term:`bytes-like object` is now accepted.
|
||||||
|
|
||||||
.. _host_port:
|
.. _host_port:
|
||||||
|
|
||||||
|
|
|
@ -156,7 +156,7 @@ Examining Symbol Tables
|
||||||
|
|
||||||
Return ``True`` if the symbol is local to its block.
|
Return ``True`` if the symbol is local to its block.
|
||||||
|
|
||||||
.. method:: is_annotated()
|
.. method:: is_annotated()
|
||||||
|
|
||||||
Return ``True`` if the symbol is annotated.
|
Return ``True`` if the symbol is annotated.
|
||||||
|
|
||||||
|
|
|
@ -153,47 +153,47 @@ Programmatic Interface
|
||||||
count information. *timing* enables a timestamp relative to when tracing was
|
count information. *timing* enables a timestamp relative to when tracing was
|
||||||
started to be displayed.
|
started to be displayed.
|
||||||
|
|
||||||
.. method:: run(cmd)
|
.. method:: run(cmd)
|
||||||
|
|
||||||
Execute the command and gather statistics from the execution with
|
Execute the command and gather statistics from the execution with
|
||||||
the current tracing parameters. *cmd* must be a string or code object,
|
the current tracing parameters. *cmd* must be a string or code object,
|
||||||
suitable for passing into :func:`exec`.
|
suitable for passing into :func:`exec`.
|
||||||
|
|
||||||
.. method:: runctx(cmd, globals=None, locals=None)
|
.. method:: runctx(cmd, globals=None, locals=None)
|
||||||
|
|
||||||
Execute the command and gather statistics from the execution with the
|
Execute the command and gather statistics from the execution with the
|
||||||
current tracing parameters, in the defined global and local
|
current tracing parameters, in the defined global and local
|
||||||
environments. If not defined, *globals* and *locals* default to empty
|
environments. If not defined, *globals* and *locals* default to empty
|
||||||
dictionaries.
|
dictionaries.
|
||||||
|
|
||||||
.. method:: runfunc(func, /, *args, **kwds)
|
.. method:: runfunc(func, /, *args, **kwds)
|
||||||
|
|
||||||
Call *func* with the given arguments under control of the :class:`Trace`
|
Call *func* with the given arguments under control of the :class:`Trace`
|
||||||
object with the current tracing parameters.
|
object with the current tracing parameters.
|
||||||
|
|
||||||
.. method:: results()
|
.. method:: results()
|
||||||
|
|
||||||
Return a :class:`CoverageResults` object that contains the cumulative
|
Return a :class:`CoverageResults` object that contains the cumulative
|
||||||
results of all previous calls to ``run``, ``runctx`` and ``runfunc``
|
results of all previous calls to ``run``, ``runctx`` and ``runfunc``
|
||||||
for the given :class:`Trace` instance. Does not reset the accumulated
|
for the given :class:`Trace` instance. Does not reset the accumulated
|
||||||
trace results.
|
trace results.
|
||||||
|
|
||||||
.. class:: CoverageResults
|
.. class:: CoverageResults
|
||||||
|
|
||||||
A container for coverage results, created by :meth:`Trace.results`. Should
|
A container for coverage results, created by :meth:`Trace.results`. Should
|
||||||
not be created directly by the user.
|
not be created directly by the user.
|
||||||
|
|
||||||
.. method:: update(other)
|
.. method:: update(other)
|
||||||
|
|
||||||
Merge in data from another :class:`CoverageResults` object.
|
Merge in data from another :class:`CoverageResults` object.
|
||||||
|
|
||||||
.. method:: write_results(show_missing=True, summary=False, coverdir=None)
|
.. method:: write_results(show_missing=True, summary=False, coverdir=None)
|
||||||
|
|
||||||
Write coverage results. Set *show_missing* to show lines that had no
|
Write coverage results. Set *show_missing* to show lines that had no
|
||||||
hits. Set *summary* to include in the output the coverage summary per
|
hits. Set *summary* to include in the output the coverage summary per
|
||||||
module. *coverdir* specifies the directory into which the coverage
|
module. *coverdir* specifies the directory into which the coverage
|
||||||
result files will be output. If ``None``, the results for each source
|
result files will be output. If ``None``, the results for each source
|
||||||
file are placed in its directory.
|
file are placed in its directory.
|
||||||
|
|
||||||
A simple example demonstrating the use of the programmatic interface::
|
A simple example demonstrating the use of the programmatic interface::
|
||||||
|
|
||||||
|
|
|
@ -913,8 +913,8 @@ Color control
|
||||||
Set pencolor to the RGB color represented by *r*, *g*, and *b*. Each of
|
Set pencolor to the RGB color represented by *r*, *g*, and *b*. Each of
|
||||||
*r*, *g*, and *b* must be in the range 0..colormode.
|
*r*, *g*, and *b* must be in the range 0..colormode.
|
||||||
|
|
||||||
If turtleshape is a polygon, the outline of that polygon is drawn with the
|
If turtleshape is a polygon, the outline of that polygon is drawn with the
|
||||||
newly set pencolor.
|
newly set pencolor.
|
||||||
|
|
||||||
.. doctest::
|
.. doctest::
|
||||||
:skipif: _tkinter is None
|
:skipif: _tkinter is None
|
||||||
|
@ -962,8 +962,8 @@ Color control
|
||||||
Set fillcolor to the RGB color represented by *r*, *g*, and *b*. Each of
|
Set fillcolor to the RGB color represented by *r*, *g*, and *b*. Each of
|
||||||
*r*, *g*, and *b* must be in the range 0..colormode.
|
*r*, *g*, and *b* must be in the range 0..colormode.
|
||||||
|
|
||||||
If turtleshape is a polygon, the interior of that polygon is drawn
|
If turtleshape is a polygon, the interior of that polygon is drawn
|
||||||
with the newly set fillcolor.
|
with the newly set fillcolor.
|
||||||
|
|
||||||
.. doctest::
|
.. doctest::
|
||||||
:skipif: _tkinter is None
|
:skipif: _tkinter is None
|
||||||
|
@ -1001,8 +1001,8 @@ Color control
|
||||||
Equivalent to ``pencolor(colorstring1)`` and ``fillcolor(colorstring2)``
|
Equivalent to ``pencolor(colorstring1)`` and ``fillcolor(colorstring2)``
|
||||||
and analogously if the other input format is used.
|
and analogously if the other input format is used.
|
||||||
|
|
||||||
If turtleshape is a polygon, outline and interior of that polygon is drawn
|
If turtleshape is a polygon, outline and interior of that polygon is drawn
|
||||||
with the newly set colors.
|
with the newly set colors.
|
||||||
|
|
||||||
.. doctest::
|
.. doctest::
|
||||||
:skipif: _tkinter is None
|
:skipif: _tkinter is None
|
||||||
|
|
|
@ -217,7 +217,6 @@ Ellipsis
|
||||||
There are two types of integers:
|
There are two types of integers:
|
||||||
|
|
||||||
Integers (:class:`int`)
|
Integers (:class:`int`)
|
||||||
|
|
||||||
These represent numbers in an unlimited range, subject to available (virtual)
|
These represent numbers in an unlimited range, subject to available (virtual)
|
||||||
memory only. For the purpose of shift and mask operations, a binary
|
memory only. For the purpose of shift and mask operations, a binary
|
||||||
representation is assumed, and negative numbers are represented in a variant of
|
representation is assumed, and negative numbers are represented in a variant of
|
||||||
|
|
Loading…
Reference in New Issue