-
Notifications
You must be signed in to change notification settings - Fork 143
Description
Thanks to @phillxnet, we now have a config to run with the Python's warning flag (#2655).
One of these warnings is relates to our use of Middlewares:
RemovedInDjango20Warning: Old-style middleware using settings.MIDDLEWARE_CLASSES is deprecated. Update your middleware and use settings.MIDDLEWARE instead.
"instead.", RemovedInDjango20Warning
This most likely relates to the deprecation of MIDDLEWARE_CLASSES in Django 1.10:
https://docs.djangoproject.com/en/1.11/ref/settings/#middleware-classes
Deprecated since version 1.10: Old-style middleware that uses settings.MIDDLEWARE_CLASSES are deprecated. Adapt old, custom middleware and use the MIDDLEWARE setting.
This was the default setting used in Django 1.9 and earlier. Django 1.10 introduced a new style of middleware. If you have an older project using this setting you should update any middleware you’ve written yourself to the new style and then use the MIDDLEWARE setting.
Note that this was fully removed from Django 2.0:
https://docs.djangoproject.com/en/4.2/releases/2.0/#features-removed-in-2-0
Support for old-style middleware using settings.MIDDLEWARE_CLASSES is removed.