{"title":"Django 5.2.4 release notes","version":"dev","locale":"en","docname":"releases/5.2.4","url":"/en/dev/releases/5.2.4/","canonical":"https://djangodocs.dev/en/dev/releases/5.2.4/","summary":"Django 5.2.4 fixes several bugs in 5.2.3. Fixed a regression in Django 5.2.2 where HttpRequest.get_preferred_type() incorrectly preferred more specific…","html":"<h1>Django 5.2.4 release notes<a class=\"heading-anchor\" href=\"#django-5-2-4-release-notes\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h1>\n<p><em>July 2, 2025</em></p>\n<p>Django 5.2.4 fixes several bugs in 5.2.3.</p>\n<section id=\"bugfixes\">\n<h2>Bugfixes<a class=\"heading-anchor\" href=\"#bugfixes\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h2>\n<ul class=\"simple\">\n<li><p>Fixed a regression in Django 5.2.2 where\n<a class=\"reference internal\" href=\"/en/dev/ref/request-response/#django.http.HttpRequest.get_preferred_type\" title=\"django.http.HttpRequest.get_preferred_type\"><code class=\"xref py py-meth docutils literal notranslate\">HttpRequest.get_preferred_type()</code></a>\nincorrectly preferred more specific media types with a lower quality\n(<a class=\"extlink-ticket reference external\" href=\"https://code.djangoproject.com/ticket/36447\">#36447</a>).</p></li>\n<li><p>Fixed a regression in Django 5.2.3 where <code class=\"docutils literal notranslate\">Value(None, JSONField())</code> used in\na <a class=\"reference internal\" href=\"/en/dev/ref/models/conditional-expressions/#django.db.models.expressions.When\" title=\"django.db.models.expressions.When\"><code class=\"xref py py-class docutils literal notranslate\">When</code></a> condition was incorrectly\nserialized as SQL <code class=\"docutils literal notranslate\">NULL</code> instead of JSON <code class=\"docutils literal notranslate\">null</code> (<a class=\"extlink-ticket reference external\" href=\"https://code.djangoproject.com/ticket/36453\">#36453</a>).</p></li>\n<li><p>Fixed a crash in Django 5.2 when performing an <code class=\"docutils literal notranslate\">__in</code> lookup involving a\ncomposite primary key and a subquery on backends that lack native support for\ntuple lookups (<a class=\"extlink-ticket reference external\" href=\"https://code.djangoproject.com/ticket/36464\">#36464</a>).</p></li>\n</ul>\n</section>","rootId":"django-5-2-4-release-notes","toc":[{"title":"Bugfixes","anchor":"bugfixes","children":[]}],"breadcrumbs":[{"docname":"releases/index","title":"Release notes","url":"/en/dev/releases/"}],"prev":{"docname":"releases/5.2.5","title":"Django 5.2.5 release notes","url":"/en/dev/releases/5.2.5/"},"next":{"docname":"releases/5.2.3","title":"Django 5.2.3 release notes","url":"/en/dev/releases/5.2.3/"},"formats":{"html":"/en/dev/releases/5.2.4/","markdown":"/en/dev/releases/5.2.4.md","json":"/en/dev/releases/5.2.4.json"},"source":"https://github.com/django/django/blob/main/docs/releases/5.2.4.txt","official":"https://docs.djangoproject.com/en/dev/releases/5.2.4/","inVersions":["dev","6.1","6.0","5.2"],"inLocales":["en"]}