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

Mypy: Set disallow_untyped_defs = true #242

Merged
merged 14 commits into from
Apr 12, 2024
Merged

Mypy: Set disallow_untyped_defs = true #242

merged 14 commits into from
Apr 12, 2024

Conversation

fohrloop
Copy link
Owner

Set disallow_untyped_defs = true. This is a bit stricter policy than before.

  • Disallows defining functions without type annotations or with incomplete type annotations
  • Also disallows mismatched function signatures; if a method is defined def foo(self, a=1),
    if is not possible to use it in subclass as super().foo(*args, **kwargs). This discourages
    the usage of *args, **kwargs in places where they're not really needed.

See: https://mypy.readthedocs.io/en/stable/config_file.html#confval-disallow_untyped_defs

@fohrloop fohrloop merged commit fe69498 into dev Apr 12, 2024
12 checks passed
@fohrloop fohrloop deleted the mypy-rules-update branch April 12, 2024 21:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant