Consistent and strict type hints improve maintainability, IDE autocompletion, and static analysis accuracy.
This issue proposes to:
- Add explicit type hints to
__aexit__ methods (currently untyped in core/rate_limit.py).
-
- Add return type hints to
lifespan and other @asynccontextmanager methods (e.g., in api/app.py and messaging/trees/data.py).
-
-
- Tighten type hints for configuration validators in
config/settings.py to avoid Any where possible.
-
-
-
- Improve Ollama base URL validation error message for better clarity.
While the current ty check may pass without these, adding them ensures the codebase adheres to the strict engineering standards mentioned in AGENTS.md.
Consistent and strict type hints improve maintainability, IDE autocompletion, and static analysis accuracy.
This issue proposes to:
__aexit__methods (currently untyped incore/rate_limit.py).lifespanand other@asynccontextmanagermethods (e.g., inapi/app.pyandmessaging/trees/data.py).config/settings.pyto avoidAnywhere possible.While the current
ty checkmay pass without these, adding them ensures the codebase adheres to the strict engineering standards mentioned inAGENTS.md.