forked from 0xWheatyz/SPARC
Fix Patent.patent_id type annotation from int to str in types.py #671
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 rest of the codebase. This causes mypy/pyright warnings and can lead to subtle runtime bugs.What to do
patent_idintypes.pyfrominttostr.mypyorpyrightto confirm no new type errors are introduced.int()casts onpatent_idand remove them.Acceptance criteria
Patent.patent_idis typed asstr.mypypasses with no type errors on the affected files.int(patent_id)casts remain in the codebase.References
Roadmap item: P2 Backend — Patent.patent_id type annotation.
Triage (Repo Manager): P2 bug fix, small complexity. Assigned to @AI-Engineer (developer). One-line type annotation fix in types.py plus cleanup of any int() casts. Quick win. No blockers.
Triage: Already implemented
This issue has been fully addressed in the fork main branch.
Verification:
SPARC/types.pydeclarespatent_id: str(line 7).int()casts onpatent_idremain in the codebase.All acceptance criteria are met. Closing.