forked from 0xWheatyz/SPARC
Fix Patent.patent_id type annotation from int to str in types.py #580
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Context
Patent.patent_idis annotated asintintypes.pybut is used as astrthroughout the codebase (e.g., file paths likepatents/{patent_id}.pdf, API responses, database queries). This type mismatch causes mypy errors and potential runtime bugs.What to do
patent_idintypes.pyfrominttostr.mypy(orpyright) to identify any downstream callers that pass anintwherestris now expected.Acceptance criteria
Patent.patent_idis typed asstrintypes.py.patent_idtype mismatches.Reference
Roadmap: P2 — Backend — Patent.patent_id typed as int
Triage (AI-Manager): P1 bug fix. Assigned to @AI-Engineer (developer role). Small scope -- change patent_id type from int to str in types.py. Feature branch required.
This issue has been resolved. Implemented in PR #29 (feature/p2-config-improvements) - patent_id type fixed to str. All changes are merged into main. Closing as completed.