Skip to content

Commit 038670a

Browse files
authored
Drop deprecated AutoSchema._get_reference method (#9525)
As well the unused RemovedInDRF316Warning
1 parent f8dbea1 commit 038670a

File tree

2 files changed

+1
-15
lines changed

2 files changed

+1
-15
lines changed

rest_framework/__init__.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,5 @@
2323
ISO_8601 = 'iso-8601'
2424

2525

26-
class RemovedInDRF316Warning(DeprecationWarning):
27-
pass
28-
29-
3026
class RemovedInDRF317Warning(PendingDeprecationWarning):
3127
pass

rest_framework/schemas/openapi.py

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,7 @@
1111
from django.db import models
1212
from django.utils.encoding import force_str
1313

14-
from rest_framework import (
15-
RemovedInDRF316Warning, exceptions, renderers, serializers
16-
)
14+
from rest_framework import exceptions, renderers, serializers
1715
from rest_framework.compat import inflection, uritemplate
1816
from rest_framework.fields import _UnvalidatedField, empty
1917
from rest_framework.settings import api_settings
@@ -721,11 +719,3 @@ def get_tags(self, path, method):
721719
path = path[1:]
722720

723721
return [path.split('/')[0].replace('_', '-')]
724-
725-
def _get_reference(self, serializer):
726-
warnings.warn(
727-
"Method `_get_reference()` has been renamed to `get_reference()`. "
728-
"The old name will be removed in DRF v3.16.",
729-
RemovedInDRF316Warning, stacklevel=2
730-
)
731-
return self.get_reference(serializer)

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy