This is the last release with Django 6.0 full support.
The next release will be focused on Django 6.1 support with Django 6.0 partial support.
What's Changed
- Add type arguments to generic references in
contrib.gisby @UnknownPlatypus in #3500 - Implicit M2M through models lose their
objects/_default_managerattributes by @UnknownPlatypus in #3499 - Resolve dynamic manager methods via mypy's
find_memberby @UnknownPlatypus in #3501 - Add type arguments to generic references in
db.models,coreandmigrationsby @UnknownPlatypus in #3504 - Allow callables returning Choices type for Field.choices. by @felixxm in #3506
- Add type arguments to generic references in
core,apps,urlsandadmindocsby @UnknownPlatypus in #3503 - Improve type in
formsand improve types of lazy regexes by @01xnikhil in #3293 - Add type arguments to generic references in
django.tasksby @UnknownPlatypus in #3512 - Add plugin support for
apps.get_model()by @UnknownPlatypus in #3511 - Add type arguments to generic references in admin filters, utils and per-app admins by @UnknownPlatypus in #3502
- Invalidate mypy cache when
settings.INSTALLED_APPSchange and cache full config computation by @UnknownPlatypus in #3514 - Mark fullnames constants as Final by @UnknownPlatypus in #3515
- Add type arguments to generic references in
utilsandtemplatesby @UnknownPlatypus in #3513 - Use mypy's
lookup_fully_qualifiedinstead of custom symbol lookup by @UnknownPlatypus in #3519 - Detect form base classes with
has_baseinstead of a metadata registry by @UnknownPlatypus in #3520 - Type args files contenttypes by @UnknownPlatypus in #3523
- Add helper to generate synthetic manager/queryset classes by @UnknownPlatypus in #3518
- Add type arguments to generic
Field's by @UnknownPlatypus in #3522 - Type admin site as DefaultAdminSite inheriting from Adminsite by @ahmedasar00 in #3296
- Declare fields of
LogEntry,FlatPageandRedirectas assignments by @UnknownPlatypus in #3524 - Validate
distinct/update/in_bulkby @UnknownPlatypus in #3168 - Ensure ORM expressions return params as a tuple by @ngnpope in #3527
- Improve comment for attributes added by model metaclass by @ngnpope in #3529
- Improved typing of the checks framework by @ngnpope in #3528
- Use typeshed aliases where possible by @ngnpope in #3533
- Fix GIS as_sql stub signatures to match runtime by @ahmedasar00 in #3212
- Make
View,TemplateView, andTemplateResponseMixingeneric on response type by @samueljsb in #2874 - Add attributes set by application/middleware to
HttpRequestby @bigfootjon in #2239 - Disallow any generics in our stubs & plugin by @UnknownPlatypus in #3535
- Change test Client headers parameter to Mapping[str, str] by @intgr in #1534
- Fix ngettext/npgettext number parameter type mismatch by @usamashehab in #3477
- Fix middleware callable composition typing by @yassinbahri in #3538
- Allow all supported types in GeneratedField.choices. by @felixxm in #3541
- Deduplicate the through-table manager additions into a loop by @UnknownPlatypus in #3544
- Make the narrowed response type of
TemplateViewopt-in by @UnknownPlatypus in #3543 - State
pyrefly/pyright/tybasic support by @sobolevn in #3562
New Contributors
- @felixxm made their first contribution in #3506
- @usamashehab made their first contribution in #3477
- @yassinbahri made their first contribution in #3538
Full Changelog: 6.0.7...6.0.8