Headline changes
-
mypy 1.6: Recommended mypy version updated to 1.6.x
-
Next djangorestframework-stubs version (3.14.5) will remove direct mypy dependency. If you are using mypy, please add an explicit
mypy
dev dependency to your project, or install djangorestframework-stubs with the extradjangorestframework-stubs[compatible-mypy]
.Mypy remains the only supported type checker. Improvements for other type checkers may be considered in the future, pull requests welcome. See #1628 for details.
-
We have now adopted mypy's stubtest to automatically find discrepancies between Django REST Framework and djangorestframework-stubs.
If you want to contribute but are not sure where to start, have a look at stubtest's TODO list file, which lists the many issues discovered by stubtest.
-
Officially added Python 3.12 support
Stubs fixes
- Allow
None
forHyperlinkedRelatedField.get_url(format=)
parameter by @4c0n in #485 - Allow
None
forPagination.template
attribute by @intgr in #482
Stubs improvements
- Fill remaining missing hints & disallow partial hints by @intgr in #480
This improved type hints all over the place.
Housekeeping
- Migrate from flake8 to ruff by @intgr in #488
- Harmonize
mypy.ini
config with django-stubs by @intgr in #479 - CI: Enable testing with Python 3.12 by @intgr in #478
- Update mypy requirement from ==1.5.* to ~=1.6.0 by @dependabot in #484
- Initial stubtest testing with autogenerated allowlist by @intgr in #493
- Cleanup: Add missing
None
return to__init__
methods by @intgr in #492 - Version 3.14.4 release by @intgr in #494
New Contributors
Full Changelog: 3.14.3...3.14.4