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

# `celery.utils.deprecated`

Deprecation utilities.

celery.utils.deprecated.Callable(deprecation=None, removal=None, alternative=None, description=None)

  Decorator for deprecated functions.

  A deprecation warning will be emitted when the function is called.

  Parameters:

    - deprecation (str) – Version that marks first deprecation, if this argument isn’t set a `PendingDeprecationWarning` will be emitted instead.

    - removal (str) – Future version when this feature will be removed.

    - alternative (str) – Instructions for an alternative solution (if any).

    - description (str) – Description of what’s being deprecated.

celery.utils.deprecated.Property(deprecation=None, removal=None, alternative=None, description=None)

  Decorator for deprecated properties.

celery.utils.deprecated.warn(description=None, deprecation=None, removal=None, alternative=None, stacklevel=2)

  Warn of (pending) deprecation.