Drop the type ignore comment from error classification

ty accepts the lookup without it, and the project keeps code free of
comments.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01V1d3RLHNBBMA6UqBLLJv27
This commit is contained in:
Artyom
2026-10-29 23:12:45 +03:00
co-authored by Claude Opus 5.5
parent a761b718b8
commit e9242816a5
2 changed files with 2 additions and 2 deletions
@@ -1,7 +1,7 @@
## 1. Требования и код
- [x] 1.1 Тест порядка проверок `POST …/messages` для постороннего (`test_request_shape_is_checked_before_access`)
- [ ] 1.2 Убрать `# type: ignore` из `shared/entrypoints/errors.py`
- [x] 1.2 Убрать `# type: ignore` из `shared/entrypoints/errors.py`
- [ ] 1.3 `openspec/config.yaml`: `gunicorn_conf.py` в карте модулей
- [ ] 1.4 Проверка группы: `make lint`, `make student-test`, `make check`
+1 -1
View File
@@ -46,7 +46,7 @@ class Unauthenticated(Exception):
def classify(error: DomainError, codes: ErrorCodes) -> tuple[str, int]:
for kind in type(error).__mro__:
known = codes.get(kind) # type: ignore[arg-type]
known = codes.get(kind)
if known is not None:
return known
return "internal_error", status.HTTP_500_INTERNAL_SERVER_ERROR