Skip to content
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

fix(relations): remove some typevars in favor of Any #608

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

Linkid
Copy link

@Linkid Linkid commented May 7, 2024

I have made things!

RelatedField subclasses can avoid dealing with data type and model type TypeVars override, as they are not specific.

This should fix the "Need type annotation for" that mypy raises for all related field subclasses.

Related issues

Ref #168

Linkid added 2 commits May 7, 2024 13:33
Remove the data type TypeVar in favor of Any. Then subclasses don't have
to deal with this rule anymore.

Ref typeddjango#168
@sobolevn sobolevn requested a review from intgr May 7, 2024 14:37
@Linkid Linkid force-pushed the fix-relations-need-type-annotation branch from e9fe7bd to 3c65afa Compare May 7, 2024 15:36
@Linkid
Copy link
Author

Linkid commented May 7, 2024

Hello. I've forgotten some methods. This should be fixed in the latest commit.

@intgr intgr self-assigned this May 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants