Paul Krill
Editor at Large

Django 5.2 release touts automatic model importing

news
Apr 2, 20252 mins
DjangoPythonWeb Development

Users are asked to update to this latest version of the Python web framework, as support is phasing out for earlier 5.x versions.

Person at laptop keyboard shown updating software.
Credit: A9 STUDIO / Shutterstock

The latest version of the Python web framework features an automatic model-importing capability in the shell. ย This release also spells the end of support levels for previous version 5.x releases.

Unveiled April 2 by the Django Software Foundation, the Django 5.2 release supports Python versions 3.10 to 3.13. This latest release features a shell management command that automatically imports models from all installed apps, with the behavior customizable to add or remove automatic imports. Additionally, support is offered for composite primary keys, and a new django.db.models.CompositePrimaryKey allows the creation of tables with a primary key consisting of multiple fields.

The Django update also makes it easier to override a BoundField update, since this now can be set to a form, field, or project level. ย Elsewhere in Django 5.2, the admin/base.html template now offers a new block extrabody for adding custom code before the closing </body> tag. Details for accessing Django can be found at djangoproject.com.

The release of Django 5.2 means that Django 5.1 has reached the end of mainstream support. A final minor bug release, version 5.1.8, which also was a security release, was issued on April 2. Django 5.1 will receive fixes for security and data losses until December 2025. Users are encouraged to upgrade before then. Django 5.0, meanwhile, has reached the end of extended support. A final security release, also issued on April 2, was labeled release 5.0.14. Django 6.0 is due in early 2026.

Paul Krill

Paul Krill is editor at large at InfoWorld. Paul has been covering computer technology as a news and feature reporter for more than 35 years, including 30 years at InfoWorld. He has specialized in coverage of software development tools and technologies since the 1990s, and he continues to lead InfoWorldโ€™s news coverage of software development platforms including Java and .NET and programming languages including JavaScript, TypeScript, PHP, Python, Ruby, Rust, and Go. Long trusted as a reporter who prioritizes accuracy, integrity, and the best interests of readers, Paul is sought out by technology companies and industry organizations who want to reach InfoWorldโ€™s audience of software developers and other information technology professionals. Paul has won a โ€œBest Technology News Coverageโ€ award from IDG.

More from this author