PyDocs

Nav

Generic Operating System Services

sleep

time

function
  • sleep(seconds, /)
sleep(seconds)

Delay execution for a given number of seconds.  The argument may be
a floating-point number for subsecond precision.
Changed in 3.5, 3.11, 3.13, 3.15
  • 3.5: The function now sleeps at least seconds even if the sleep is interrupted by a signal, except if the signal handler raises an exception (see PEP 475 for the rationale).
  • 3.11: On Unix, the clock_nanosleep() and nanosleep() functions are now used if available. On Windows, a waitable timer is now used.
  • 3.13: Raises an auditing event.
  • 3.15: Accepts any real number, not only integer or float.
0 Examples
No examples for time/sleep.
See Also
No see-alsos for time/sleep
0 Notes
No notes for sleep