refactor: Enable a few more mypy checks and fix related typing issues.#207
Merged
Conversation
Turns on `disallow_subclassing_any`, `disallow_untyped_calls`, `check_untyped_defs`, and `warn_return_any` (still well short of `--strict`) and addresses the resulting failures. Replaces the dict-returning `crypto.encrypt()` / `make_test_message()` with `EncryptionTestDTO`, propagating through `upload_user_file` and tests, adds missing return-type annotations, and narrows generic collections. The vendored `actual.utils.openid` and the `proto.Message`-driven `actual.protobuf_models` are isolated via per-module overrides. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
…e payee/account names in CLI. - `user_create_key` now serializes the DTO with `model_dump_json(by_alias=True)` instead of `json.dumps`, which can't handle pydantic models. - `EncryptMetaDTO(**encrypted.meta)` in the test was double-wrapping the DTO; pass `encrypted.meta` directly. - CLI accounts/payees commands no longer skip rows when `name` is None; render as empty string instead to preserve the previous output. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #207 +/- ##
==========================================
- Coverage 97.54% 97.49% -0.05%
==========================================
Files 21 22 +1
Lines 3257 3277 +20
==========================================
+ Hits 3177 3195 +18
- Misses 80 82 +2 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
disallow_subclassing_any,disallow_untyped_calls,check_untyped_defsandwarn_return_any.crypto.encrypt()/make_test_message()withEncryptionTestDTO, propagating throughupload_user_fileand tests, adds missing return-type annotations, and narrows generic collections. The vendoredactual.utils.openidand theproto.Message-drivenactual.protobuf_modelsare isolated via per-module overrides.