Fixed #30024 -- Made urlencode() and Client raise TypeError when None is passed as data.

This commit is contained in:
Jon Dufresne 2018-12-27 11:19:55 -05:00 committed by Tim Graham
parent 293db9eb36
commit 6fe9c45b72
5 changed files with 64 additions and 8 deletions

View file

@ -457,6 +457,11 @@ Miscellaneous
* Tests that violate deferrable database constraints now error when run on
SQLite 3.20+, just like on other backends that support such constraints.
* To catch usage mistakes, the test :class:`~django.test.Client` and
:func:`django.utils.http.urlencode` now raise ``TypeError`` if ``None`` is
passed as a value to encode because ``None`` can't be encoded in GET and POST
data. Either pass an empty string or omit the value.
.. _deprecated-features-2.2:
Features deprecated in 2.2