-
-
Notifications
You must be signed in to change notification settings - Fork 450
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
Declare manager class attributes on models as ClassVar
s
#1672
Merged
Commits on Sep 2, 2023
-
Move ModelBase.objects declaration to Model.objects, for mypy 1.5.0
mypy 1.5.0 was fixed to understand that metaclass attributes take precedence over attributes in the regular class. So we need to declare `objects` in the regular class to allow it to be overridden in subclasses. Fixes typeddjango#1648. Signed-off-by: Anders Kaseorg <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for fc3ef75 - Browse repository at this point
Copy the full SHA fc3ef75View commit details
Commits on Sep 4, 2023
-
Declare manager class attributes on models as
ClassVar
sInclusions: - Adjustments for the plugin to make generated managers `ClassVar`s - Changes the default 'objects' to 'ClassVar' and controls it via the plugin - Plugin ensures to only add the 'objects' manager to models it exists on during runtime
Configuration menu - View commit details
-
Copy full SHA for 662f4ee - Browse repository at this point
Copy the full SHA 662f4eeView commit details -
Configuration menu - View commit details
-
Copy full SHA for cc1f7c9 - Browse repository at this point
Copy the full SHA cc1f7c9View commit details -
Enforce appropriate keyword only arguments
Co-authored-by: Nikita Sobolev <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 2393ed5 - Browse repository at this point
Copy the full SHA 2393ed5View commit details -
Configuration menu - View commit details
-
Copy full SHA for 6919929 - Browse repository at this point
Copy the full SHA 6919929View commit details -
Configuration menu - View commit details
-
Copy full SHA for e96954f - Browse repository at this point
Copy the full SHA e96954fView commit details -
Configuration menu - View commit details
-
Copy full SHA for 7359fd0 - Browse repository at this point
Copy the full SHA 7359fd0View commit details -
Configuration menu - View commit details
-
Copy full SHA for 7e58520 - Browse repository at this point
Copy the full SHA 7e58520View commit details
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.