From 210d0489c5daad56b806f8165f9fe09fb3c2a019 Mon Sep 17 00:00:00 2001 From: Claude Paroz Date: Wed, 26 Feb 2014 22:48:20 +0100 Subject: Fixed #21188 -- Introduced subclasses for to-be-removed-in-django-XX warnings MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Thanks Anssi Kääriäinen for the idea and Simon Charette for the review. --- .../internals/contributing/writing-code/submitting-patches.txt | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'docs/internals/contributing/writing-code') diff --git a/docs/internals/contributing/writing-code/submitting-patches.txt b/docs/internals/contributing/writing-code/submitting-patches.txt index 37354f7a81..4efeab9fc5 100644 --- a/docs/internals/contributing/writing-code/submitting-patches.txt +++ b/docs/internals/contributing/writing-code/submitting-patches.txt @@ -173,11 +173,12 @@ There are a couple reasons that code in Django might be deprecated: As the :ref:`deprecation policy` describes, the first release of Django that deprecates a feature (``A.B``) should raise a -``PendingDeprecationWarning`` when the deprecated feature is invoked. Assuming +``RemovedInDjangoXXWarning`` (where XX is the Django version where the feature +will be removed) when the deprecated feature is invoked. Assuming we have a good test coverage, these warnings will be shown by the test suite when :ref:`running it ` with warnings enabled: ``python -Wall runtests.py``. This is annoying and the output of the test suite -should remain clean. Thus, when adding a ``PendingDeprecationWarning`` you need +should remain clean. Thus, when adding a ``RemovedInDjangoXXWarning`` you need to eliminate or silence any warnings generated when running the tests. The first step is to remove any use of the deprecated behavior by Django itself. @@ -218,9 +219,8 @@ Finally, there are a couple of updates to Django's documentation to make: under the ``A.B+2`` version describing what code will be removed. Once you have completed these steps, you are finished with the deprecation. -In each minor release, all ``PendingDeprecationWarning``\s are promoted to -``DeprecationWarning``\s and any features marked with ``DeprecationWarning`` -are removed. +In each minor release, all ``RemovedInDjangoXXWarning``\s matching the new +version are removed. Javascript patches ------------------ -- cgit v1.3