This document describes the current stable version of Kombu (4.0). For development docs, go here.

Python Compatibility - kombu.utils.compat

Python Compatibility Utilities.

kombu.utils.compat.NamedTuple(name, fields)[source]

Typed version of collections.namedtuple.

kombu.utils.compat.coro(gen)[source]

Decorator to mark generator as co-routine.

kombu.utils.compat.detect_environment()[source]

Detect the current environment: default, eventlet, or gevent.

kombu.utils.compat.entrypoints(namespace)[source]

Return setuptools entrypoints for namespace.

kombu.utils.compat.fileno(f)[source]

Get fileno from file-like object.

kombu.utils.compat.maybe_fileno(f)[source]

Get object fileno, or None if not defined.

kombu.utils.compat.nested(*args, **kwds)[source]

Nest context managers.