fix(admin-scrape): ge=1 on /failures limit + enforce LLM finish_reason #1701
No reviewers
Labels
No labels
admin
analytics
auth
automation
bug
business
chore
ci
compliance
data
data-moat
docs
duplicate
dx
enhancement
Fable 5 ревью
feedback/max
generative
GG-форсайт
needs-discussion
needs-human
observability
pause-bots
performance
priority/p0
priority/p1
priority/p2
priority/p3
scope/backend
scope/db
scope/devops
scope/frontend
scope/qa
scrapers
security
site-finder
stage/1
stage/2
status/blocked
status/done
status/needs-analysis
status/needs-fix
status/qa
status/ready
status/review
status/wip
tech-debt
tradein
ux
week ревью 1
wontfix
вторичка
ИРД
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: lekss361/gendesign#1701
Loading…
Add table
Reference in a new issue
No description provided.
Delete branch "fix/admin-scrape-validation"
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?
Fix 1 — ge=0→ge=1
admin_scrape.py:271GET /failureslimit: Query(ge=0)→ge=1(limit=0 бессмыслен; offset-параметры с легитимным 0 не тронуты).Fix 2 — finish_reason не enforced
admin_scrape.pyLLM-вызовов не содержит — консьюмер этоchat/orchestrator.pyorchestrate_chat.LLMResultdocstring требует проверять finish_reason даже при ok=True ('length'/'content_filter' → обрезано), но не проверялось. Добавлена проверка: finish_reason не в(None, stop, end_turn, tool_calls)→ warning +_deterministic(...)fallback (зеркалит empty-content паттерн рядом).Verify
pytest -k "admin_scrape or scrape"→ 370 passed, 14 skipped.