run_iocsh.utils¶
Standalone utilities for run-iocsh.
Attributes¶
Functions¶
|
Poll |
Module Contents¶
- run_iocsh.utils.wait_for(predicate: collections.abc.Callable[[], bool], timeout: float = DEFAULT_WAIT_FOR_TIMEOUT, poll_interval: float = DEFAULT_POLL_INTERVAL) None[source]¶
Poll
predicateuntil it returns True ortimeoutelapses.Exceptions from
predicateare caught and treated as a false result (polling continues until timeout).- Args:
predicate: Callable invoked repeatedly; success when it returns True. timeout: Maximum seconds to wait before giving up. poll_interval: Seconds to sleep between polls.
- Raises:
TimeoutError: If the predicate never returns True within
timeout.