djangodocs.org

766 sections in Django dev Search all versions →

Bugfixes

Release notes Django 1.8.7 release notes

Fixed a regression in 1.8.6 by restoring the ability to use Manager objects for the queryset argument of ModelChoiceField (#25683). Fixed a regression in 1.8.6 that caused an application with South migrations in the migrations directory to fail (#25618).

Bugfixes

Release notes Django 1.9.1 release notes

Prevented QuerySet.delete() from crashing on MySQL when querying across relations (#25882). Fixed evaluation of zero-length slices of QuerySet.values() (#25894). Fixed a state bug when using an AlterModelManagers operation (#25852). Fixed TypedChoiceField change detection with nullable fields (#25942).

Models

Release notes Django 2.0 release notes What’s new in Django 2.0Minor features

On Oracle, AutoField and BigAutoField are now created as identity columns. The new chunk_size parameter of QuerySet.iterator() controls the number of rows fetched by the Python database client when streaming results from the database.

Miscellaneous

Release notes Django 2.0 release notes Features deprecated in 2.0

HttpRequest.xreadlines() is deprecated in favor of iterating over the request. The field_name keyword argument to QuerySet.earliest() and QuerySet.latest() is deprecated in favor of passing the field names as arguments. Write .earliest('pub_date') instead of .earliest(field_name='pub_date').

Bugfixes

Release notes Django 2.0.1 release notes

Reallowed filtering a queryset with GeometryField=None (#28896). Corrected admin check to allow a OneToOneField in ModelAdmin.autocomplete_fields (#28898). Fixed a regression on SQLite where DecimalField returned a result with trailing zeros in the fractional part truncated (#28915).

Bugfixes

Release notes Django 2.0.2 release notes

Fixed regression in the use of QuerySet.values_list(..., flat=True) followed by annotate() (#29067). Fixed a regression where a queryset that annotates with geometry objects crashes (#29054).

Bugfixes

Release notes Django 2.0.5 release notes

Fixed a regression in Django 2.0.4 where QuerySet.values() or values_list() after combining an annotated and unannotated queryset with union(), difference(), or intersection() crashed due to mismatching columns (#29286).

Models

Release notes Django 2.2 release notes What’s new in Django 2.2Minor features

Added the NullIf and Reverse database functions, as well as many math database functions. Setting the new ignore_conflicts parameter of QuerySet.bulk_create() to True tells the database to ignore failure to insert rows that fail uniqueness constraints or other checks.

Bugfixes

Release notes Django 2.2.1 release notes

Fixed a regression in Django 2.2 where Paginator crashes if object_list is a queryset ordered or aggregated over a nested JSONField key transform (#30335).

Bugfixes

Release notes Django 2.2.8 release notes

Fixed a data loss possibility in the select_for_update(). When using 'self' in the of argument with multi-table inheritance, a parent model was locked instead of the queryset’s model (#30953).

Release notes Django 3.0 release notes Backwards incompatible changes in 3.0

Attempts to use a new Model instance to update an existing row will result in an IntegrityError. In order to update an existing model for a specific primary key value, use the update_or_create() method or QuerySet.filter(pk=…).update(…) instead. For example:

Features removed in 3.0

Release notes Django 3.0 release notes

The field_name keyword argument of QuerySet.earliest() and latest() is removed. See Features deprecated in 2.1 for details on these changes, including how to remove usage of these features. The ForceRHR GIS function is removed. django.utils.http.cookie_date() is removed.

Bugfixes

Release notes Django 3.0.1 release notes

Reallowed, following a regression in Django 3.0, Window expressions to be used in conditions outside of queryset filters, e.g. in When conditions (#31060). Fixed a data loss possibility in SplitArrayField.

Bugfixes

Release notes Django 3.1.1 release notes

Reverted a deprecation in Django 3.1 that caused a crash when passing deprecated keyword arguments to a queryset in TemplateView.get_context_data() (#31877). Enforced thread sensitivity of the MiddlewareMixin.process_request() and process_response() hooks when in an async context (#31905).

Bugfixes

Release notes Django 3.1.4 release notes

Fixed a regression in Django 3.1 that caused suppressing connection errors when JSONField is used on SQLite (#32224). Fixed a crash on SQLite, when QuerySet.values()/values_list() contained key transforms for JSONField returning non-string primitive values (#32203).

Miscellaneous

Release notes Django 3.2 release notes Features deprecated in 3.2

See What’s new in Django 3.2 for more details. Automatically calling repr() on a queryset in TransactionTestCase.assertQuerysetEqual(), when compared to string values, is deprecated. If you need the previous behavior, explicitly set transform to repr.

Bugfixes

Release notes Django 3.2.1 release notes

Fixed a regression in Django 3.2 that caused a crash of QuerySet.values()/values_list() after QuerySet.union(), intersection(), and difference() when it was ordered by an unannotated field (#32627).

Miscellaneous

Release notes Django 4.0 release notes Features deprecated in 4.0

Unsupported operations on a sliced queryset now raise TypeError instead of AssertionError. The undocumented django.test.runner.reorder_suite() function is renamed to reorder_tests(). It now accepts an iterable of tests rather than a test suite, and returns an iterator of tests.