module documentation

Undocumented

Class ​Context​Var A fake ContextVar based on the previous greenlet/threading ident function. Used on Python 3.6, eventlet, and old versions of gevent.
Class ​Local No class docstring; 0/2 property, 0/1 class variable, 1/8 method documented
Class ​Local​Manager No summary
Class ​Local​Proxy A proxy to the object bound to a Local. All operations on the proxy are forwarded to the bound object. If no object is bound, a RuntimeError is raised.
Class ​Local​Stack This class works similar to a Local but keeps a stack of objects instead. This is best explained with an example:
Function __release​_local__ Undocumented
Function get​_ident Undocumented
Function release​_local Releases the contents of the local for the current context. This makes it possible to use locals without a manager.
Constant F Undocumented
Variable greenlet​_patched Undocumented
Class _​Cannot​Use​Context​Var Undocumented
Class _​Proxy​IOp Look up an augmented assignment method on a proxied object. The method is wrapped to return the proxy instead of the object.
Class _​Proxy​Lookup Descriptor that handles proxied attribute lookup for LocalProxy.
Function ​_l​_to​_r​_op Swap the argument order to turn an l-op into an r-op.
def __release_local__(storage):

Undocumented

Parameters
storage:t.AnyUndocumented
def get_ident():

Undocumented

Returns
intUndocumented
def release_local(local):

Releases the contents of the local for the current context. This makes it possible to use locals without a manager.

Example:

>>> loc = Local()
>>> loc.foo = 42
>>> release_local(loc)
>>> hasattr(loc, 'foo')
False

With this function one can release Local objects as well as LocalStack objects. However it is not possible to release data held by proxies that way, one always has to retain a reference to the underlying local object in order to be able to release it.

New in version 0.6.1.
Parameters
local:t.Union[Local, LocalStack]Undocumented
F =

Undocumented

Value
t.TypeVar('F',
          bound=t.Callable[..., t.Any])
greenlet_patched =

Undocumented

def _l_to_r_op(op):
Swap the argument order to turn an l-op into an r-op.
Parameters
op:FUndocumented
Returns
FUndocumented