PyDocs

Nav

Python Runtime Services

getgeneratorstate

inspect

function · Added in 3.2 (source)
  • getgeneratorstate(generator)
Get current state of a generator-iterator.

Possible states are:
  GEN_CREATED: Waiting to start execution.
  GEN_RUNNING: Currently being executed by the interpreter.
  GEN_SUSPENDED: Currently suspended at a yield expression.
  GEN_CLOSED: Execution has completed.
0 Examples
No examples for inspect/getgeneratorstate.
See Also
No see-alsos for inspect/getgeneratorstate
0 Notes
No notes for getgeneratorstate