django_evolution.deprecation

Internal support for handling deprecations in Django Evolution.

The version-specific objects in this module are not considered stable between releases, and may be removed at any point. The base objects are considered stable.

New in version 2.2.

Module Attributes

RemovedInNextDjangoEvolutionWarning

Alias for deprecations in the next Django Evolution release.

Exceptions

BaseRemovedInDjangoEvolutionWarning

Base class for a Django Evolution deprecation warning.

RemovedInDjangoEvolution30Warning

Deprecations for features being removed in Django Evolution 3.0.

RemovedInDjangoEvolution40Warning

Deprecations for features being removed in Django Evolution 4.0.

RemovedInNextDjangoEvolutionWarning

Alias for deprecations in the next Django Evolution release.

exception django_evolution.deprecation.BaseRemovedInDjangoEvolutionWarning

Bases: DeprecationWarning

Base class for a Django Evolution deprecation warning.

All version-specific deprecation warnings inherit from this, allowing callers to check for Django Evolution deprecations without being tied to a specific version.

New in version 2.2.

classmethod warn(message, stacklevel=2)

Emit the deprecation warning.

This is a convenience function that emits a deprecation warning using this class, with a suitable default stack level. Callers can provide a useful message and a custom stack level.

Parameters:
  • message (unicode) – The message to show in the deprecation warning.

  • stacklevel (int, optional) – The stack level for the warning.

exception django_evolution.deprecation.RemovedInDjangoEvolution30Warning

Bases: BaseRemovedInDjangoEvolutionWarning

Deprecations for features being removed in Django Evolution 3.0.

Note that this class will itself be removed in Django Evolution 3.0. If you need to check against Django Evolution deprecation warnings, please see BaseRemovedInDjangoEvolutionWarning.

New in version 2.2.

exception django_evolution.deprecation.RemovedInDjangoEvolution40Warning

Bases: BaseRemovedInDjangoEvolutionWarning

Deprecations for features being removed in Django Evolution 4.0.

Note that this class will itself be removed in Django Evolution 4.0. If you need to check against Django Evolution deprecation warnings, please see BaseRemovedInDjangoEvolutionWarning. Alternatively, you can use the alias for this class, RemovedInNextDjangoEvolutionWarning.

New in version 2.2.

django_evolution.deprecation.RemovedInNextDjangoEvolutionWarning

Alias for deprecations in the next Django Evolution release.