Use correct class to indicate present deprecation

`PendingDeprecationWarning` means "we plan to deprecate, but haven't
yet." A feature that's to be deleted in the next release is not planned
to be deprecated; it **is** deprecated.

> Base class for warnings about features which are obsolete and expected
> to be deprecated in the future, but are not deprecated at the moment.
>
> This class is rarely used as emitting a warning about a possible
> upcoming deprecation is unusual, and DeprecationWarning is preferred for
> already active deprecations.

https://docs.python.org/3/library/exceptions.html#PendingDeprecationWarning
This commit is contained in:
David Cain 2022-09-21 10:51:52 -07:00
parent c6cafc9725
commit c98a8f0fa6
No known key found for this signature in database
GPG Key ID: 8D4C4ABF1EA02DC1

View File

@ -37,5 +37,5 @@ class RemovedInDRF314Warning(PendingDeprecationWarning):
pass
class RemovedInDRF315Warning(PendingDeprecationWarning):
class RemovedInDRF315Warning(DeprecationWarning):
pass