interruptible_sleep
AsyncFunction
This function is defined in the retry_utils module.Sleep with periodic interruption checks.
Signature
Parameters
float
required
Total sleep duration in seconds
float
default:"0.2"
How often to check for interruption (seconds)
Optional
Function that returns True if sleep should be interrupted
Returns
bool
True if completed full sleep, False if interrupted
Usage
Uses
interrupt_fnasyncio.sleep
Source
View on GitHub
praisonaiagents/agent/retry_utils.py at line 70
