mirror of
https://github.com/django/django.git
synced 2024-12-23 09:36:06 +00:00
Clarified a contrib.sites deprecation and added to 1.7 release notes.
This commit is contained in:
parent
3b89d2d540
commit
ba27f89587
@ -206,8 +206,8 @@ details on these changes.
|
||||
|
||||
* ``AppCommand.handle_app()`` will no longer be supported.
|
||||
|
||||
* ``RequestSite`` will be located in ``django.contrib.sites.requests`` and
|
||||
``get_current_site`` in ``django.contrib.sites.shortcuts``.
|
||||
* ``RequestSite`` and ``get_current_site()`` will no longer be importable from
|
||||
``django.contrib.sites.models``.
|
||||
|
||||
* FastCGI support via the ``runfcgi`` management command will be
|
||||
removed. Please deploy your project using WSGI.
|
||||
|
@ -472,9 +472,10 @@ a fallback when the database-backed sites framework is not available.
|
||||
Sets the ``name`` and ``domain`` attributes to the value of
|
||||
:meth:`~django.http.HttpRequest.get_host`.
|
||||
|
||||
.. versionchanged:: 1.7
|
||||
.. deprecated:: 1.7
|
||||
|
||||
This class used to be defined in ``django.contrib.sites.models``.
|
||||
This class used to be defined in ``django.contrib.sites.models``. The
|
||||
old import location will work until Django 1.9.
|
||||
|
||||
A :class:`~django.contrib.sites.requests.RequestSite` object has a similar
|
||||
interface to a normal :class:`~django.contrib.sites.models.Site` object,
|
||||
@ -498,9 +499,10 @@ Finally, to avoid repetitive fallback code, the framework provides a
|
||||
object or a :class:`~django.contrib.sites.requests.RequestSite` object
|
||||
based on the request.
|
||||
|
||||
.. versionchanged:: 1.7
|
||||
.. deprecated:: 1.7
|
||||
|
||||
This function used to be defined in ``django.contrib.sites.models``.
|
||||
The old import location will work until Django 1.9.
|
||||
|
||||
.. versionchanged:: 1.8
|
||||
|
||||
|
@ -1757,6 +1757,17 @@ FastCGI support
|
||||
FastCGI support via the ``runfcgi`` management command will be removed in
|
||||
Django 1.9. Please deploy your project using WSGI.
|
||||
|
||||
Moved objects in ``contrib.sites``
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
Following the app-loading refactor, two objects in
|
||||
``django.contrib.sites.models`` needed to be moved because they must be
|
||||
available without importing ``django.contrib.sites.models`` when
|
||||
``django.contrib.sites`` isn't installed. Import ``RequestSite`` from
|
||||
``django.contrib.sites.requests`` and ``get_current_site()`` from
|
||||
``django.contrib.sites.shortcuts``. The old import locations will work until
|
||||
Django 1.9.
|
||||
|
||||
.. removed-features-1.7:
|
||||
|
||||
Features removed in 1.7
|
||||
|
Loading…
Reference in New Issue
Block a user