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

CI: Remove flake & mypy? #125

Open
adamcharnock opened this issue Jun 26, 2024 · 1 comment
Open

CI: Remove flake & mypy? #125

adamcharnock opened this issue Jun 26, 2024 · 1 comment

Comments

@adamcharnock
Copy link
Owner

adamcharnock commented Jun 26, 2024

Just throwing this out there for discussion. I love black, but using flake in addition just seems to throw up a bunch of noise that I don't think really makes much difference to code quality (it mostly just results in # noqa comments for me).

mypy is also being a bit of an irritant too. I did catch an error in a type annotation, but other than that it was (IMHO) just noise:

hordak/admin.py:51: error: "Callable[[AccountAdmin, Any], Any]" has no attribute "admin_order_field"  [attr-defined]
hordak/management/commands/create_benchmark_transactions.py:36: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs  [annotation-unchecked]
hordak/management/commands/create_benchmark_transactions.py:37: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs  [annotation-unchecked]
hordak/management/commands/create_benchmark_transactions.py:38: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs  [annotation-unchecked]
hordak/management/commands/create_benchmark_transactions.py:39: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs  [annotation-unchecked]
hordak/management/commands/create_benchmark_transactions.py:40: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs  [annotation-unchecked]
hordak/management/commands/create_benchmark_transactions.py:82: error: Syntax error in type annotation  [syntax]
hordak/management/commands/create_benchmark_transactions.py:82: note: Suggestion: Use Tuple[T1, ..., Tn] instead of (T1, ..., Tn)
hordak/forms/transactions.py:178: error: Need type annotation for "source_account"  [var-annotated]
hordak/forms/transactions.py:182: error: Need type annotation for "trading_account"  [var-annotated]
hordak/forms/transactions.py:191: error: Need type annotation for "destination_account"  [var-annotated]
hordak/forms/statement_csv_import.py:13: error: Need type annotation for "bank_account"  [var-annotated]
hordak/views/transactions.py:65: error: Definition of "object" in base class "DeletionMixin" is incompatible with definition in base class "BaseDetailView"  [misc]

How helpful do other people find these two tools though?


UPDATE: I'd also be happy to replace these with automatic tools such as (example). It isn't the changes I object to, rather it's the manual drudgery of having to follow rules that I'm not really sure I agree with.

adamcharnock added a commit that referenced this issue Jun 30, 2024
…sues using our IDEs or in PR review. Black catches most of it anyway, #125
@adamcharnock
Copy link
Owner Author

I've removed mypy as part of #127 (4a15aa1), because god help me.

Commit message:

Removing mypy. We're all consenting adults here. Let's catch these issues using our IDEs or in PR review. Black catches most of it anyway, #125

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

No branches or pull requests

1 participant