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

[nit][pre-commit][mypy] add mypy type checking to precommit #506

Merged
merged 6 commits into from
Nov 21, 2024

Conversation

nowei
Copy link
Contributor

@nowei nowei commented Nov 2, 2024

Changes:

  • Adds mypy to pre-commit checks
  • Fixes typing inconsistencies/missing types in most places

TO BE MERGED AFTER: #503

@nowei
Copy link
Contributor Author

nowei commented Nov 2, 2024

scripts/sample_lambda.py:6: error: Function is missing a type annotation  [no-untyped-def]
python/src/schemas/project_types.py:18: error: Function is missing a type annotation  [no-untyped-def]
python/src/lib/output_template_comparator.py:26: error: Function is missing a return type annotation  [no-untyped-def]
python/src/lib/output_template_comparator.py:26: note: Use "-> None" if function does not return a value
python/src/lib/output_template_comparator.py:34: error: Function is missing a return type annotation  [no-untyped-def]
python/src/lib/output_template_comparator.py:47: error: Function is missing a return type annotation  [no-untyped-def]
python/src/lib/output_template_comparator.py:47: error: Function "builtins.any" is not valid as a type  [valid-type]
python/src/lib/output_template_comparator.py:47: note: Perhaps you meant "typing.Any" instead of "any"?
python/src/lib/output_template_comparator.py:60: error: Missing type parameters for generic type "dict"  [type-arg]
python/src/lib/output_template_comparator.py:64: error: Call to untyped function "_normalize_names" in typed context  [no-untyped-call]
python/src/lib/output_template_comparator.py:70: error: Function is missing a type annotation for one or more arguments
 [no-untyped-def]
python/src/lib/output_template_comparator.py:72: error: Incompatible return value type (got "IO[bytes]", expected "ZipExtFile")  [return-value]
python/src/lib/output_template_comparator.py:74: error: Function is missing a return type annotation  [no-untyped-def]
python/src/lib/output_template_comparator.py:74: note: Use "-> None" if function does not return a value
python/src/lib/output_template_comparator.py:86: error: Missing type parameters for generic type "tuple"  [type-arg]
python/src/lib/output_template_comparator.py:95: error: Function is missing a type annotation  [no-untyped-def]
python/src/lib/output_template_comparator.py:119: error: Function is missing a type annotation  [no-untyped-def]
python/src/lib/output_template_comparator.py:175: error: Incompatible types in assignment (expression has type "str", target has type "list[str]")  [assignment]
python/src/lib/output_template_comparator.py:180: error: Incompatible types in assignment (expression has type "str", target has type "list[str]")  [assignment]
python/src/lib/output_template_comparator.py:183: error: Call to untyped function "compare_sheet_columns" in typed context  [no-untyped-call]
python/src/lib/output_template_comparator.py:195: error: Call to untyped function "compare_cell_values" in typed context
  [no-untyped-call]
python/src/lib/output_template_comparator.py:203: error: Incompatible return value type (got "CPFDiffReport", expected "list[str]")  [return-value]
python/src/lib/output_template_comparator.py:206: error: Function is missing a type annotation for one or more arguments
  [no-untyped-def]
python/src/lib/output_template_comparator.py:238: error: "list[str]" has no attribute "summary_report"  [attr-defined]
python/src/lib/email.py:9: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/tests/src/lib/test_output_template_comparator.py:11: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_output_template_comparator.py:22: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_output_template_comparator.py:33: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_output_template_comparator.py:35: error: Call to untyped function "compare_sheet_columns" in typed context  [no-untyped-call]
python/tests/src/lib/test_output_template_comparator.py:43: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_output_template_comparator.py:48: error: Call to untyped function "compare_sheet_columns" in typed context  [no-untyped-call]
python/tests/src/lib/test_output_template_comparator.py:56: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_output_template_comparator.py:61: error: Call to untyped function "compare_sheet_columns" in typed context  [no-untyped-call]
python/tests/src/lib/test_output_template_comparator.py:64: error: Call to untyped function "compare_cell_values" in typed context  [no-untyped-call]
python/tests/src/lib/test_output_template_comparator.py:70: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_output_template_comparator.py:72: error: Call to untyped function "compare_sheet_columns" in typed context  [no-untyped-call]
python/tests/src/lib/test_output_template_comparator.py:73: error: Call to untyped function "compare_cell_values" in typed context  [no-untyped-call]
python/src/lib/constants.py:12: error: Function is missing a type annotation  [no-untyped-def]
python/src/lib/workbook_utils.py:13: error: Function is missing a return type annotation  [no-untyped-def]
python/src/lib/workbook_utils.py:21: error: Function is missing a return type annotation  [no-untyped-def]
python/src/lib/workbook_utils.py:49: error: Function is missing a return type annotation  [no-untyped-def]
python/src/lib/logging.py:39: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/lib/logging.py:43: error: Function is missing a type annotation  [no-untyped-def]
python/src/lib/logging.py:54: error: Function is missing a type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:90: error: Function is missing a type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:103: error: Function is missing a type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:113: error: Function is missing a type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:121: error: Function is missing a type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:131: error: Function is missing a type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:139: error: Function is missing a type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:143: error: Class cannot subclass "BaseModel" (has type "Any")  [misc]
python/src/schemas/schema_V2024_05_24.py:605: error: Function is missing a type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:613: error: Untyped decorator makes function "serialize_mm_dd_yyyy_dates" untyped  [misc]
python/src/schemas/schema_V2024_05_24.py:627: error: Untyped decorator makes function "validate_field" untyped  [misc]
python/src/schemas/schema_V2024_05_24.py:642: error: Function is missing a return type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:642: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:643: error: Non-overlapping equality check (left operand type: "Callable[[str | None], str]", right operand type: "Literal['']")  [comparison-overlap]
python/src/schemas/schema_V2024_05_24.py:784: error: Untyped decorator makes function "validate_field" untyped  [misc]
python/src/schemas/schema_V2024_05_24.py:799: error: Function is missing a return type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:799: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:800: error: Non-overlapping equality check (left operand type: "Callable[[str | None], str]", right operand type: "Literal['']")  [comparison-overlap]
python/src/schemas/schema_V2024_05_24.py:805: error: Class cannot subclass "BaseModel" (has type "Any")  [misc]
python/src/schemas/schema_V2024_05_24.py:911: error: Untyped decorator makes function "validate_field" untyped  [misc]
python/src/schemas/schema_V2024_05_24.py:917: error: Function is missing a return type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:917: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:918: error: Non-overlapping equality check (left operand type: "Callable[[str | None], str]", right operand type: "Literal['']")  [comparison-overlap]
python/src/schemas/schema_V2024_05_24.py:1089: error: Untyped decorator makes function "validate_field" untyped  [misc]
python/src/schemas/schema_V2024_05_24.py:1105: error: Function is missing a return type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:1105: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:1106: error: Non-overlapping equality check (left operand type: "Callable[[str | None], str]", right operand type: "Literal['']")  [comparison-overlap]
python/src/schemas/schema_V2024_05_24.py:1238: error: Untyped decorator makes function "validate_field" untyped  [misc]
python/src/schemas/schema_V2024_05_24.py:1240: error: Function is missing a return type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:1240: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:1241: error: Non-overlapping equality check (left operand type: "Callable[[str | None], str]", right operand type: "Literal['']")  [comparison-overlap]
python/src/schemas/schema_V2024_05_24.py:1246: error: Class cannot subclass "BaseModel" (has type "Any")  [misc]
python/src/schemas/schema_V2024_05_24.py:1323: error: Untyped decorator makes function "validate_field" untyped  [misc]
python/src/schemas/schema_V2024_05_24.py:1336: error: Function is missing a return type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:1336: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:1337: error: Non-overlapping equality check (left operand type: "Callable[[str | None], str]", right operand type: "Literal['']")  [comparison-overlap]
python/src/schemas/schema_V2024_05_24.py:1367: error: Class cannot subclass "BaseModel" (has type "Any")  [misc]
python/src/schemas/schema_V2024_05_24.py:1377: error: Untyped decorator makes function "validate_code" untyped  [misc]
python/src/schemas/schema_V2024_05_24.py:1379: error: Function is missing a return type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:1379: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:1384: error: Untyped decorator makes function "validate_code_name_pair" untyped
  [misc]
python/src/schemas/schema_V2024_05_24.py:1386: error: Function is missing a return type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_05_24.py:1386: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/schemas/schema_V2024_04_01.py:124: error: Class cannot subclass "BaseModel" (has type "Any")  [misc]
python/src/schemas/schema_V2024_04_01.py:349: error: Function is missing a type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_04_01.py:357: error: Untyped decorator makes function "serialize_mm_dd_yyyy_dates" untyped  [misc]
python/src/schemas/schema_V2024_04_01.py:371: error: Untyped decorator makes function "validate_field" untyped  [misc]
python/src/schemas/schema_V2024_04_01.py:386: error: Function is missing a return type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_04_01.py:386: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/schemas/schema_V2024_04_01.py:387: error: Non-overlapping equality check (left operand type: "Callable[[str | None], str]", right operand type: "Literal['']")  [comparison-overlap]
python/src/schemas/schema_V2024_04_01.py:523: error: Untyped decorator makes function "validate_field" untyped  [misc]
python/src/schemas/schema_V2024_04_01.py:538: error: Function is missing a return type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_04_01.py:538: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/schemas/schema_V2024_04_01.py:539: error: Non-overlapping equality check (left operand type: "Callable[[str | None], str]", right operand type: "Literal['']")  [comparison-overlap]
python/src/schemas/schema_V2024_04_01.py:544: error: Class cannot subclass "BaseModel" (has type "Any")  [misc]
python/src/schemas/schema_V2024_04_01.py:602: error: Untyped decorator makes function "validate_field" untyped  [misc]
python/src/schemas/schema_V2024_04_01.py:608: error: Function is missing a return type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_04_01.py:608: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/schemas/schema_V2024_04_01.py:609: error: Non-overlapping equality check (left operand type: "Callable[[str | None], str]", right operand type: "Literal['']")  [comparison-overlap]
python/src/schemas/schema_V2024_04_01.py:744: error: Untyped decorator makes function "validate_field" untyped  [misc]
python/src/schemas/schema_V2024_04_01.py:760: error: Function is missing a return type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_04_01.py:760: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/schemas/schema_V2024_04_01.py:761: error: Non-overlapping equality check (left operand type: "Callable[[str | None], str]", right operand type: "Literal['']")  [comparison-overlap]
python/src/schemas/schema_V2024_04_01.py:861: error: Untyped decorator makes function "validate_field" untyped  [misc]
python/src/schemas/schema_V2024_04_01.py:863: error: Function is missing a return type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_04_01.py:863: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/schemas/schema_V2024_04_01.py:864: error: Non-overlapping equality check (left operand type: "Callable[[str | None], str]", right operand type: "Literal['']")  [comparison-overlap]
python/src/schemas/schema_V2024_04_01.py:869: error: Class cannot subclass "BaseModel" (has type "Any")  [misc]
python/src/schemas/schema_V2024_04_01.py:929: error: Untyped decorator makes function "validate_field" untyped  [misc]
python/src/schemas/schema_V2024_04_01.py:942: error: Function is missing a return type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_04_01.py:942: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/schemas/schema_V2024_04_01.py:943: error: Non-overlapping equality check (left operand type: "Callable[[str | None], str]", right operand type: "Literal['']")  [comparison-overlap]
python/src/schemas/schema_V2024_04_01.py:973: error: Class cannot subclass "BaseModel" (has type "Any")  [misc]
python/src/schemas/schema_V2024_04_01.py:983: error: Untyped decorator makes function "validate_code" untyped  [misc]
python/src/schemas/schema_V2024_04_01.py:985: error: Function is missing a return type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_04_01.py:985: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/schemas/schema_V2024_04_01.py:990: error: Untyped decorator makes function "validate_code_name_pair" untyped
 [misc]
python/src/schemas/schema_V2024_04_01.py:992: error: Function is missing a return type annotation  [no-untyped-def]
python/src/schemas/schema_V2024_04_01.py:992: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/lib/s3_helper.py:11: error: Function is missing a return type annotation  [no-untyped-def]
python/src/lib/s3_helper.py:30: error: Function is missing a return type annotation  [no-untyped-def]
python/src/lib/s3_helper.py:34: error: Missing type parameters for generic type "_TemporaryFileWrapper"  [type-arg]
python/src/lib/s3_helper.py:91: error: Returning Any from function declared to return "str | None"  [no-any-return]
python/src/functions/test_lambdas.py:11: error: Untyped decorator makes function "pre_create_archive" untyped  [misc]
python/src/schemas/schema_versions.py:64: error: Function is missing a return type annotation  [no-untyped-def]
python/src/schemas/schema_versions.py:68: error: Function is missing a return type annotation  [no-untyped-def]
python/src/schemas/schema_versions.py:72: error: Class cannot subclass "BaseModel" (has type "Any")  [misc]
python/src/schemas/schema_versions.py:75: error: Untyped decorator makes function "validate_field" untyped  [misc]
python/src/schemas/schema_versions.py:77: error: Function is missing a return type annotation  [no-untyped-def]
python/src/schemas/schema_versions.py:77: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/schemas/schema_versions.py:80: error: Call to untyped function "compatible_older_versions" of "Version" in typed context  [no-untyped-call]
python/src/schemas/schema_versions.py:84: error: Call to untyped function "compatible_newer_versions" of "Version" in typed context  [no-untyped-call]
python/src/schemas/schema_versions.py:105: error: Incompatible return value type (got "Enum", expected "Version")  [return-value]
python/src/schemas/schema_versions.py:112: error: Incompatible return value type (got "type[src.schemas.schema_V2024_05_24.SubrecipientRow]", expected "src.schemas.schema_versions.SubrecipientRow")  [return-value]
python/src/schemas/schema_versions.py:114: error: Incompatible return value type (got "type[src.schemas.schema_V2024_04_01.SubrecipientRow]", expected "src.schemas.schema_versions.SubrecipientRow")  [return-value]
python/src/schemas/schema_versions.py:121: error: Incompatible return value type (got "type[src.schemas.schema_V2024_05_24.CoverSheetRow]", expected "src.schemas.schema_versions.CoverSheetRow")  [return-value]
python/src/schemas/schema_versions.py:123: error: Incompatible return value type (got "type[src.schemas.schema_V2024_04_01.CoverSheetRow]", expected "src.schemas.schema_versions.CoverSheetRow")  [return-value]
python/src/schemas/schema_versions.py:129: error: Argument 1 to "getVersionFromString" has incompatible type "Version"; expected "str"  [arg-type]
python/src/schemas/schema_versions.py:142: error: Incompatible return value type (got "type[src.schemas.schema_V2024_05_24.Project1ARow]", expected "src.schemas.schema_versions.Project1ARow")  [return-value]
python/src/schemas/schema_versions.py:144: error: Incompatible return value type (got "type[src.schemas.schema_V2024_04_01.Project1ARow]", expected "src.schemas.schema_versions.Project1ARow")  [return-value]
python/src/schemas/schema_versions.py:150: error: Incompatible return value type (got "type[src.schemas.schema_V2024_05_24.Project1BRow]", expected "src.schemas.schema_versions.Project1BRow")  [return-value]
python/src/schemas/schema_versions.py:152: error: Incompatible return value type (got "type[src.schemas.schema_V2024_04_01.Project1BRow]", expected "src.schemas.schema_versions.Project1BRow")  [return-value]
python/src/schemas/schema_versions.py:158: error: Incompatible return value type (got "type[src.schemas.schema_V2024_05_24.Project1CRow]", expected "src.schemas.schema_versions.Project1CRow")  [return-value]
python/src/schemas/schema_versions.py:160: error: Incompatible return value type (got "type[src.schemas.schema_V2024_04_01.Project1CRow]", expected "src.schemas.schema_versions.Project1CRow")  [return-value]
python/src/schemas/schema_versions.py:163: error: Missing type parameters for generic type "dict"  [type-arg]
python/src/lib/treasury_generation_common.py:14: error: Class cannot subclass "BaseModel" (has type "Any")  [misc]
python/src/lib/treasury_generation_common.py:18: error: Class cannot subclass "BaseModel" (has type "Any")  [misc]
python/src/lib/treasury_generation_common.py:23: error: Class cannot subclass "BaseModel" (has type "Any")  [misc]
python/src/lib/treasury_generation_common.py:40: error: Function is missing a return type annotation  [no-untyped-def]
python/src/lib/workbook_validator.py:72: error: Function is missing a return type annotation  [no-untyped-def]
python/src/lib/workbook_validator.py:72: error: Missing type parameters for generic type "Tuple"  [type-arg]
python/src/lib/workbook_validator.py:76: error: Function is missing a return type annotation  [no-untyped-def]
python/src/lib/workbook_validator.py:76: error: Missing type parameters for generic type "Tuple"  [type-arg]
python/src/lib/workbook_validator.py:80: error: Missing type parameters for generic type "tuple"  [type-arg]
python/src/lib/workbook_validator.py:103: error: Value of type "dict[str, str] | None" is not indexable  [index]
python/src/lib/workbook_validator.py:137: error: Returning Any from function declared to return "str"  [no-any-return]
python/src/lib/workbook_validator.py:139: error: Returning Any from function declared to return "str"  [no-any-return]
python/src/lib/workbook_validator.py:147: error: Returning Any from function declared to return "str"  [no-any-return]
python/src/lib/workbook_validator.py:175: error: Item "type" of "type[CoverSheetRow] | type[Project1ARow] | type[Project1BRow] | type[Project1CRow] | type[SubrecipientRow]" has no attribute "model_fields"  [union-attr]
python/src/lib/workbook_validator.py:216: error: Incompatible return value type (got "tuple[list[WorkbookError], str | None, list[Project1ARow | Project1BRow | Project1CRow], list[SubrecipientRow]]", expected "tuple[list[WorkbookError], str | None, list[SubrecipientRow], str]")  [return-value]
python/src/lib/workbook_validator.py:219: error: Incompatible return value type (got "tuple[list[WorkbookError], str]", expected "tuple[list[WorkbookError], str | None, list[SubrecipientRow], str]")  [return-value]
python/src/lib/workbook_validator.py:293: error: "SubrecipientRow" has no attribute "model_dump"  [attr-defined]
python/src/lib/workbook_validator.py:295: error: Incompatible return value type (got "tuple[list[WorkbookError], ProjectType | None, list[SubrecipientRow], str]", expected "tuple[list[WorkbookError], str | None, list[Project1ARow | Project1BRow | Project1CRow], list[SubrecipientRow]]")  [return-value]
python/src/lib/workbook_validator.py:350: error: "CoverSheetRow" not callable  [operator]
python/src/lib/workbook_validator.py:353: error: Argument 1 to "get_workbook_errors_for_row" has incompatible type "CoverSheetRow"; expected "type[CoverSheetRow] | type[Project1ARow] | type[Project1BRow] | type[Project1CRow] | type[SubrecipientRow]"  [arg-type]
python/src/lib/workbook_validator.py:375: error: Argument 1 to "getSchemaByProject" has incompatible type "str"; expected "Version"  [arg-type]
python/src/lib/workbook_validator.py:376: error: Incompatible return value type (got "tuple[list[WorkbookError], Project1ARow | Project1BRow | Project1CRow, ProjectType]", expected "tuple[list[WorkbookError], type[Project1ARow] | type[Project1BRow] | type[Project1CRow] | None, ProjectType | None]")  [return-value]
python/src/lib/workbook_validator.py:412: error: Argument "row" to "WorkbookError" has incompatible type "int"; expected
 "str"  [arg-type]
python/src/lib/workbook_validator.py:413: error: Argument "col" to "WorkbookError" has incompatible type "int"; expected
 "str"  [arg-type]
python/src/lib/workbook_validator.py:442: error: "SubrecipientRow" not callable  [operator]
python/src/lib/workbook_validator.py:445: error: Argument 1 to "get_workbook_errors_for_row" has incompatible type "SubrecipientRow"; expected "type[CoverSheetRow] | type[Project1ARow] | type[Project1BRow] | type[Project1CRow] | type[SubrecipientRow]"  [arg-type]
python/src/lib/workbook_validator.py:464: error: "SubrecipientRow" has no attribute "EIN__c"  [attr-defined]
python/src/lib/workbook_validator.py:464: error: "SubrecipientRow" has no attribute "Unique_Entity_Identifier__c"  [attr-defined]
python/src/lib/workbook_validator.py:470: error: Item "Project1ARow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "Subrecipient_TIN__c"  [union-attr]
python/src/lib/workbook_validator.py:470: error: Item "Project1BRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "Subrecipient_TIN__c"  [union-attr]
python/src/lib/workbook_validator.py:470: error: Item "Project1CRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "Subrecipient_TIN__c"  [union-attr]
python/src/lib/workbook_validator.py:470: error: Item "Project1ARow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "Subrecipient_UEI__c"  [union-attr]
python/src/lib/workbook_validator.py:470: error: Item "Project1BRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "Subrecipient_UEI__c"  [union-attr]
python/src/lib/workbook_validator.py:470: error: Item "Project1CRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "Subrecipient_UEI__c"  [union-attr]
python/src/lib/workbook_validator.py:474: error: Item "type" of "type[Project1ARow] | type[Project1BRow] | type[Project1CRow]" has no attribute "model_fields"  [union-attr]
python/src/lib/workbook_validator.py:477: error: Item "type" of "type[Project1ARow] | type[Project1BRow] | type[Project1CRow]" has no attribute "model_fields"  [union-attr]
python/src/lib/workbook_validator.py:483: error: Item "Project1ARow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "row_num"  [union-attr]
python/src/lib/workbook_validator.py:483: error: Item "Project1BRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "row_num"  [union-attr]
python/src/lib/workbook_validator.py:483: error: Item "Project1CRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "row_num"  [union-attr]
python/src/lib/workbook_validator.py:502: error: Too many values to unpack (2 expected, 4 provided)  [misc]
python/src/functions/subrecipient_treasury_report_gen.py:32: error: Class cannot subclass "BaseModel" (has type "Any")  [misc]
python/src/functions/subrecipient_treasury_report_gen.py:38: error: Untyped decorator makes function "handle" untyped  [misc]
python/src/functions/subrecipient_treasury_report_gen.py:39: error: Function is missing a return type annotation  [no-untyped-def]
python/src/functions/subrecipient_treasury_report_gen.py:76: error: Function is missing a return type annotation  [no-untyped-def]
python/src/functions/subrecipient_treasury_report_gen.py:127: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/functions/subrecipient_treasury_report_gen.py:132: error: Missing type parameters for generic type "dict"  [type-arg]
python/src/functions/subrecipient_treasury_report_gen.py:152: error: Return value expected  [return-value]
python/src/functions/subrecipient_treasury_report_gen.py:164: error: Return value expected  [return-value]
python/src/functions/subrecipient_treasury_report_gen.py:169: error: Function is missing a return type annotation  [no-untyped-def]
python/src/functions/subrecipient_treasury_report_gen.py:169: error: Missing type parameters for generic type "dict"  [type-arg]
python/src/functions/subrecipient_treasury_report_gen.py:181: error: Function is missing a return type annotation  [no-untyped-def]
python/src/functions/subrecipient_treasury_report_gen.py:182: error: Missing type parameters for generic type "dict"  [type-arg]
python/src/functions/subrecipient_treasury_report_gen.py:200: error: Call to untyped function "get_most_recent_upload" in typed context  [no-untyped-call]
python/src/functions/subrecipient_treasury_report_gen.py:202: error: "SubrecipientRow" has no attribute "model_fields"  [attr-defined]
python/src/functions/subrecipient_treasury_report_gen.py:223: error: Function is missing a type annotation  [no-untyped-def]
python/src/functions/subrecipient_treasury_report_gen.py:236: error: Function is missing a return type annotation  [no-untyped-def]
python/src/functions/generate_presigned_url_and_send_email.py:25: error: Class cannot subclass "BaseModel" (has type "Any")  [misc]
python/src/functions/generate_presigned_url_and_send_email.py:30: error: Untyped decorator makes function "handle" untyped  [misc]
python/src/functions/generate_presigned_url_and_send_email.py:31: error: Function is missing a return type annotation  [no-untyped-def]
python/src/functions/generate_presigned_url_and_send_email.py:102: error: Function is missing a return type annotation  [no-untyped-def]
python/src/functions/create_archive.py:18: error: Class cannot subclass "BaseModel" (has type "Any")  [misc]
python/src/functions/create_archive.py:22: error: Untyped decorator makes function "handle" untyped  [misc]
python/src/functions/create_archive.py:23: error: Function is missing a return type annotation  [no-untyped-def]
python/src/functions/create_archive.py:66: error: Function is missing a return type annotation  [no-untyped-def]
python/src/functions/create_archive.py:66: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:26: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:46: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:56: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:61: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:68: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:88: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:92: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:103: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:110: error: Argument 1 to "getSchemaByProject" has incompatible type "str"; expected "Version"  [arg-type]
python/tests/src/lib/test_workbook_validator.py:110: error: Argument 2 to "getSchemaByProject" has incompatible type "str"; expected "ProjectType"  [arg-type]
python/tests/src/lib/test_workbook_validator.py:113: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:129: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:145: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:163: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:166: error: Argument 2 to "validate_project_sheet" has incompatible type "Project1ARow | Project1BRow | Project1CRow"; expected "type[Project1ARow] | type[Project1BRow] | type[Project1CRow]"  [arg-type]
python/tests/src/lib/test_workbook_validator.py:167: error: Argument 1 to "getSchemaByProject" has incompatible type "str"; expected "Version"  [arg-type]
python/tests/src/lib/test_workbook_validator.py:167: error: Argument 2 to "getSchemaByProject" has incompatible type "str"; expected "ProjectType"  [arg-type]
python/tests/src/lib/test_workbook_validator.py:173: error: Item "Project1ARow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "row_num"  [union-attr]
python/tests/src/lib/test_workbook_validator.py:173: error: Item "Project1BRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "row_num"  [union-attr]
python/tests/src/lib/test_workbook_validator.py:173: error: Item "Project1CRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "row_num"  [union-attr]
python/tests/src/lib/test_workbook_validator.py:174: error: Item "Project1ARow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "Subrecipient_UEI__c"  [union-attr]
python/tests/src/lib/test_workbook_validator.py:174: error: Item "Project1BRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "Subrecipient_UEI__c"  [union-attr]
python/tests/src/lib/test_workbook_validator.py:174: error: Item "Project1CRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "Subrecipient_UEI__c"  [union-attr]
python/tests/src/lib/test_workbook_validator.py:175: error: Item "Project1ARow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "Subrecipient_TIN__c"  [union-attr]
python/tests/src/lib/test_workbook_validator.py:175: error: Item "Project1BRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "Subrecipient_TIN__c"  [union-attr]
python/tests/src/lib/test_workbook_validator.py:175: error: Item "Project1CRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "Subrecipient_TIN__c"  [union-attr]
python/tests/src/lib/test_workbook_validator.py:177: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:180: error: Argument 2 to "validate_project_sheet" has incompatible type "Project1ARow | Project1BRow | Project1CRow"; expected "type[Project1ARow] | type[Project1BRow] | type[Project1CRow]"  [arg-type]
python/tests/src/lib/test_workbook_validator.py:181: error: Argument 1 to "getSchemaByProject" has incompatible type "str"; expected "Version"  [arg-type]
python/tests/src/lib/test_workbook_validator.py:181: error: Argument 2 to "getSchemaByProject" has incompatible type "str"; expected "ProjectType"  [arg-type]
python/tests/src/lib/test_workbook_validator.py:195: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:200: error: Argument 2 to "validate_project_sheet" has incompatible type "Project1ARow | Project1BRow | Project1CRow"; expected "type[Project1ARow] | type[Project1BRow] | type[Project1CRow]"  [arg-type]
python/tests/src/lib/test_workbook_validator.py:201: error: Argument 1 to "getSchemaByProject" has incompatible type "str"; expected "Version"  [arg-type]
python/tests/src/lib/test_workbook_validator.py:201: error: Argument 2 to "getSchemaByProject" has incompatible type "str"; expected "ProjectType"  [arg-type]
python/tests/src/lib/test_workbook_validator.py:212: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:217: error: Argument 2 to "validate_project_sheet" has incompatible type "Project1ARow | Project1BRow | Project1CRow"; expected "type[Project1ARow] | type[Project1BRow] | type[Project1CRow]"  [arg-type]
python/tests/src/lib/test_workbook_validator.py:218: error: Argument 1 to "getSchemaByProject" has incompatible type "str"; expected "Version"  [arg-type]
python/tests/src/lib/test_workbook_validator.py:218: error: Argument 2 to "getSchemaByProject" has incompatible type "str"; expected "ProjectType"  [arg-type]
python/tests/src/lib/test_workbook_validator.py:231: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:237: error: "SubrecipientRow" has no attribute "EIN__c"  [attr-defined]
python/tests/src/lib/test_workbook_validator.py:238: error: "SubrecipientRow" has no attribute "Unique_Entity_Identifier__c"  [attr-defined]
python/tests/src/lib/test_workbook_validator.py:240: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:251: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:261: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:270: error: Non-overlapping equality check (left operand type: "str", right operand type: "Literal[13]")  [comparison-overlap]
python/tests/src/lib/test_workbook_validator.py:274: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:283: error: Non-overlapping equality check (left operand type: "str", right operand type: "Literal[13]")  [comparison-overlap]
python/tests/src/lib/test_workbook_validator.py:287: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:296: error: Non-overlapping equality check (left operand type: "str", right operand type: "Literal[13]")  [comparison-overlap]
python/tests/src/lib/test_workbook_validator.py:302: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_workbook_validator.py:308: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:23: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:23: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:33: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:36: error: Need type annotation for "event" (hint: "event: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:46: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:46: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:68: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:68: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:81: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:81: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:94: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:94: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:118: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:144: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:170: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:196: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:222: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:235: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:277: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:309: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:310: error: Call to untyped function "get_most_recent_upload" in typed context  [no-untyped-call]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:313: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:313: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:317: error: Call to untyped function "get_most_recent_upload" in typed context  [no-untyped-call]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:320: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:320: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:321: error: Need type annotation for "empty_subrecipient"
 [var-annotated]
python/tests/src/lib/test_subrecipient_treasury_report_gen.py:323: error: Call to untyped function "get_most_recent_upload" in typed context  [no-untyped-call]
python/tests/src/lib/test_create_archive.py:9: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_create_archive.py:40: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_create_archive.py:40: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_create_archive.py:55: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_create_archive.py:55: note: Use "-> None" if function does not return a value
python/tests/conftest.py:27: error: Untyped decorator makes function "valid_file" untyped  [misc]
python/tests/conftest.py:33: error: Untyped decorator makes function "valid_workbook" untyped  [misc]
python/tests/conftest.py:38: error: Untyped decorator makes function "valid_workbook_old_schema" untyped  [misc]
python/tests/conftest.py:43: error: Untyped decorator makes function "valid_workbook_old_compatible_schema" untyped  [misc]
python/tests/conftest.py:50: error: Untyped decorator makes function "valid_coversheet" untyped  [misc]
python/tests/conftest.py:51: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/tests/conftest.py:55: error: Untyped decorator makes function "valid_project_sheet" untyped  [misc]
python/tests/conftest.py:56: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/tests/conftest.py:60: error: Untyped decorator makes function "valid_workbook_1A" untyped  [misc]
python/tests/conftest.py:65: error: Untyped decorator makes function "valid_project_sheet_1A" untyped  [misc]
python/tests/conftest.py:70: error: Untyped decorator makes function "valid_workbook_1A_with_conflict" untyped  [misc]
python/tests/conftest.py:78: error: Untyped decorator makes function "valid_second_workbook_1A_sheet" untyped  [misc]
python/tests/conftest.py:89: error: Untyped decorator makes function "valid_workbook_1B" untyped  [misc]
python/tests/conftest.py:94: error: Untyped decorator makes function "valid_project_sheet_1B" untyped  [misc]
python/tests/conftest.py:99: error: Untyped decorator makes function "valid_workbook_1B_with_conflict" untyped  [misc]
python/tests/conftest.py:107: error: Untyped decorator makes function "valid_second_workbook_1B_sheet" untyped  [misc]
python/tests/conftest.py:118: error: Untyped decorator makes function "valid_workbook_1C" untyped  [misc]
python/tests/conftest.py:123: error: Untyped decorator makes function "valid_project_sheet_1C" untyped  [misc]
python/tests/conftest.py:128: error: Untyped decorator makes function "valid_workbook_1C_with_conflict" untyped  [misc]
python/tests/conftest.py:136: error: Untyped decorator makes function "valid_second_workbook_1C_sheet" untyped  [misc]
python/tests/conftest.py:147: error: Untyped decorator makes function "valid_subrecipientsheet" untyped  [misc]
python/tests/conftest.py:148: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/tests/conftest.py:153: error: Function is missing a type annotation  [no-untyped-def]
python/tests/conftest.py:159: error: Function is missing a type annotation  [no-untyped-def]
python/tests/conftest.py:165: error: Function is missing a type annotation  [no-untyped-def]
python/tests/conftest.py:171: error: Function is missing a type annotation  [no-untyped-def]
python/tests/conftest.py:177: error: Function is missing a type annotation  [no-untyped-def]
python/tests/conftest.py:183: error: Function is missing a type annotation  [no-untyped-def]
python/tests/conftest.py:189: error: Function is missing a type annotation  [no-untyped-def]
python/tests/conftest.py:195: error: Function is missing a type annotation  [no-untyped-def]
python/tests/conftest.py:201: error: Function is missing a type annotation  [no-untyped-def]
python/tests/conftest.py:207: error: Function is missing a type annotation  [no-untyped-def]
python/tests/conftest.py:214: error: Function is missing a type annotation  [no-untyped-def]
python/tests/conftest.py:220: error: Function is missing a type annotation  [no-untyped-def]
python/tests/conftest.py:228: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/conftest.py:233: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/conftest.py:238: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/conftest.py:243: error: Function is missing a type annotation  [no-untyped-def]
python/tests/conftest.py:250: error: Function is missing a type annotation  [no-untyped-def]
python/tests/conftest.py:257: error: Untyped decorator makes function "output_1A_template" untyped  [misc]
python/tests/conftest.py:262: error: Untyped decorator makes function "output_1B_template" untyped  [misc]
python/tests/conftest.py:267: error: Untyped decorator makes function "output_1C_template" untyped  [misc]
python/tests/conftest.py:273: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/conftest.py:288: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/conftest.py:331: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/conftest.py:343: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/conftest.py:355: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/conftest.py:360: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/conftest.py:365: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/conftest.py:370: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/conftest.py:375: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/conftest.py:380: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/conftest.py:385: error: Function is missing a return type annotation  [no-untyped-def]
python/src/functions/validate_workbook.py:19: error: Untyped decorator makes function "handle" untyped  [misc]
python/src/functions/validate_workbook.py:20: error: Function is missing a return type annotation  [no-untyped-def]
python/src/functions/validate_workbook.py:75: error: Dict entry 2 has incompatible type "str": "list[SubrecipientRow]"; expected "str": "list[dict[str, str]] | str | None"  [dict-item]
python/src/functions/validate_workbook.py:81: error: Function is missing a return type annotation  [no-untyped-def]
python/src/functions/validate_workbook.py:81: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/functions/generate_treasury_report.py:41: error: Class cannot subclass "BaseModel" (has type "Any")  [misc]
python/src/functions/generate_treasury_report.py:50: error: Class cannot subclass "BaseModel" (has type "Any")  [misc]
python/src/functions/generate_treasury_report.py:59: error: Untyped decorator makes function "handle" untyped  [misc]
python/src/functions/generate_treasury_report.py:60: error: Function is missing a return type annotation  [no-untyped-def]
python/src/functions/generate_treasury_report.py:97: error: Function is missing a return type annotation  [no-untyped-def]
python/src/functions/generate_treasury_report.py:312: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/functions/generate_treasury_report.py:339: error: Incompatible types in assignment (expression has type "None", variable has type "_TemporaryFileWrapper[bytes]")  [assignment]
python/src/functions/generate_treasury_report.py:351: error: Function is missing a return type annotation  [no-untyped-def]
python/src/functions/generate_treasury_report.py:363: error: Argument 2 to "validate_project_sheet" has incompatible type "Project1ARow | Project1BRow | Project1CRow"; expected "type[Project1ARow] | type[Project1BRow] | type[Project1CRow]"
 [arg-type]
python/src/functions/generate_treasury_report.py:363: error: Argument 3 to "validate_project_sheet" has incompatible type "Version"; expected "str"  [arg-type]
python/src/functions/generate_treasury_report.py:368: error: Item "Project1ARow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "Identification_Number__c"  [union-attr]
python/src/functions/generate_treasury_report.py:368: error: Item "Project1BRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "Identification_Number__c"  [union-attr]
python/src/functions/generate_treasury_report.py:368: error: Item "Project1CRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "Identification_Number__c"  [union-attr]
python/src/functions/generate_treasury_report.py:373: error: Function is missing a return type annotation  [no-untyped-def]
python/src/functions/generate_treasury_report.py:373: error: Function is missing a type annotation for one or more arguments  [no-untyped-def]
python/src/functions/generate_treasury_report.py:383: error: Need type annotation for "project_agency_ids_to_remove" (hint: "project_agency_ids_to_remove: set[<type>] = ...")  [var-annotated]
python/src/functions/generate_treasury_report.py:413: error: Function is missing a return type annotation  [no-untyped-def]
python/src/functions/generate_treasury_report.py:443: error: Function is missing a return type annotation  [no-untyped-def]
python/src/functions/generate_treasury_report.py:454: error: Item "Project1ARow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "model_json_schema"  [union-attr]
python/src/functions/generate_treasury_report.py:454: error: Item "Project1BRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "model_json_schema"  [union-attr]
python/src/functions/generate_treasury_report.py:454: error: Item "Project1CRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "model_json_schema"  [union-attr]
python/src/functions/generate_treasury_report.py:455: error: Item "Project1ARow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "dict"  [union-attr]
python/src/functions/generate_treasury_report.py:455: error: Item "Project1BRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "dict"  [union-attr]
python/src/functions/generate_treasury_report.py:455: error: Item "Project1CRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "dict"  [union-attr]
python/src/functions/generate_treasury_report.py:471: error: Function is missing a return type annotation  [no-untyped-def]
python/src/functions/generate_treasury_report.py:488: error: Argument 2 to "validate_project_sheet" has incompatible type "Project1ARow | Project1BRow | Project1CRow"; expected "type[Project1ARow] | type[Project1BRow] | type[Project1CRow]"
 [arg-type]
python/src/functions/generate_treasury_report.py:488: error: Argument 3 to "validate_project_sheet" has incompatible type "Version"; expected "str"  [arg-type]
python/src/functions/generate_treasury_report.py:495: error: Item "Project1ARow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "Identification_Number__c"  [union-attr]
python/src/functions/generate_treasury_report.py:495: error: Item "Project1BRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "Identification_Number__c"  [union-attr]
python/src/functions/generate_treasury_report.py:495: error: Item "Project1CRow" of "Project1ARow | Project1BRow | Project1CRow" has no attribute "Identification_Number__c"  [union-attr]
python/tests/src/lib/test_treasury_report_1C.py:26: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1C.py:30: error: Argument "agency_id" to "get_projects_to_remove" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1C.py:35: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1C.py:35: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_treasury_report_1C.py:58: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1C.py:58: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_treasury_report_1C.py:81: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1C.py:81: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_treasury_report_1C.py:104: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1C.py:104: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_treasury_report_1C.py:127: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1C.py:127: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_treasury_report_1C.py:150: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1C.py:150: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_treasury_report_1C.py:173: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1C.py:174: error: Need type annotation for "project_id_agency_id_to_upload_date" (hint: "project_id_agency_id_to_upload_date: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1C.py:175: error: Need type annotation for "project_id_agency_id_to_row_num" (hint: "project_id_agency_id_to_row_num: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1C.py:186: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1C.py:192: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1C.py:196: error: Need type annotation for "project_id_agency_id_to_upload_date" (hint: "project_id_agency_id_to_upload_date: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1C.py:197: error: Need type annotation for "project_id_agency_id_to_row_num" (hint: "project_id_agency_id_to_row_num: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1C.py:208: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1C.py:221: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1C.py:227: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1C.py:231: error: Need type annotation for "project_id_agency_id_to_upload_date" (hint: "project_id_agency_id_to_upload_date: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1C.py:232: error: Need type annotation for "project_id_agency_id_to_row_num" (hint: "project_id_agency_id_to_row_num: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1C.py:243: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1C.py:256: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1C.py:262: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1C.py:266: error: Need type annotation for "project_id_agency_id_to_upload_date" (hint: "project_id_agency_id_to_upload_date: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1C.py:267: error: Need type annotation for "project_id_agency_id_to_row_num" (hint: "project_id_agency_id_to_row_num: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1C.py:278: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1C.py:291: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1B.py:26: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1B.py:30: error: Argument "agency_id" to "get_projects_to_remove" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1B.py:35: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1B.py:35: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_treasury_report_1B.py:58: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1B.py:58: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_treasury_report_1B.py:81: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1B.py:81: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_treasury_report_1B.py:104: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1B.py:104: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_treasury_report_1B.py:127: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1B.py:127: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_treasury_report_1B.py:150: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1B.py:150: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_treasury_report_1B.py:173: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1B.py:174: error: Need type annotation for "project_id_agency_id_to_upload_date" (hint: "project_id_agency_id_to_upload_date: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1B.py:175: error: Need type annotation for "project_id_agency_id_to_row_num" (hint: "project_id_agency_id_to_row_num: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1B.py:186: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1B.py:192: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1B.py:196: error: Need type annotation for "project_id_agency_id_to_upload_date" (hint: "project_id_agency_id_to_upload_date: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1B.py:197: error: Need type annotation for "project_id_agency_id_to_row_num" (hint: "project_id_agency_id_to_row_num: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1B.py:208: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1B.py:221: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1B.py:227: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1B.py:231: error: Need type annotation for "project_id_agency_id_to_upload_date" (hint: "project_id_agency_id_to_upload_date: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1B.py:232: error: Need type annotation for "project_id_agency_id_to_row_num" (hint: "project_id_agency_id_to_row_num: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1B.py:243: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1B.py:256: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1B.py:262: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1B.py:266: error: Need type annotation for "project_id_agency_id_to_upload_date" (hint: "project_id_agency_id_to_upload_date: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1B.py:267: error: Need type annotation for "project_id_agency_id_to_row_num" (hint: "project_id_agency_id_to_row_num: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1B.py:278: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1B.py:291: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1A.py:26: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1A.py:30: error: Argument "agency_id" to "get_projects_to_remove" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1A.py:35: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1A.py:35: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_treasury_report_1A.py:58: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1A.py:58: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_treasury_report_1A.py:81: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1A.py:81: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_treasury_report_1A.py:104: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1A.py:104: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_treasury_report_1A.py:127: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1A.py:127: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_treasury_report_1A.py:150: error: Function is missing a return type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1A.py:150: note: Use "-> None" if function does not return a value
python/tests/src/lib/test_treasury_report_1A.py:173: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1A.py:174: error: Need type annotation for "project_id_agency_id_to_upload_date" (hint: "project_id_agency_id_to_upload_date: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1A.py:175: error: Need type annotation for "project_id_agency_id_to_row_num" (hint: "project_id_agency_id_to_row_num: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1A.py:186: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1A.py:192: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1A.py:196: error: Need type annotation for "project_id_agency_id_to_upload_date" (hint: "project_id_agency_id_to_upload_date: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1A.py:197: error: Need type annotation for "project_id_agency_id_to_row_num" (hint: "project_id_agency_id_to_row_num: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1A.py:208: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1A.py:221: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1A.py:227: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1A.py:231: error: Need type annotation for "project_id_agency_id_to_upload_date" (hint: "project_id_agency_id_to_upload_date: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1A.py:232: error: Need type annotation for "project_id_agency_id_to_row_num" (hint: "project_id_agency_id_to_row_num: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1A.py:243: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1A.py:256: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1A.py:262: error: Function is missing a type annotation  [no-untyped-def]
python/tests/src/lib/test_treasury_report_1A.py:266: error: Need type annotation for "project_id_agency_id_to_upload_date" (hint: "project_id_agency_id_to_upload_date: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1A.py:267: error: Need type annotation for "project_id_agency_id_to_row_num" (hint: "project_id_agency_id_to_row_num: dict[<type>, <type>] = ...")  [var-annotated]
python/tests/src/lib/test_treasury_report_1A.py:278: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
python/tests/src/lib/test_treasury_report_1A.py:291: error: Argument "agency_id" to "combine_project_rows" has incompatible type "int"; expected "str"  [arg-type]
Found 459 errors in 27 files (checked 35 source files)

Copy link

github-actions bot commented Nov 2, 2024

QA Summary

Pusher: @as1729, Action: pull_request_target, Workflow: Continuous Integration

See our documentation for tips on how to resolve failing QA checks.

QA Check Result
🌐 Web Tests
🔗 API Tests
🐍 Python Tests
📏 ESLint
🧼 Ruff
🧹 TFLint

Test Coverage

View the workflow summary for individual coverage reports if this comment is truncated.

Coverage report for api suite
St File % Stmts % Branch % Funcs % Lines Uncovered Line #s
🟡 All files 50.88 33.76 57.09 51.35
🔴  src 0 100 0 0
🔴   server.ts 0 100 0 0 6-13
🟢  src/directives/requireAuth 100 100 100 100
🟢   requireAuth.ts 100 100 100 100
🟡  src/directives/skipAuth 50 100 0 50
🟡   skipAuth.ts 50 100 0 50 13
🔴  src/functions 0 100 0 0
🔴   graphql.ts 0 100 0 0 15-27
🔴  src/functions/processValidationJson 36.36 50 40 35.63
🟢   processValidationJson.scenarios.ts 100 100 100 100
🔴   processValidationJson.ts 35.63 50 40 34.88 59-98,118-119,157-165,177-178,193-196,201,213-214,222-343,355-358,366
🔴  src/lib 13.12 9.57 11.7 13.43
🟡   auth.ts 62.96 48.48 57.14 65.38 60-61,77-78,84-85,101-102,124,131,134,139-146,170,174
🔴   aws.ts 25.42 18.75 25 25.42 53-58,74-97,121-123,150-171,186-272
🟢   constants.ts 100 100 100 100
🔴   db.ts 45.45 50 50 45.45 15-35,41,43,50
🔴   ec-codes.ts 0 100 100 0 1
🟢   logger.ts 100 100 100 100
🔴   persist-upload.js 0 0 0 0 16-295
🔴   preconditions.ts 0 0 0 0 2-3
🔴   records.js 0 0 0 0 12-214
🔴   templateRules.ts 0 0 0 0
🔴   tracer.ts 0 100 100 0 5-14
🔴   validate-upload.js 0 0 0 0 18-790
🟢   validation-error.ts 83.33 100 50 83.33 22
🔴   validation-rules.js 0 0 0 0 6-194
🟡  src/services/agencies 67.34 50 80 67.34
🟢   agencies.scenarios.ts 100 100 100 100
🟡   agencies.ts 65.21 50 75 65.21 40-51,60-64,97-98,104,113-121
🟡  src/services/expenditureCategories 78.57 66.66 88.88 78.57
🟢   expenditureCategories.scenarios.ts 100 100 100 100
🟡   expenditureCategories.ts 77.77 66.66 88.88 77.77 30-34,49-52,60,91
🟡  src/services/inputTemplates 77.77 66.66 85.71 77.77
🟢   inputTemplates.scenarios.ts 100 100 100 100
🟡   inputTemplates.ts 76.92 66.66 85.71 76.92 25-29,39-40,50,85
🟡  src/services/organizations 75 90.9 50 75
🟢   organizations.scenarios.ts 100 100 100 100
🟡   organizations.ts 73.97 90.9 44.44 73.97 34-35,53-57,92,164-194,202,220-247
🟢  src/services/outputTemplates 82.85 66.66 85.71 82.85
🟢   outputTemplates.scenarios.ts 100 100 100 100
🟢   outputTemplates.ts 82.35 66.66 85.71 82.35 26-30,40-41,51,114
🟡  src/services/passage 74.07 62.5 100 74.07
🟡   passage.ts 74.07 62.5 100 74.07 18-19,65-76
🟡  src/services/projects 80 100 62.5 80
🟢   projects.scenarios.ts 100 100 100 100
🟡   projects.ts 78.57 100 62.5 78.57 45-51
🟢  src/services/reportingPeriodCertifications 100 100 100 100
🟢   reportingPeriodCertifications.scenarios.ts 100 100 100 100
🟢   reportingPeriodCertifications.ts 100 100 100 100
🟡  src/services/reportingPeriods 70.58 60 57.89 71.64
🟢   reportingPeriods.scenarios.ts 100 100 100 100
🟡   reportingPeriods.ts 68.75 60 50 69.84 15-27,44-48,58-59,74-77,93,116,124,165,188-209
🟢  src/services/subrecipientUploads 88.88 83.33 85.71 88.88
🟢   subrecipientUploads.scenarios.ts 100 100 100 100
🟢   subrecipientUploads.ts 86.36 83.33 80 86.36 64,94-99
🟢  src/services/subrecipients 90.19 88.88 92.3 90.19
🟢   subrecipients.scenarios.ts 100 100 100 100
🟢   subrecipients.ts 86.11 88.88 83.33 86.11 63,101-102,108-113
🟡  src/services/uploadValidations 57.14 100 14.28 57.14
🟢   uploadValidations.scenarios.ts 100 100 100 100
🟡   uploadValidations.ts 53.84 100 14.28 53.84 10,16,30,38,45-48
🟢  src/services/uploads 93.2 75 88.88 93.2
🟢   uploads.scenarios.ts 100 100 100 100
🟢   uploads.ts 90.78 75 75 90.78 40,108,136-150
🟢  src/services/users 85.61 82 88.88 85.61
🟢   users.scenarios.ts 100 100 100 100
🟢   users.ts 84.61 82 84.21 84.61 220,237,253,275-277,286-290,308-309,323-326,344-346,354-355,360,369-375
🟢  src/services/validationRuleses 85.71 100 71.42 85.71
🟢   validationRuleses.scenarios.ts 100 100 100 100
🟢   validationRuleses.ts 84.61 100 71.42 84.61 43-48
Coverage report for web suite
St File % Stmts % Branch % Funcs % Lines Uncovered Line #s
🔴 All files 17.57 22.37 15.03 17.18
🟢  api/src/lib 100 100 100 100
🟢   constants.ts 100 100 100 100
🔴  web/src 28.57 18.75 66.66 28.57
🔴   App.tsx 0 0 0 0 3-36
🟢   Routes.tsx 100 100 100 100
🟡   auth.ts 50 50 100 50 19-24
🔴   entry.client.tsx 0 0 100 0 10-22
🔴  web/src/auth 7.14 0 4.16 7.14
🔴   localAuth.ts 9.09 0 8.33 9.09 39-68,76-80
🔴   passageAuth.ts 5 0 0 5 22-25,31-60
🔴  web/src/components/Agency/Agencies 0 100 0 0
🔴   Agencies.tsx 0 100 0 0 9-21
🔴  web/src/components/Agency/AgenciesCell 0 100 0 0
🔴   AgenciesCell.tsx 0 100 0 0 8-39
🔴  web/src/components/Agency/Agency 0 0 0 0
🔴   Agency.tsx 0 0 0 0 10-78
🔴  web/src/components/Agency/AgencyCell 0 100 0 0
🔴   AgencyCell.tsx 0 100 0 0 7-27
🔴  web/src/components/Agency/AgencyForm 0 0 0 0
🔴   AgencyForm.tsx 0 0 0 0 25-45
🔴  web/src/components/Agency/EditAgencyCell 0 100 0 0
🔴   EditAgencyCell.tsx 0 100 0 0 10-59
🔴  web/src/components/Agency/NewAgency 0 100 0 0
🔴   NewAgency.tsx 0 100 0 0 9-35
🟢  web/src/components/Navigation 100 60 100 100
🟢   Navigation.tsx 100 60 100 100 24-68
🔴  web/src/components/Organization/EditOrganizationCell 0 100 0 0
🔴   EditOrganizationCell.tsx 0 100 0 0 13-64
🔴  web/src/components/Organization/EditOrganizationForm 0 0 0 0
🔴   EditOrganizationForm.tsx 0 0 0 0 27-41
🔴  web/src/components/Organization/NewOrganization 0 100 0 0
🔴   NewOrganization.tsx 0 100 0 0 9-37
🔴  web/src/components/Organization/NewOrganizationForm 0 0 0 0
🔴   NewOrganizationForm.tsx 0 0 0 0 25-54
🔴  web/src/components/Organization/Organization 0 0 0 0
🔴   Organization.tsx 0 0 0 0 10-70
🔴  web/src/components/Organization/OrganizationCell 0 100 0 0
🔴   OrganizationCell.tsx 0 100 0 0 7-28
🔴  web/src/components/Organization/OrganizationPickListsCell 40 0 27.27 36.36
🟡   OrganizationPickListsCell.mock.ts 50 100 0 100
🔴   OrganizationPickListsCell.stories.tsx 0 0 0 0 6-32
🟡   OrganizationPickListsCell.tsx 64.28 0 50 58.33 14-16,50-76
🔴  web/src/components/Organization/Organizations 0 100 0 0
🔴   Organizations.tsx 0 100 0 0 9-21
🔴  web/src/components/Organization/OrganizationsCell 0 100 0 0
🔴   OrganizationsCell.tsx 0 100 0 0 8-37
🔴  web/src/components/OutputTemplate/EditOutputTemplateCell 0 100 0 0
🔴   EditOutputTemplateCell.tsx 0 100 0 0 18-81
🔴  web/src/components/OutputTemplate/NewOutputTemplate 0 0 0 0
🔴   NewOutputTemplate.tsx 0 0 0 0 17-126
🔴  web/src/components/OutputTemplate/OutputTemplate 0 0 0 0
🔴   OutputTemplate.tsx 0 0 0 0 17-97
🔴  web/src/components/OutputTemplate/OutputTemplateCell 0 100 0 0
🔴   OutputTemplateCell.tsx 0 100 0 0 17-47
🔴  web/src/components/OutputTemplate/OutputTemplateForm 0 0 0 0
🔴   OutputTemplateForm.tsx 0 0 0 0 18-63
🔴  web/src/components/OutputTemplate/OutputTemplates 0 0 0 0
🔴   OutputTemplates.tsx 0 0 0 0 18-94
🔴  web/src/components/OutputTemplate/OutputTemplatesCell 0 100 0 0
🔴   OutputTemplatesCell.tsx 0 100 0 0 18-52
🔴  web/src/components/ReportingPeriod/EditReportingPeriodCell 0 100 0 0
🔴   EditReportingPeriodCell.tsx 0 100 0 0 13-74
🔴  web/src/components/ReportingPeriod/NewReportingPeriod 0 100 0 0
🔴   NewReportingPeriod.tsx 0 100 0 0 9-35
🔴  web/src/components/ReportingPeriod/ReportingPeriod 0 0 0 0
🔴   ReportingPeriod.tsx 0 0 0 0 12-101
🔴  web/src/components/ReportingPeriod/ReportingPeriodCell 0 100 0 0
🔴   ReportingPeriodCell.tsx 0 100 0 0 7-33
🔴  web/src/components/ReportingPeriod/ReportingPeriodForm 0 0 0 0
🔴   ReportingPeriodForm.tsx 0 0 0 0 18-43
🟡  web/src/components/ReportingPeriod/ReportingPeriods 71.42 38.46 55.55 71.42
🟡   ReportingPeriods.tsx 67.74 44.44 41.66 67.74 47-52,59-60,66,81,116-133
🟢   columns.tsx 81.81 25 83.33 81.81 36-40
🟡  web/src/components/ReportingPeriod/ReportingPeriodsCell 55 0 55.55 47.05
🟢   ReportingPeriodsCell.mock.ts 100 100 100 100
🔴   ReportingPeriodsCell.stories.tsx 0 0 0 0 6-32
🟢   ReportingPeriodsCell.tsx 100 100 100 100
🔴  web/src/components/Subrecipient/SubrecipientTableUploadLinksDisplay 0 0 0 0
🔴   SubrecipientTableUploadLinksDisplay.stories.tsx 0 100 100 0 5-82
🔴   SubrecipientTableUploadLinksDisplay.tsx 0 0 0 0 14-42
🔴  web/src/components/Subrecipient/Subrecipients 0 0 0 0
🔴   Subrecipients.tsx 0 100 0 0 5-8
🔴   columns.tsx 0 0 0 0 7-93
🔴  web/src/components/Subrecipient/SubrecipientsCell 0 100 0 0
🔴   SubrecipientsCell.tsx 0 100 0 0 7-60
🟢  web/src/components/TableBuilder 83.72 72 78.94 82.92
🟡   DebouncedInput.tsx 80 100 66.66 77.77 21,32
🟡   Filter.tsx 75 100 50 75 10
🟡   TableBuilder.tsx 73.33 40 80 71.42 40-42,50
🟢   TableHeader.tsx 100 91.66 100 100 13
🟢   TableRow.tsx 100 100 100 100
🟡  web/src/components/TemplateUploadReportingPeriodCell 55 0 55.55 47.05
🟢   TemplateUploadReportingPeriodCell.mock.ts 100 100 100 100
🔴   TemplateUploadReportingPeriodCell.stories.tsx 0 0 0 0 11-37
🟢   TemplateUploadReportingPeriodCell.tsx 100 100 100 100
🔴  web/src/components/TreasuryGeneration/DownloadTreasuryFiles 0 0 0 0
🔴   DownloadTreasuryFiles.tsx 0 0 0 0 7-68
🔴  web/src/components/TreasuryGeneration/NewTreasuryGeneration 0 100 0 0
🔴   NewTreasuryGeneration.tsx 0 100 0 0 8-39
🔴  web/src/components/TreasuryGeneration/NewTreasuryGenerationForm 0 0 0 0
🔴   NewTreasuryGenerationForm.tsx 0 0 0 0 20-31
🔴  web/src/components/Upload/EditUploadCell 0 100 0 0
🔴   EditUploadCell.tsx 0 100 0 0 10-66
🔴  web/src/components/Upload/NewUpload 0 100 0 0
🔴   NewUpload.tsx 0 100 0 0 7-35
🔴  web/src/components/Upload/Upload 0 0 0 0
🔴   Upload.stories.tsx 0 100 100 0 5-93
🔴   Upload.tsx 0 0 0 0 16-119
🔴  web/src/components/Upload/UploadCell 0 100 0 0
🔴   UploadCell.tsx 0 100 0 0 7-60
🔴  web/src/components/Upload/UploadForm 0 0 0 0
🔴   UploadForm.tsx 0 0 0 0 23-108
🔴  web/src/components/Upload/UploadValidationButtonGroup 0 0 0 0
🔴   UploadValidationButtonGroup.stories.tsx 0 100 0 0 5-47
🔴   [UploadValidationButtonGroup.tsx](https://github.com/usdigitalresponse/cpf-reporter/blob/ec43...*[Comment body truncated]*

Copy link

github-actions bot commented Nov 2, 2024

Terraform Summary

Pusher: @as1729, Action: pull_request_target, Workflow: Continuous Integration

Step Result
🖌 Terraform Format & Style
⚙️ Terraform Initialization
🤖 Terraform Validation
📖 Terraform Plan

Hint: If "Terraform Format & Style" failed, run terraform fmt -recursive from the terraform/ directory and commit the results.

Output

Validation Output
Success! The configuration is valid.


Plan Summary
CHANGE RESOURCE
add aws_s3_object.origin_dist_artifact["static/js/app.82adbeb8.js"]
aws_s3_object.origin_dist_artifact["static/js/app.82adbeb8.js.LICENSE.txt"]
update aws_ecs_service.console
aws_s3_object.origin_dist_artifact["200.html"]
aws_s3_object.origin_dist_artifact["build-manifest.json"]
aws_s3_object.origin_dist_artifact["chunk-references.json"]
aws_s3_object.origin_dist_artifact["index.html"]
module.lambda_function-cpfCreateArchive.aws_lambda_function.this[0]
module.lambda_function-cpfValidation.aws_lambda_function.this[0]
module.lambda_function-email-presigned-url.aws_lambda_function.this[0]
module.lambda_function-graphql.aws_lambda_function.this[0]
module.lambda_function-processValidationJson.aws_lambda_function.this[0]
module.lambda_function-subrecipientTreasuryReportGen.aws_lambda_function.this[0]
module.lambda_function-treasuryProjectFileGeneration.aws_lambda_function.this[0]
recreate aws_ecs_task_definition.console
aws_s3_object.lambda_artifact-graphql
aws_s3_object.lambda_artifact-processValidationJson
aws_s3_object.lambda_artifact-python
module.lambda_function-cpfCreateArchive.aws_lambda_permission.current_version_triggers["StepFunctionTrigger"]
module.lambda_function-cpfValidation.aws_lambda_permission.current_version_triggers["S3BucketNotification"]
module.lambda_function-email-presigned-url.aws_lambda_permission.current_version_triggers["StepFunctionTrigger"]
module.lambda_function-graphql.aws_lambda_permission.current_version_triggers["APIGateway"]
module.lambda_function-processValidationJson.aws_lambda_permission.current_version_triggers["S3BucketNotification"]
module.lambda_function-subrecipientTreasuryReportGen.aws_lambda_permission.current_version_triggers["StepFunctionTrigger"]
module.lambda_function-treasuryProjectFileGeneration.aws_lambda_permission.current_version_triggers["S3BucketNotification"]
module.lambda_function-treasuryProjectFileGeneration.aws_lambda_permission.current_version_triggers["StepFunctionTrigger"]
delete aws_s3_object.origin_dist_artifact["static/js/app.61ca8613.js"]
aws_s3_object.origin_dist_artifact["static/js/app.61ca8613.js.LICENSE.txt"]

@github-actions github-actions bot added the python label Nov 3, 2024
@nowei
Copy link
Contributor Author

nowei commented Nov 3, 2024

Post refactor:
Mypy strict output (generally not strict):

python/src/lib/logging.py:8: error: Missing type parameters for generic type "Callable"  [type-arg]
python/src/lib/logging.py:21: error: Missing type parameters for generic type "Callable"  [type-arg]
python/src/lib/logging.py:44: error: Missing type parameters for generic type "Callable"  [type-arg]
python/tests/src/lib/test_workbook_validator.py:44: error: Untyped decorator makes function "test_empty_row_data" untyped  [misc]
python/tests/src/lib/test_workbook_validator.py:55: error: Untyped decorator makes function "test_non_empty_row_data" untyped  [misc]
python/tests/conftest.py:28: error: Untyped decorator makes function "valid_file" untyped  [misc]
python/tests/conftest.py:34: error: Untyped decorator makes function "valid_workbook" untyped  [misc]
python/tests/conftest.py:39: error: Untyped decorator makes function "valid_workbook_old_schema" untyped  [misc]
python/tests/conftest.py:44: error: Untyped decorator makes function "valid_workbook_old_compatible_schema" untyped  [misc]
python/tests/conftest.py:51: error: Untyped decorator makes function "valid_coversheet" untyped  [misc]
python/tests/conftest.py:58: error: Untyped decorator makes function "valid_project_sheet" untyped  [misc]
python/tests/conftest.py:65: error: Untyped decorator makes function "valid_workbook_1A" untyped  [misc]
python/tests/conftest.py:70: error: Untyped decorator makes function "valid_project_sheet_1A" untyped  [misc]
python/tests/conftest.py:75: error: Untyped decorator makes function "valid_workbook_1A_with_conflict" untyped  [misc]
python/tests/conftest.py:83: error: Untyped decorator makes function "valid_second_workbook_1A_sheet" untyped  [misc]
python/tests/conftest.py:94: error: Untyped decorator makes function "valid_workbook_1B" untyped  [misc]
python/tests/conftest.py:99: error: Untyped decorator makes function "valid_project_sheet_1B" untyped  [misc]
python/tests/conftest.py:104: error: Untyped decorator makes function "valid_workbook_1B_with_conflict" untyped  [misc]
python/tests/conftest.py:112: error: Untyped decorator makes function "valid_second_workbook_1B_sheet" untyped  [misc]
python/tests/conftest.py:123: error: Untyped decorator makes function "valid_workbook_1C" untyped  [misc]
python/tests/conftest.py:128: error: Untyped decorator makes function "valid_project_sheet_1C" untyped  [misc]
python/tests/conftest.py:133: error: Untyped decorator makes function "valid_workbook_1C_with_conflict" untyped  [misc]
python/tests/conftest.py:141: error: Untyped decorator makes function "valid_second_workbook_1C_sheet" untyped  [misc]
python/tests/conftest.py:152: error: Untyped decorator makes function "valid_subrecipientsheet" untyped  [misc]
python/tests/conftest.py:159: error: Untyped decorator makes function "invalid_cover_sheet" untyped  [misc]
python/tests/conftest.py:165: error: Untyped decorator makes function "invalid_cover_sheet_missing_code" untyped  [misc]
python/tests/conftest.py:173: error: Untyped decorator makes function "invalid_cover_sheet_empty_code" untyped  [misc]
python/tests/conftest.py:181: error: Untyped decorator makes function "invalid_cover_sheet_empty_desc" untyped  [misc]
python/tests/conftest.py:189: error: Untyped decorator makes function "invalid_project_sheet" untyped  [misc]
python/tests/conftest.py:195: error: Untyped decorator makes function "invalid_project_sheet_missing_field" untyped  [misc]
python/tests/conftest.py:203: error: Untyped decorator makes function "invalid_project_sheet_empty_field" untyped  [misc]
python/tests/conftest.py:211: error: Untyped decorator makes function "invalid_project_sheet_unmatching_subrecipient_tin_field" untyped  [misc]
python/tests/conftest.py:219: error: Untyped decorator makes function "invalid_project_sheet_unmatching_subrecipient_uei_field" untyped  [misc]
python/tests/conftest.py:227: error: Untyped decorator makes function "invalid_project_sheet_unmatching_subrecipient_tin_uei_field" untyped  [misc]
python/tests/conftest.py:236: error: Untyped decorator makes function "invalid_subrecipient_sheet" untyped  [misc]
python/tests/conftest.py:244: error: Untyped decorator makes function "valid_subrecipient_sheet_blank_optional_fields" untyped  [misc]
python/tests/conftest.py:254: error: Untyped decorator makes function "sample_template" untyped  [misc]
python/tests/conftest.py:259: error: Untyped decorator makes function "template_workbook" untyped  [misc]
python/tests/conftest.py:264: error: Untyped decorator makes function "template_workbook_two" untyped  [misc]
python/tests/conftest.py:269: error: Untyped decorator makes function "cpf_file_archive" untyped  [misc]
python/tests/conftest.py:276: error: Untyped decorator makes function "cpf_file_archive_two" untyped  [misc]
python/tests/conftest.py:284: error: Untyped decorator makes function "output_1A_template" untyped  [misc]
python/tests/conftest.py:289: error: Untyped decorator makes function "output_1B_template" untyped  [misc]
python/tests/conftest.py:294: error: Untyped decorator makes function "output_1C_template" untyped  [misc]
python/tests/conftest.py:299: error: Untyped decorator makes function "valid_aws_typing_context" untyped  [misc]
python/tests/conftest.py:314: error: Untyped decorator makes function "valid_subrecipients_json_content" untyped  [misc]
python/tests/conftest.py:357: error: Untyped decorator makes function "sample_subrecipients_generation_event" untyped  [misc]
python/tests/conftest.py:369: error: Untyped decorator makes function "sample_subrecipients_lambda_payload" untyped  [misc]
python/tests/conftest.py:381: error: Untyped decorator makes function "invalid_json_content" untyped  [misc]
python/tests/conftest.py:386: error: Untyped decorator makes function "no_subrecipients_key_json_content" untyped  [misc]
python/tests/conftest.py:391: error: Untyped decorator makes function "no_subrecipients_list_json_content" untyped  [misc]
python/tests/conftest.py:396: error: Untyped decorator makes function "empty_subrecipients_list_json_content" untyped  [misc]
python/tests/conftest.py:401: error: Untyped decorator makes function "subrecipients_no_uploads" untyped  [misc]
python/tests/conftest.py:406: error: Untyped decorator makes function "empty_subrecipient_treasury_template" untyped  [misc]
python/tests/conftest.py:411: error: Untyped decorator makes function "sample_subrecipient_uploads_with_dates" untyped  [misc]
Found 55 errors in 3 files (checked 35 source files)

Test results:

root@b429cb3a21a8:/home/node/app/python# poetry run pytest
============================================================================================== test session starts ==============================================================================================
platform linux -- Python 3.12.3, pytest-8.3.2, pluggy-1.5.0
rootdir: /home/node/app/python
configfile: pyproject.toml
plugins: cov-5.0.0
collected 84 items

tests/src/lib/test_create_archive.py ...                                                                                                                                                                  [  3%]
tests/src/lib/test_output_template_comparator.py ......                                                                                                                                                   [ 10%]
tests/src/lib/test_subrecipient_treasury_report_gen.py ................                                                                                                                                   [ 29%]
tests/src/lib/test_treasury_report_1A.py ...........                                                                                                                                                      [ 42%]
tests/src/lib/test_treasury_report_1B.py ...........                                                                                                                                                      [ 55%]
tests/src/lib/test_treasury_report_1C.py ...........                                                                                                                                                      [ 69%]
tests/src/lib/test_workbook_validator.py ..........................                                                                                                                                       [100%]

---------- coverage: platform linux, python 3.12.3-final-0 -----------
Name                                                     Stmts   Miss Branch BrPart  Cover
------------------------------------------------------------------------------------------
src/__init__.py                                              0      0      0      0   100%
src/functions/__init__.py                                    0      0      0      0   100%
src/functions/create_archive.py                             63     21     18      3    70%
src/functions/generate_presigned_url_and_send_email.py      56     56     10      0     0%
src/functions/generate_treasury_report.py                  196    103     72      4    46%
src/functions/subrecipient_treasury_report_gen.py          115     23     35      3    80%
src/functions/test_lambdas.py                                9      4      2      0    64%
src/functions/validate_workbook.py                          55     55      8      0     0%
src/lib/__init__.py                                          0      0      0      0   100%
src/lib/constants.py                                        10      0      0      0   100%
src/lib/email.py                                            17     17      0      0     0%
src/lib/logging.py                                          19      1      4      1    91%
src/lib/output_template_comparator.py                      114     50     38      0    50%
src/lib/s3_helper.py                                        37     24      0      0    35%
src/lib/treasury_generation_common.py                       34     10      2      0    67%
src/lib/workbook_utils.py                                   31     18     10      1    34%
src/lib/workbook_validator.py                              208     17     56      8    91%
src/schemas/__init__.py                                      0      0      0      0   100%
src/schemas/custom_types.py                                 23      0     10      2    94%
src/schemas/project_types.py                                14      0      6      0   100%
src/schemas/schema_V2024_04_01.py                          295     37     78      0    84%
src/schemas/schema_V2024_05_24.py                          323     18     78      8    93%
src/schemas/schema_versions.py                             103     16     36      8    81%
------------------------------------------------------------------------------------------
TOTAL                                                     1722    470    463     38    71%
Coverage HTML written to dir htmlcov


========================================================================================= 84 passed in 64.86s (0:01:04) =========================================================================================

@nowei nowei requested a review from as1729 November 3, 2024 22:36
@as1729
Copy link
Contributor

as1729 commented Nov 4, 2024

@nowei do we need to address the remaining errors in the mypy strict output above in a separate follow-up PR?

@nowei
Copy link
Contributor Author

nowei commented Nov 4, 2024

No, most of the strict errors are from untyped decorators from libraries like pytest or trying to type the callable functions in structlog. I fixed all the normal mypy issues and most of the strict ones, but the strict ones don't show up normally in the non-strict setting.

Also this should get merged after the other pre-commit changes get merged 😅

@nowei
Copy link
Contributor Author

nowei commented Nov 4, 2024

The step after would be to add a mypy checker to the CI

Base automatically changed from nowei/pre-commit to main November 15, 2024 19:30
@nowei
Copy link
Contributor Author

nowei commented Nov 21, 2024

Can we merge this PR in first so the new tickets I'm working on won't conflict with this PR?

@as1729 as1729 merged commit 33b9c63 into main Nov 21, 2024
22 checks passed
@as1729 as1729 deleted the nowei/mypy-checking branch November 21, 2024 16:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants