Some cleanup of new repeat() docstring

This commit is contained in:
Griatch 2021-03-07 18:02:16 +01:00
parent f773dec5ba
commit 9c2268d3d1

View file

@ -1081,10 +1081,9 @@ def repeat(interval, callback, persistent=True, idstring="", stop=False,
*args, **kwargs: Used as arguments to `callback`. *args, **kwargs: Used as arguments to `callback`.
Returns: Returns:
tuple or None: This is the `store_key` - the identifier for the created ticker. tuple or None: The tuple is the `store_key` - the identifier for the
Store this and pass into unrepat() in order to to stop this ticker created ticker. Store this and pass into unrepat() in order to to stop
later. It this lost you need to stop the ticker via `TICKER_HANDLER.remove` this ticker later. Returns `None` if `stop=True`.
by supplying all the same arguments directly. No return if `stop=True`
Raises: Raises:
KeyError: If trying to stop a ticker that was not found. KeyError: If trying to stop a ticker that was not found.
@ -1113,7 +1112,9 @@ def unrepeat(store_key):
Args: Args:
store_key (tuple): This is the return from `repeat`, used to uniquely store_key (tuple): This is the return from `repeat`, used to uniquely
identify the ticker to stop. identify the ticker to stop. Without the store_key, the ticker
must be stopped by passing its parameters to `TICKER_HANDLER.remove`
directly.
Returns: Returns:
bool: True if a ticker was stopped, False if not (for example because no bool: True if a ticker was stopped, False if not (for example because no