From bf34b383eb4169c192725fce744fc300502eb6b3 Mon Sep 17 00:00:00 2001 From: Alex Willmer Date: Wed, 3 Oct 2018 00:22:18 +0100 Subject: [PATCH] docs: Disambiguate references to Context This addresses an error found while running tox -edocs Warning, treated as error: mitogen/docs/api.rst:469:more than one target found for cross-reference u'Context': mitogen.core.Context, mitogen.parent.Context --- docs/api.rst | 8 +++++--- docs/getting_started.rst | 2 +- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/docs/api.rst b/docs/api.rst index c74193e3..6f114a0a 100644 --- a/docs/api.rst +++ b/docs/api.rst @@ -458,7 +458,7 @@ Router Class rich data structures that cannot normally be passed via a serialization. - :param Context via: + :param mitogen.core.Context via: Same as the `via` parameter for :meth:`local`. :param bool debug: @@ -1078,7 +1078,8 @@ Select Class each, returning the result of calling `msg.unpickle()` on each in turn. Results are returned in the order they arrived. - This is sugar for handling batch :class:`Context.call_async` + This is sugar for handling batch + :meth:`Context.call_async ` invocations: .. code-block:: python @@ -1245,7 +1246,8 @@ Broker Class .. method:: keep_alive Return :data:`True` if any reader's :attr:`Side.keep_alive` - attribute is :data:`True`, or any :class:`Context` is still + attribute is :data:`True`, or any + :class:`Context ` is still registered that is not the master. Used to delay shutdown while some important work is in progress (e.g. log draining). diff --git a/docs/getting_started.rst b/docs/getting_started.rst index 436b34a1..1c92a559 100644 --- a/docs/getting_started.rst +++ b/docs/getting_started.rst @@ -208,7 +208,7 @@ started the context, however as shown, this can be overridden. Calling A Function ------------------ -.. currentmodule:: mitogen.master +.. currentmodule:: mitogen.parent Now that some contexts exist, it is time to execute code in them. Any regular function, static method, or class method reachable directly from module scope