2.0.txt 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673
  1. ============================================
  2. Django 2.0 release notes - UNDER DEVELOPMENT
  3. ============================================
  4. Welcome to Django 2.0!
  5. These release notes cover the :ref:`new features <whats-new-2.0>`, as well as
  6. some :ref:`backwards incompatible changes <backwards-incompatible-2.0>` you'll
  7. want to be aware of when upgrading from Django 1.11 or earlier. We've
  8. :ref:`dropped some features<removed-features-2.0>` that have reached the end of
  9. their deprecation cycle, and we've :ref:`begun the deprecation process for some
  10. features <deprecated-features-2.0>`.
  11. See the :doc:`/howto/upgrade-version` guide if you're updating an existing
  12. project.
  13. Python compatibility
  14. ====================
  15. Django 2.0 supports Python 3.5+. Since Django 1.11, support for Python 2.7 and
  16. 3.4 is removed. We **highly recommend** and only officially support the latest
  17. release of each series.
  18. Third-party library support for older version of Django
  19. =======================================================
  20. Following the release of Django 2.0, we suggest that third-party app authors
  21. drop support for all versions of Django prior to 1.11. At that time, you should
  22. be able run your package's tests using ``python -Wd`` so that deprecation
  23. warnings do appear. After making the deprecation warning fixes, your app should
  24. be compatible with Django 2.0.
  25. .. _whats-new-2.0:
  26. What's new in Django 2.0
  27. ========================
  28. Minor features
  29. --------------
  30. :mod:`django.contrib.admin`
  31. ~~~~~~~~~~~~~~~~~~~~~~~~~~~
  32. * ...
  33. :mod:`django.contrib.admindocs`
  34. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  35. * ...
  36. :mod:`django.contrib.auth`
  37. ~~~~~~~~~~~~~~~~~~~~~~~~~~
  38. * The default iteration count for the PBKDF2 password hasher is increased from
  39. 36,000 to 100,000.
  40. :mod:`django.contrib.contenttypes`
  41. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  42. * ...
  43. :mod:`django.contrib.gis`
  44. ~~~~~~~~~~~~~~~~~~~~~~~~~
  45. * Added MySQL support for the
  46. :class:`~django.contrib.gis.db.models.functions.AsGeoJSON` function,
  47. :class:`~django.contrib.gis.db.models.functions.GeoHash` function,
  48. :class:`~django.contrib.gis.db.models.functions.IsValid` function, and
  49. :lookup:`isvalid` lookup.
  50. * Added the :class:`~django.contrib.gis.db.models.functions.Azimuth` and
  51. :class:`~django.contrib.gis.db.models.functions.LineLocatePoint` functions,
  52. supported on PostGIS and SpatiaLite.
  53. * Any :class:`~django.contrib.gis.geos.GEOSGeometry` imported from GeoJSON now
  54. has its SRID set.
  55. * Added the :attr:`.OSMWidget.default_zoom` attribute to customize the map's
  56. default zoom level.
  57. * Made metadata readable and editable on rasters through the
  58. :attr:`~django.contrib.gis.gdal.GDALRaster.metadata`,
  59. :attr:`~django.contrib.gis.gdal.GDALRaster.info`, and
  60. :attr:`~django.contrib.gis.gdal.GDALBand.metadata` attributes.
  61. * Allowed passing driver-specific creation options to
  62. :class:`~django.contrib.gis.gdal.GDALRaster` objects using ``papsz_options``.
  63. * Allowed creating :class:`~django.contrib.gis.gdal.GDALRaster` objects in
  64. GDAL's internal virtual filesystem. Rasters can now be :ref:`created from and
  65. converted to binary data <gdal-raster-vsimem>` in-memory.
  66. :mod:`django.contrib.messages`
  67. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  68. * ...
  69. :mod:`django.contrib.postgres`
  70. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  71. * The new ``distinct`` argument for
  72. :class:`~django.contrib.postgres.aggregates.ArrayAgg` determines if
  73. concatenated values will be distinct.
  74. * The new :class:`~django.contrib.postgres.functions.RandomUUID` database
  75. function returns a version 4 UUID. It requires use of PostgreSQL's
  76. ``pgcrypto`` extension which can be activated using the new
  77. :class:`~django.contrib.postgres.operations.CryptoExtension` migration
  78. operation.
  79. * :class:`django.contrib.postgres.indexes.GinIndex` now supports the
  80. ``fast_update`` and ``gin_pending_list_limit`` parameters.
  81. :mod:`django.contrib.redirects`
  82. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  83. * ...
  84. :mod:`django.contrib.sessions`
  85. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  86. * ...
  87. :mod:`django.contrib.sitemaps`
  88. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  89. * Added the ``protocol`` keyword argument to the
  90. :class:`~django.contrib.sitemaps.GenericSitemap` constructor.
  91. :mod:`django.contrib.sites`
  92. ~~~~~~~~~~~~~~~~~~~~~~~~~~~
  93. * ...
  94. :mod:`django.contrib.staticfiles`
  95. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  96. * ...
  97. :mod:`django.contrib.syndication`
  98. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  99. * ...
  100. Cache
  101. ~~~~~
  102. * ...
  103. CSRF
  104. ~~~~
  105. * ...
  106. Database backends
  107. ~~~~~~~~~~~~~~~~~
  108. * ...
  109. Email
  110. ~~~~~
  111. * ...
  112. File Storage
  113. ~~~~~~~~~~~~
  114. * :meth:`File.open() <django.core.files.File.open>` can be used as a context
  115. manager, e.g. ``with file.open() as f:``.
  116. File Uploads
  117. ~~~~~~~~~~~~
  118. * ...
  119. Forms
  120. ~~~~~
  121. * The new ``date_attrs`` and ``time_attrs`` arguments for
  122. :class:`~django.forms.SplitDateTimeWidget` and
  123. :class:`~django.forms.SplitHiddenDateTimeWidget` allow specifying different
  124. HTML attributes for the ``DateInput`` and ``TimeInput`` (or hidden)
  125. subwidgets.
  126. * The new :meth:`Form.errors.get_json_data()
  127. <django.forms.Form.errors.get_json_data>` method returns form errors as
  128. a dictionary suitable for including in a JSON response.
  129. Generic Views
  130. ~~~~~~~~~~~~~
  131. * ...
  132. Internationalization
  133. ~~~~~~~~~~~~~~~~~~~~
  134. * ...
  135. Management Commands
  136. ~~~~~~~~~~~~~~~~~~~
  137. * :djadmin:`inspectdb` now translates MySQL's unsigned integer columns to
  138. ``PositiveIntegerField`` or ``PositiveSmallIntegerField``.
  139. * The new :option:`makemessages --add-location` option controls the comment
  140. format in PO files.
  141. * :djadmin:`loaddata` can now :ref:`read from stdin <loading-fixtures-stdin>`.
  142. * The new :option:`diffsettings --output` option allows formatting the output
  143. in a unified diff format.
  144. * On Oracle, :djadmin:`inspectdb` can now introspect ``AutoField`` if the
  145. column is created as an identity column.
  146. * On MySQL, :djadmin:`dbshell` now supports client-side TLS certificates.
  147. Migrations
  148. ~~~~~~~~~~
  149. * ...
  150. Models
  151. ~~~~~~
  152. * The new :class:`~django.db.models.functions.StrIndex` database function
  153. finds the starting index of a string inside another string.
  154. * On Oracle, ``AutoField`` and ``BigAutoField`` are now created as `identity
  155. columns`_.
  156. .. _`identity columns`: https://docs.oracle.com/database/121/DRDAA/migr_tools_feat.htm#DRDAA109
  157. * The new ``chunk_size`` parameter of :meth:`.QuerySet.iterator` controls the
  158. number of rows fetched by the Python database client when streaming results
  159. from the database. For databases that don't support server-side cursors, it
  160. controls the number of results Django fetches from the database adapter.
  161. * Added the :class:`~django.db.models.functions.datetime.ExtractQuarter`
  162. function to extract the quarter from :class:`~django.db.models.DateField` and
  163. :class:`~django.db.models.DateTimeField`, and exposed it through the
  164. :lookup:`quarter` lookup.
  165. * Added the :class:`~django.db.models.functions.datetime.TruncQuarter`
  166. function to truncate :class:`~django.db.models.DateField` and
  167. :class:`~django.db.models.DateTimeField` to the first day of a quarter.
  168. Requests and Responses
  169. ~~~~~~~~~~~~~~~~~~~~~~
  170. * The :djadmin:`runserver` Web server supports HTTP 1.1.
  171. Serialization
  172. ~~~~~~~~~~~~~
  173. * ...
  174. Signals
  175. ~~~~~~~
  176. * ...
  177. Templates
  178. ~~~~~~~~~
  179. * To increase the usefulness of :meth:`.Engine.get_default` in third-party
  180. apps, it now returns the first engine if multiple ``DjangoTemplates`` engines
  181. are configured in ``TEMPLATES`` rather than raising ``ImproperlyConfigured``.
  182. * Custom template tags may now accept keyword-only arguments.
  183. Tests
  184. ~~~~~
  185. * Added threading support to :class:`~django.test.LiveServerTestCase`.
  186. * Added settings that allow customizing the test tablespace parameters for
  187. Oracle: :setting:`DATAFILE_SIZE`, :setting:`DATAFILE_TMP_SIZE`,
  188. :setting:`DATAFILE_EXTSIZE`, and :setting:`DATAFILE_TMP_EXTSIZE`.
  189. URLs
  190. ~~~~
  191. * ...
  192. Validators
  193. ~~~~~~~~~~
  194. * ...
  195. .. _backwards-incompatible-2.0:
  196. Backwards incompatible changes in 2.0
  197. =====================================
  198. Removed support for bytestrings in some places
  199. ----------------------------------------------
  200. To support native Python 2 strings, older Django versions had to accept both
  201. bytestrings and unicode strings. Now that Python 2 support is dropped,
  202. bytestrings should only be encountered around input/output boundaries (handling
  203. of binary fields or HTTP streams, for example). You might have to update your
  204. code to limit bytestring usage to a minimum, as Django no longer accepts
  205. bytestrings in certain code paths.
  206. Database backend API
  207. --------------------
  208. This section describes changes that may be needed in third-party database
  209. backends.
  210. * The ``DatabaseOperations.datetime_cast_date_sql()``,
  211. ``datetime_cast_time_sql()``, ``datetime_trunc_sql()``, and
  212. ``datetime_extract_sql()`` methods now return only the SQL to perform the
  213. operation instead of SQL and a list of parameters.
  214. * Third-party database backends should add a ``DatabaseWrapper.display_name``
  215. attribute with the name of the database that your backend works with. Django
  216. may use it in various messages, such as in system checks.
  217. * The first argument of ``SchemaEditor._alter_column_type_sql()`` is now
  218. ``model`` rather than ``table``.
  219. * The first argument of ``SchemaEditor._create_index_name()`` is now
  220. ``table_name`` rather than ``model``.
  221. Dropped support for Oracle 11.2
  222. -------------------------------
  223. The end of upstream support for Oracle 11.2 is Dec. 2020. Django 1.11 will be
  224. supported until April 2020 which almost reaches this date. Django 2.0
  225. officially supports Oracle 12.1+.
  226. Default MySQL isolation level is read committed
  227. -----------------------------------------------
  228. MySQL's default isolation level, repeatable read, may cause data loss in
  229. typical Django usage. To prevent that and for consistency with other databases,
  230. the default isolation level is now read committed. You can use the
  231. :setting:`DATABASES` setting to :ref:`use a different isolation level
  232. <mysql-isolation-level>`, if needed.
  233. :attr:`AbstractUser.last_name <django.contrib.auth.models.User.last_name>` ``max_length`` increased to 150
  234. ----------------------------------------------------------------------------------------------------------
  235. A migration for :attr:`django.contrib.auth.models.User.last_name` is included.
  236. If you have a custom user model inheriting from ``AbstractUser``, you'll need
  237. to generate and apply a database migration for your user model.
  238. If you want to preserve the 30 character limit for last names, use a custom
  239. form::
  240. from django.contrib.auth.forms import UserChangeForm
  241. class MyUserChangeForm(UserChangeForm):
  242. last_name = forms.CharField(max_length=30, required=False)
  243. If you wish to keep this restriction in the admin when editing users, set
  244. ``UserAdmin.form`` to use this form::
  245. from django.contrib.auth.admin import UserAdmin
  246. from django.contrib.auth.models import User
  247. class MyUserAdmin(UserAdmin):
  248. form = MyUserChangeForm
  249. admin.site.unregister(User)
  250. admin.site.register(User, MyUserAdmin)
  251. ``QuerySet.reverse()`` and ``last()`` are prohibited after slicing
  252. ------------------------------------------------------------------
  253. Calling ``QuerySet.reverse()`` or ``last()`` on a sliced queryset leads to
  254. unexpected results due to the slice being applied after reordering. This is
  255. now prohibited, e.g.::
  256. >>> Model.objects.all()[:2].reverse()
  257. Traceback (most recent call last):
  258. ...
  259. TypeError: Cannot reverse a query once a slice has been taken.
  260. Form fields no longer accept optional arguments as positional arguments
  261. -----------------------------------------------------------------------
  262. To help prevent runtime errors due to incorrect ordering of form field
  263. arguments, optional arguments of built-in form fields are no longer accepted
  264. as positional arguments. For example::
  265. forms.IntegerField(25, 10)
  266. raises an exception and should be replaced with::
  267. forms.IntegerField(max_value=25, min_value=10)
  268. ``call_command()`` validates the options it receives
  269. ----------------------------------------------------
  270. ``call_command()`` now validates that the argument parser of the command being
  271. called defines all of the options passed to ``call_command()``.
  272. For custom management commands that use options not created using
  273. ``parser.add_argument()``, add a ``stealth_options`` attribute on the command::
  274. class MyCommand(BaseCommand):
  275. stealth_options = ('option_name', ...)
  276. Miscellaneous
  277. -------------
  278. * The ``SessionAuthenticationMiddleware`` class is removed. It provided no
  279. functionality since session authentication is unconditionally enabled in
  280. Django 1.10.
  281. * The default HTTP error handlers (``handler404``, etc.) are now callables
  282. instead of dotted Python path strings. Django favors callable references
  283. since they provide better performance and debugging experience.
  284. * :class:`~django.views.generic.base.RedirectView` no longer silences
  285. ``NoReverseMatch`` if the ``pattern_name`` doesn't exist.
  286. * When :setting:`USE_L10N` is off, :class:`~django.forms.FloatField` and
  287. :class:`~django.forms.DecimalField` now respect :setting:`DECIMAL_SEPARATOR`
  288. and :setting:`THOUSAND_SEPARATOR` during validation. For example, with the
  289. settings::
  290. USE_L10N = False
  291. USE_THOUSAND_SEPARATOR = True
  292. DECIMAL_SEPARATOR = ','
  293. THOUSAND_SEPARATOR = '.'
  294. an input of ``"1.345"`` is now converted to ``1345`` instead of ``1.345``.
  295. * Subclasses of :class:`~django.contrib.auth.models.AbstractBaseUser` are no
  296. longer required to implement ``get_short_name()`` and ``get_full_name()``.
  297. (The base implementations that raise ``NotImplementedError`` are removed.)
  298. ``django.contrib.admin`` uses these methods if implemented but doesn't
  299. require them. Third-party apps that use these methods may want to adopt a
  300. similar approach.
  301. * The ``FIRST_DAY_OF_WEEK`` and ``NUMBER_GROUPING`` format settings are now
  302. kept as integers in JavaScript and JSON i18n view outputs.
  303. * :meth:`~django.test.TransactionTestCase.assertNumQueries` now ignores
  304. connection configuration queries. Previously, if a test opened a new database
  305. connection, those queries could be included as part of the
  306. ``assertNumQueries()`` count.
  307. * The ``PASSWORD_RESET_TIMEOUT_DAYS`` setting is more properly respected in
  308. ``contrib.auth`` password reset. Previously, resets were allowed for one day
  309. longer than expected. For example, with the default of
  310. ``PASSWORD_RESET_TIMEOUT_DAYS = 3``, password reset tokens are now valid for
  311. 72 hours rather than 96 hours.
  312. * The default size of the Oracle test tablespace is increased from 20M to 50M
  313. and the default autoextend size is increased from 10M to 25M.
  314. * To improve performance when streaming large result sets from the database,
  315. :meth:`.QuerySet.iterator` now fetches 2000 rows at a time instead of 100.
  316. The old behavior can be restored using the ``chunk_size`` parameter. For
  317. example::
  318. Book.objects.iterator(chunk_size=100)
  319. * Providing unknown package names in the ``packages`` argument of the
  320. :class:`~django.views.i18n.JavaScriptCatalog` view now raises ``ValueError``
  321. instead of passing silently.
  322. * A model instance's primary key now appears in the default ``Model.__str__()``
  323. method, e.g. ``Question object (1)``.
  324. * ``makemigrations`` now detects changes to the model field ``limit_choices_to``
  325. option. Add this to your existing migrations or accept an auto-generated
  326. migration for fields that use it.
  327. * Performing queries that require :ref:`automatic spatial transformations
  328. <automatic-spatial-transformations>` now raises ``NotImplementedError``
  329. on MySQL instead of silently using non-transformed geometries.
  330. .. _deprecated-features-2.0:
  331. Features deprecated in 2.0
  332. ==========================
  333. Miscellaneous
  334. -------------
  335. * The ``django.db.backends.postgresql_psycopg2`` module is deprecated in favor
  336. of ``django.db.backends.postgresql``. It's been an alias since Django 1.9.
  337. This only affects code that imports from the module directly. The
  338. ``DATABASES`` setting can still use
  339. ``'django.db.backends.postgresql_psycopg2'``, though you can simplify that by
  340. using the ``'django.db.backends.postgresql'`` name added in Django 1.9.
  341. * ``django.shortcuts.render_to_response()`` is deprecated in favor of
  342. :func:`django.shortcuts.render`. ``render()`` takes the same arguments
  343. except that is also requires a ``request``.
  344. * The ``DEFAULT_CONTENT_TYPE`` setting is deprecated. It doesn't interact well
  345. well with third-party apps and is obsolete since HTML5 has mostly superseded
  346. XHTML.
  347. * ``HttpRequest.xreadlines()`` is deprecated in favor of iterating over the
  348. request.
  349. .. _removed-features-2.0:
  350. Features removed in 2.0
  351. =======================
  352. These features have reached the end of their deprecation cycle and are removed
  353. in Django 2.0. See :ref:`deprecated-features-1.9` and
  354. :ref:`deprecated-features-1.10` for details, including how to remove usage of
  355. these features.
  356. * The ``weak`` argument to ``django.dispatch.signals.Signal.disconnect()`` is
  357. removed.
  358. * ``django.db.backends.base.BaseDatabaseOperations.check_aggregate_support()``
  359. is removed.
  360. * The ``django.forms.extras`` package is removed.
  361. * The ``assignment_tag`` helper is removed.
  362. * The ``host`` argument to ``SimpleTestCase.assertsRedirects()`` is removed.
  363. The compatibility layer which allows absolute URLs to be considered equal to
  364. relative ones when the path is identical is also removed.
  365. * ``Field.rel`` and ``Field.remote_field.to`` are removed.
  366. * The ``on_delete`` argument for ``ForeignKey`` and ``OneToOneField`` are now
  367. required.
  368. * ``django.db.models.fields.add_lazy_relation()`` is removed.
  369. * When time zone support is enabled, database backends that don't support time
  370. zones no longer convert aware datetimes to naive values in UTC anymore when
  371. such values are passed as parameters to SQL queries executed outside of the
  372. ORM, e.g. with ``cursor.execute()``.
  373. * ``django.contrib.auth.tests.utils.skipIfCustomUser()`` is removed.
  374. * The ``GeoManager`` and ``GeoQuerySet`` classes are removed.
  375. * The ``django.contrib.gis.geoip`` module is removed.
  376. * The ``supports_recursion`` check for template loaders is removed from:
  377. * ``django.template.engine.Engine.find_template()``
  378. * ``django.template.loader_tags.ExtendsNode.find_template()``
  379. * ``django.template.loaders.base.Loader.supports_recursion()``
  380. * ``django.template.loaders.cached.Loader.supports_recursion()``
  381. * The ``load_template`` and ``load_template_sources`` template loader methods
  382. are removed.
  383. * The ``template_dirs`` argument for template loaders is removed:
  384. * ``django.template.loaders.base.Loader.get_template()``
  385. * ``django.template.loaders.cached.Loader.cache_key()``
  386. * ``django.template.loaders.cached.Loader.get_template()``
  387. * ``django.template.loaders.cached.Loader.get_template_sources()``
  388. * ``django.template.loaders.filesystem.Loader.get_template_sources()``
  389. * ``django.template.loaders.base.Loader.__call__()`` is removed.
  390. * Support for custom error views that don't accept an ``exception`` parameter
  391. is removed.
  392. * The ``mime_type`` attribute of ``django.utils.feedgenerator.Atom1Feed`` and
  393. ``django.utils.feedgenerator.RssFeed`` is removed.
  394. * The ``app_name`` argument to ``include()`` is removed.
  395. * Support for passing a 3-tuple (including ``admin.site.urls``) as the first
  396. argument to ``include()`` is removed.
  397. * Support for setting a URL instance namespace without an application namespace
  398. is removed.
  399. * ``Field._get_val_from_obj()`` is removed.
  400. * ``django.template.loaders.eggs.Loader`` is removed.
  401. * The ``current_app`` parameter to the ``contrib.auth`` function-based views is
  402. removed.
  403. * The ``callable_obj`` keyword argument to
  404. ``SimpleTestCase.assertRaisesMessage()`` is removed.
  405. * Support for the ``allow_tags`` attribute on ``ModelAdmin`` methods is
  406. removed.
  407. * The ``enclosure`` keyword argument to ``SyndicationFeed.add_item()`` is
  408. removed.
  409. * The ``django.template.loader.LoaderOrigin`` and
  410. ``django.template.base.StringOrigin`` aliases for
  411. ``django.template.base.Origin`` are removed.
  412. * The ``makemigrations --exit`` option is removed.
  413. * Support for direct assignment to a reverse foreign key or many-to-many
  414. relation is removed.
  415. * The ``get_srid()`` and ``set_srid()`` methods of
  416. ``django.contrib.gis.geos.GEOSGeometry`` are removed.
  417. * The ``get_x()``, ``set_x()``, ``get_y()``, ``set_y()``, ``get_z()``, and
  418. ``set_z()`` methods of ``django.contrib.gis.geos.Point`` are removed.
  419. * The ``get_coords()`` and ``set_coords()`` methods of
  420. ``django.contrib.gis.geos.Point`` are removed.
  421. * The ``cascaded_union`` property of ``django.contrib.gis.geos.MultiPolygon``
  422. is removed.
  423. * ``django.utils.functional.allow_lazy()`` is removed.
  424. * The ``shell --plain`` option is removed.
  425. * The ``django.core.urlresolvers`` module is removed.
  426. * ``CommaSeparatedIntegerField`` is removed, except for support in historical
  427. migrations.
  428. * The template ``Context.has_key()`` method is removed.
  429. * Support for the ``django.core.files.storage.Storage.accessed_time()``,
  430. ``created_time()``, and ``modified_time()`` methods is removed.
  431. * Support for query lookups using the model name when
  432. ``Meta.default_related_name`` is set is removed.
  433. * The MySQL ``__search`` lookup is removed.
  434. * The shim for supporting custom related manager classes without a
  435. ``_apply_rel_filters()`` method is removed.
  436. * Using ``User.is_authenticated()`` and ``User.is_anonymous()`` as methods
  437. rather than properties is no longer supported.
  438. * The ``Model._meta.virtual_fields`` attribute is removed.
  439. * The keyword arguments ``virtual_only`` in ``Field.contribute_to_class()`` and
  440. ``virtual`` in ``Model._meta.add_field()`` are removed.
  441. * The ``javascript_catalog()`` and ``json_catalog()`` views are removed.
  442. * ``django.contrib.gis.utils.precision_wkt()`` is removed.
  443. * In multi-table inheritance, implicit promotion of a ``OneToOneField`` to a
  444. ``parent_link`` is removed.
  445. * Support for ``Widget._format_value()`` is removed.
  446. * ``FileField`` methods ``get_directory_name()`` and ``get_filename()`` are
  447. removed.
  448. * The ``mark_for_escaping()`` function and the classes it uses: ``EscapeData``,
  449. ``EscapeBytes``, ``EscapeText``, ``EscapeString``, and ``EscapeUnicode`` are
  450. removed.
  451. * The ``escape`` filter now uses ``django.utils.html.conditional_escape()``.
  452. * ``Manager.use_for_related_fields`` is removed.
  453. * Model ``Manager`` inheritance follows MRO inheritance rules. The requirement
  454. to use ``Meta.manager_inheritance_from_future`` to opt-in to the behavior is
  455. removed.
  456. * Support for old-style middleware using ``settings.MIDDLEWARE_CLASSES`` is
  457. removed.