select.devpoll()

select.devpoll() (Only supported on Solaris and derivatives.) Returns a /dev/poll polling object; see section /dev/poll Polling Objects below for the methods supported by devpoll objects. devpoll() objects are linked to the number of file descriptors allowed at the time of instantiation. If your program reduces this value, devpoll() will fail. If your program increases this value, devpoll() may return an incomplete list of active file descriptors. The new file descriptor is non-inheritable.

sched.scheduler.queue

scheduler.queue Read-only attribute returning a list of upcoming events in the order they will be run. Each event is shown as a named tuple with the following fields: time, priority, action, argument, kwargs.

sched.scheduler.cancel()

scheduler.cancel(event) Remove the event from the queue. If event is not an event currently in the queue, this method will raise a ValueError.

sched.scheduler.enterabs()

scheduler.enterabs(time, priority, action, argument=(), kwargs={}) Schedule a new event. The time argument should be a numeric type compatible with the return value of the timefunc function passed to the constructor. Events scheduled for the same time will be executed in the order of their priority. Executing the event means executing action(*argument, **kwargs). argument is a sequence holding the positional arguments for action. kwargs is a dictionary holding the keyword arguments for actio

sched.scheduler.enter()

scheduler.enter(delay, priority, action, argument=(), kwargs={}) Schedule an event for delay more time units. Other than the relative time, the other arguments, the effect and the return value are the same as those for enterabs(). Changed in version 3.3: argument parameter is optional. New in version 3.3: kwargs parameter was added.

sched.scheduler

class sched.scheduler(timefunc=time.monotonic, delayfunc=time.sleep) The scheduler class defines a generic interface to scheduling events. It needs two functions to actually deal with the “outside world” — timefunc should be callable without arguments, and return a number (the “time”, in any units whatsoever). If time.monotonic is not available, the timefunc default is time.time instead. The delayfunc function should be callable with one argument, compatible with the output of timefunc, and

RuntimeWarning

exception RuntimeWarning Base class for warnings about dubious runtime behavior.

sched.scheduler.empty()

scheduler.empty() Return true if the event queue is empty.

runpy.run_path()

runpy.run_path(file_path, init_globals=None, run_name=None) Execute the code at the named filesystem location and return the resulting module globals dictionary. As with a script name supplied to the CPython command line, the supplied path may refer to a Python source file, a compiled bytecode file or a valid sys.path entry containing a __main__ module (e.g. a zipfile containing a top-level __main__.py file). For a simple script, the specified code is simply executed in a fresh module namesp

round()

round(number[, ndigits]) Return the floating point value number rounded to ndigits digits after the decimal point. If ndigits is omitted, it returns the nearest integer to its input. Delegates to number.__round__(ndigits). For the built-in types supporting round(), values are rounded to the closest multiple of 10 to the power minus ndigits; if two multiples are equally close, rounding is done toward the even choice (so, for example, both round(0.5) and round(-0.5) are 0, and round(1.5) is 2)