-
-
Notifications
You must be signed in to change notification settings - Fork 456
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
Update _Choices type alias #2368
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please, add several tests for that.
4a6dc8e
to
a162237
Compare
@sobolevn, thanks for the obvious feedback. I've reduced the scope of the PR to change only the |
9f5ef89
to
46b8648
Compare
Hey, sorry for the amount of force-pushes and failed tests. I must have gotten something wrong with my environment, because the test suite was passing locally since the beginning, even though the errors are quite simple |
Django 5 allows model field choices to be callables, mappings or subclasses of models.Choices. This commit introduces these options in the stubs.
46b8648
to
8e79ee2
Compare
Please, fix the merge conflict :) |
I pushed an updated version here which should be ready with the merge conflict resolved: |
Updating the _Choices type alias
Django 5 allows model field choices to be callables, mappings or subclasses of
models.Choices
. This PR introduces these options in the stubs.Related issues
No related issues