From 375374c396dd6655507fb36bfbc2781f654f6065 Mon Sep 17 00:00:00 2001 From: Evgenii Alekseev Date: Thu, 22 Aug 2024 18:28:26 +0300 Subject: [PATCH] docs: improve waiter classes docs --- src/ahriman/models/waiter.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/ahriman/models/waiter.py b/src/ahriman/models/waiter.py index 8a22c008..70ff3104 100644 --- a/src/ahriman/models/waiter.py +++ b/src/ahriman/models/waiter.py @@ -67,7 +67,7 @@ class WaiterTaskFinished(WaiterResult): indicates whether the waiter completed with success or not Returns: - Literal[True]: always False + Literal[True]: always ``True`` """ return True @@ -82,7 +82,7 @@ class WaiterTimedOut(WaiterResult): indicates whether the waiter completed with success or not Returns: - Literal[False]: always False + Literal[False]: always ``False`` """ return False @@ -108,7 +108,7 @@ class Waiter: check if timer is out Returns: - bool: True in case current monotonic time is more than :attr:`start_time` and :attr:`wait_timeout` + bool: ``True`` in case current monotonic time is more than :attr:`start_time` and :attr:`wait_timeout` doesn't equal to 0 """ since_start = time.monotonic() - self.start_time @@ -124,7 +124,7 @@ class Waiter: **kwargs(Params.kwargs): keyword arguments for check call Returns: - WaiterResult: consumed time in seconds + WaiterResult: waiter result object """ while not (timed_out := self.is_timed_out()) and in_progress(*args, **kwargs): time.sleep(self.interval)