Discussion:
Updating depricated restframework/compatibility methods.
Alex Daigle
2018-07-18 20:52:49 UTC
Permalink
To whom this may concern,

I wish to update a project which uses an old version of
djangorestframework. I am unable to find documentation on `get_module_name`
from the django rest framework (3.2.5). I found it in
rest_framework.compat, I have looked in the announcements and the notices
of deprecation for djangorestframework versions 2.x - 3.x and I have not
been able to find any information about its new replacement, about its
deprecation (or reasons for it being depricated), or steps to update.

Help would be greatly appreciated.
--
You received this message because you are subscribed to the Google Groups "Django REST framework" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-rest-framework+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Alex Daigle
2018-07-18 21:05:18 UTC
Permalink
To whom this may concern,

I wish to update a project which uses an old version of
djangorestframework. I am unable to find documentation on `get_model_name`
from the django rest framework (3.2.5). I found it in
rest_framework.compat, I have looked in the announcements and the notices
of deprecation for djangorestframework versions 2.x - 3.x and I have not
been able to find any information about its new replacement, about its
deprecation (or reasons for it being depricated), or steps to update.

Help would be greatly appreciated
--
You received this message because you are subscribed to the Google Groups "Django REST framework" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-rest-framework+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Carlton Gibson
2018-07-19 06:16:46 UTC
Permalink
Hi Alex,

See https://github.com/encode/django-rest-framework/commit/25de8c960fcbb79f6d1097da22cab2dfeefb4e6e <https://github.com/encode/django-rest-framework/commit/25de8c960fcbb79f6d1097da22cab2dfeefb4e6e>

You just need `model_cls._meta.model_name` by the look of it.

Kind Regards,

Carlton
Post by Alex Daigle
To whom this may concern,
I wish to update a project which uses an old version of djangorestframework. I am unable to find documentation on `get_model_name` from the django rest framework (3.2.5). I found it in rest_framework.compat, I have looked in the announcements and the notices of deprecation for djangorestframework versions 2.x - 3.x and I have not been able to find any information about its new replacement, about its deprecation (or reasons for it being depricated), or steps to update.
Help would be greatly appreciated
--
You received this message because you are subscribed to the Google Groups "Django REST framework" group.
For more options, visit https://groups.google.com/d/optout <https://groups.google.com/d/optout>.
--
You received this message because you are subscribed to the Google Groups "Django REST framework" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-rest-framework+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Alex Daigle
2018-07-19 14:40:33 UTC
Permalink
Very helpful, thank you.
Post by Carlton Gibson
Hi Alex,
See
https://github.com/encode/django-rest-framework/commit/25de8c960fcbb79f6d1097da22cab2dfeefb4e6e
You just need `model_cls._meta.model_name` by the look of it.
Kind Regards,
Carlton
To whom this may concern,
I wish to update a project which uses an old version of
djangorestframework. I am unable to find documentation on `get_model_name`
from the django rest framework (3.2.5). I found it in
rest_framework.compat, I have looked in the announcements and the notices
of deprecation for djangorestframework versions 2.x - 3.x and I have not
been able to find any information about its new replacement, about its
deprecation (or reasons for it being depricated), or steps to update.
Help would be greatly appreciated
--
You received this message because you are subscribed to the Google Groups
"Django REST framework" group.
To unsubscribe from this group and stop receiving emails from it, send an
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Django REST framework" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-rest-framework+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Loading...