April 2, 2025 » Simon Willison's Weblog: django » [Archived Version]
Composite primary keys in Django Django 5.2 is out today and a big new feature is composite primary keys, which can now be defined like this: class Release(models.Model): pk = models.CompositePrimaryKey( "version", "name" ) version = models.IntegerField() name = models.CharField(max_length=20) They don't yet work with the Django admin or as targets for foreign keys. Other smaller new features include: All ORM models are now automatically imported into ./manage.py shell…
Read MoreApril 2, 2025 » The Django weblog » [Archived Version]
The Django team is happy to announce the release of Django 5.2. The release notes showcase a composite of new features. A few highlights are: All models are automatically imported in the shell by default. Django now supports composite primary keys! The new django.db.models.CompositePrimaryKey allows tables to be created with a primary key consisting of multiple fields. Overriding a BoundField got a lot easier: this can now be set on a form, field or project level. You can get Django 5.2 from …
Read MoreApril 2, 2025 » The Django weblog » [Archived Version]
In accordance with our security release policy, the Django team is issuing releases for Django 5.1.8 and Django 5.0.14. These releases address the security issues detailed below. We encourage all users of Django to upgrade as soon as possible. CVE-2025-27556: Potential denial-of-service vulnerability in LoginView, LogoutView, and set_language() on Windows Python's NFKC normalization is slow on Windows. As a consequence, django.contrib.auth.views.LoginView, django.contrib.auth.views.LogoutView,…
Read MoreApril 2, 2025 » Better Simple » [Archived Version]
DjangoCon US 2025 is accepting talk proposals for a few more weeks. If folks are on the fence about submitting a talk, here are some ideas that I would personally be interested in.
Read MoreMarch 29, 2025 » james.walters.click » [Archived Version]
There's a post that's a couple of years old called "Any updates?". I saw it recently in Django News, but I think I've seen it before. It basically discourages you from commenting on GitHub Issues with "Any updates?" since 1) if there were any, they would be in the issue …
Read MoreMarch 28, 2025 » Django News » [Archived Version]
Updates to Django Today 'Updates to Django' is presented by Abigail Afi Gbadago from the DSF Board and Djangonaut Space!🚀 Last week we had 20 pull requests merged into Django by 14 different contributors - including 4 first-time contributors! Congratulations to mguegnol, YQ, Filip Owczarek and Ahmed Nassar for having their first commits merged into Django - welcome on board!🥳 This week’s Django highlights: The environment variable HIDE_PRODUCTION_WARNING has been cha…
Read MoreMarch 21, 2025 » Django News » [Archived Version]
News Django 5.2 release candidate 1 released The final opportunity for you to try out a composite of new features before Django 5.2 is released. djangoproject.com Python 3.14.0a6 Release Python 3.14.0a6 alpha (Pi Day release) introduces deferred annotation evaluation and improved interpreter performance, offering potential efficiency gains for Django-based projects. python.org Discussion #154262: Ability to make Gi…
Read MoreMarch 21, 2025 » Django on Matt Layman » [Archived Version]
In this episode, I updated my new onboarding form on the School Desk app. This form is vital for the first experience of new users, so I spent a lot of time making sure it will do what is needed.
Read MoreMarch 19, 2025 » The Django weblog » [Archived Version]
Django 5.2 release candidate 1 is the final opportunity for you to try out a composite of new features before Django 5.2 is released. The release candidate stage marks the string freeze and the call for translators to submit translations. Provided no major bugs are discovered that can't be solved in the next two weeks, Django 5.2 will be released on or around April 2. Any delays will be communicated on the on the Django forum. Please use this opportunity to help find and fix bugs (which should…
Read MoreMarch 19, 2025 » Better Simple » [Archived Version]
When removing multi-table inheritance in Django, you need to remove your Model's bases from the migration's model state. This post goes into detail on when this comes up and how to resolve it.
Read More