Skip to content

Update django-stubs to 5.2.0 #5804

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

pyup-bot
Copy link
Collaborator

This PR updates django-stubs[compatible-mypy] from 5.1.3 to 5.2.0.

Changelog

5.2.0

Important changes

- We now support Django5.2 LTS release!
- Partial Django support is moved to 5.0 from 4.2
- We now also run all checks in this repo under `mypy --strict` mode
- Minimal `mypy` version is update to `1.13`

What's Changed

* fix `format_lazy` typing by ashm-dev in https://github.com/typeddjango/django-stubs/pull/2504
* Update models's fields' `_Choices` type by stianjensen in https://github.com/typeddjango/django-stubs/pull/2476
* fix: Add `context_data` attribute to _MonkeyPatchedW/ASGIResponse. by PacificGilly in https://github.com/typeddjango/django-stubs/pull/2509
* Fix id and pk of AnonymousUser by stickperson in https://github.com/typeddjango/django-stubs/pull/2515
* Add docs about "`type[Model]` does not have `objects` attribute" by sobolevn in https://github.com/typeddjango/django-stubs/pull/2519
* Update `db.migrations.operations` by Viicos in https://github.com/typeddjango/django-stubs/pull/2349
* Add `select_format()` methods by adamchainz in https://github.com/typeddjango/django-stubs/pull/2525
* Tidy `django.conf.urls` by adamchainz in https://github.com/typeddjango/django-stubs/pull/2528
* Fix `Func.function` by adamchainz in https://github.com/typeddjango/django-stubs/pull/2529
* Add `ClassVar` annotations on mutable `ModelAdmin` types for `ruff` by zyv in https://github.com/typeddjango/django-stubs/pull/2524
* Add `ClassVar` annotations on `Migration` class attributes by zyv in https://github.com/typeddjango/django-stubs/pull/2530
* Remove insecure password hashers by adamchainz in https://github.com/typeddjango/django-stubs/pull/2537
* Update for Model.[a]save() signature change by adamchainz in https://github.com/typeddjango/django-stubs/pull/2535
* Update TestCase classes for Django 5.1 by adamchainz in https://github.com/typeddjango/django-stubs/pull/2540
* Improve admin decorators by adamchainz in https://github.com/typeddjango/django-stubs/pull/2538
* Update for template system checks change by adamchainz in https://github.com/typeddjango/django-stubs/pull/2536
* Remove ForeignObjectRel.is_hidden() by adamchainz in https://github.com/typeddjango/django-stubs/pull/2539
* Correct Field.slice_expression() 'length' argument name. by adamchainz in https://github.com/typeddjango/django-stubs/pull/2548
* Update django.urls for Django 5.1 by adamchainz in https://github.com/typeddjango/django-stubs/pull/2546
* Update django.db.models.options.Options for Django 5.1 by adamchainz in https://github.com/typeddjango/django-stubs/pull/2545
* Add admin is_collapsible() methods by adamchainz in https://github.com/typeddjango/django-stubs/pull/2541
* Update django.template for Django 5.1 by adamchainz in https://github.com/typeddjango/django-stubs/pull/2543
* Add new system checks from Django 5.1 by adamchainz in https://github.com/typeddjango/django-stubs/pull/2542
* Add full signatures to CheckConstraint.__init__ overloads by adamchainz in https://github.com/typeddjango/django-stubs/pull/2544
* Make Model.[a]save() keyword-only by adamchainz in https://github.com/typeddjango/django-stubs/pull/2550
* Add query_params argument to test tools from Django 5.1 by adamchainz in https://github.com/typeddjango/django-stubs/pull/2547
* fix 2552 by add ModelIterable to _need_generic by lucemia in https://github.com/typeddjango/django-stubs/pull/2553
* Add window frame exclusion from Django 5.1 by adamchainz in https://github.com/typeddjango/django-stubs/pull/2554
* Improve process_view() methods by adamchainz in https://github.com/typeddjango/django-stubs/pull/2556
* Update core.files.storages for Django 5.1 by adamchainz in https://github.com/typeddjango/django-stubs/pull/2558
* Update contrib.auth for Django 5.1 by adamchainz in https://github.com/typeddjango/django-stubs/pull/2555
* Complete JSONObject by adamchainz in https://github.com/typeddjango/django-stubs/pull/2560
* Fix FieldCacheMixin.cache_name by adamchainz in https://github.com/typeddjango/django-stubs/pull/2562
* Use AbstractContextManager instead of `contextmanager` by adamchainz in https://github.com/typeddjango/django-stubs/pull/2561
* Add ModelForm.declared_fields by adamchainz in https://github.com/typeddjango/django-stubs/pull/2557
* Update test.selenium for Django 5.1 by adamchainz in https://github.com/typeddjango/django-stubs/pull/2559
* Update database expressions for Django 5.1 by adamchainz in https://github.com/typeddjango/django-stubs/pull/2563
* fixed typing in contrib.auth.decorators by Rusich90 in https://github.com/typeddjango/django-stubs/pull/2564
* Update `_Choices` type for forms by mrgalopes in https://github.com/typeddjango/django-stubs/pull/2565
* Update some database backend attributes for Django 5.1 by adamchainz in https://github.com/typeddjango/django-stubs/pull/2567
* Update PostgreSQL backend `is_postgresql_*` properties for Django 5.1 by adamchainz in https://github.com/typeddjango/django-stubs/pull/2566
* Remove unused code from the plugin by ngnpope in https://github.com/typeddjango/django-stubs/pull/2570
* Add `db_table_comment` to model meta by ngnpope in https://github.com/typeddjango/django-stubs/pull/2571
* Fix `BaseModelAdmin.get_inlines()` return type by MaestroXXXVIII in https://github.com/typeddjango/django-stubs/pull/2576
* Fix a few typos by UnknownPlatypus in https://github.com/typeddjango/django-stubs/pull/2579
* Document custom field typing by UnknownPlatypus in https://github.com/typeddjango/django-stubs/pull/2578
* Improve stubs for `flatten` and `flatten_fieldsets` by ngnpope in https://github.com/typeddjango/django-stubs/pull/2572
* Improve typing of choices by ngnpope in https://github.com/typeddjango/django-stubs/pull/2582
* Run tests in parallel by UnknownPlatypus in https://github.com/typeddjango/django-stubs/pull/2580
* Make GeneratedField parameter db_persist required by JasonLovesDoggo in https://github.com/typeddjango/django-stubs/pull/2568
* Re-add explicit test cache disabling by UnknownPlatypus in https://github.com/typeddjango/django-stubs/pull/2589
* Ignore `__slotnames__` by adamchainz in https://github.com/typeddjango/django-stubs/pull/2584
* Update a bunch of stuff for Django 5.1 by adamchainz in https://github.com/typeddjango/django-stubs/pull/2585
* Add get_refs() to BaseExpression and WhereNode by adamchainz in https://github.com/typeddjango/django-stubs/pull/2586
* Update Django 4.2 LTS version to 4.2.20 by intgr in https://github.com/typeddjango/django-stubs/pull/2592
* Allow tuples for some `TypedModelMeta` fields by ngnpope in https://github.com/typeddjango/django-stubs/pull/2594
* Update `django.contrib.gis.geoip2` stubs by ngnpope in https://github.com/typeddjango/django-stubs/pull/2593
* Update django to 5.2 by sobolevn in https://github.com/typeddjango/django-stubs/pull/2596
* Fix django.urls.base.reverse after 5.2 by simwr872 in https://github.com/typeddjango/django-stubs/pull/2595
* Update `django.core.validators` for Django 5.2 by JaeHyuckSa in https://github.com/typeddjango/django-stubs/pull/2598
* Update `django.test.client` and `django.utils` for Django 5.2 by JaeHyuckSa in https://github.com/typeddjango/django-stubs/pull/2599
* Update `django.contrib.auth.backends` for Django 5.2 by JaeHyuckSa in https://github.com/typeddjango/django-stubs/pull/2600
* Update `django.contrib.auth.models` for Django 5.2 by JaeHyuckSa in https://github.com/typeddjango/django-stubs/pull/2601
* Allow `MutableMapping` for `Form.Initial` by UnknownPlatypus in https://github.com/typeddjango/django-stubs/pull/2604
* Update `django.contrib.admin` for Django 5.2 by JaeHyuckSa in https://github.com/typeddjango/django-stubs/pull/2607
* Update `django.db.models.sql` for Django 5.2 by JaeHyuckSa in https://github.com/typeddjango/django-stubs/pull/2606
* Update `django.forms.widgets` for Django 5.2 by federicobond in https://github.com/typeddjango/django-stubs/pull/2608
* create and re-use `TypeAlias`es and `TypeVar`s for "user" and "any user" by terencehonles in https://github.com/typeddjango/django-stubs/pull/2384
* Update `django.contrib` for Django 5.2 by JaeHyuckSa in https://github.com/typeddjango/django-stubs/pull/2611
* Add stub for `get_select2_language` from `django.contrib.admin.widgets` by michalpokusa in https://github.com/typeddjango/django-stubs/pull/2612
* Update `django.core.management.commands` for Django 5.2 by JaeHyuckSa in https://github.com/typeddjango/django-stubs/pull/2613
* Restrict setuptools to `<79.0.0` for `SETUPTOOLS_ENABLE_FEATURES=legacy-editable` to work by michalpokusa in https://github.com/typeddjango/django-stubs/pull/2617
* Add EmailMultiAlternatives.body_contains() by cuu508 in https://github.com/typeddjango/django-stubs/pull/2618
* Add HttpResponse.text by cuu508 in https://github.com/typeddjango/django-stubs/pull/2622
* Allow tuples for some `Options` fields by ngnpope in https://github.com/typeddjango/django-stubs/pull/2627
* Add `__all__` by donBarbos in https://github.com/typeddjango/django-stubs/pull/2624
* Fix some django 5.2 new missing parameters by sobolevn in https://github.com/typeddjango/django-stubs/pull/2629
* [5.2] Improve `django.http.request.MediaType` by sobolevn in https://github.com/typeddjango/django-stubs/pull/2631
* [5.2] Fix new errors in `django.http` module by sobolevn in https://github.com/typeddjango/django-stubs/pull/2632
* [5.2] Fix `django.template.library` by sobolevn in https://github.com/typeddjango/django-stubs/pull/2633
* Update `django.core.serializers` for Django 5.2 by JaeHyuckSa in https://github.com/typeddjango/django-stubs/pull/2614
* Update contrib.gis for Django 5.1 by adamchainz in https://github.com/typeddjango/django-stubs/pull/2587
* Update some field attributes for Django 5.1 by adamchainz in https://github.com/typeddjango/django-stubs/pull/2583

New Contributors
* stianjensen made their first contribution in https://github.com/typeddjango/django-stubs/pull/2476
* PacificGilly made their first contribution in https://github.com/typeddjango/django-stubs/pull/2509
* stickperson made their first contribution in https://github.com/typeddjango/django-stubs/pull/2515
* zyv made their first contribution in https://github.com/typeddjango/django-stubs/pull/2524
* lucemia made their first contribution in https://github.com/typeddjango/django-stubs/pull/2553
* Rusich90 made their first contribution in https://github.com/typeddjango/django-stubs/pull/2564
* mrgalopes made their first contribution in https://github.com/typeddjango/django-stubs/pull/2565
* MaestroXXXVIII made their first contribution in https://github.com/typeddjango/django-stubs/pull/2576
* JasonLovesDoggo made their first contribution in https://github.com/typeddjango/django-stubs/pull/2568
* simwr872 made their first contribution in https://github.com/typeddjango/django-stubs/pull/2595
* michalpokusa made their first contribution in https://github.com/typeddjango/django-stubs/pull/2612
* donBarbos made their first contribution in https://github.com/typeddjango/django-stubs/pull/2624

**Full Changelog**: https://github.com/typeddjango/django-stubs/compare/5.1.3...5.2.0
Links

@luzfcb luzfcb force-pushed the pyup-update-django-stubs-5.1.3-to-5.2.0 branch from a3fd2c5 to 9a3ddb9 Compare April 30, 2025 20:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant