fix(awooop): keep callback audit summary stable
This commit is contained in:
@@ -20268,6 +20268,24 @@ pnpm --dir apps/web lint -- --file 'src/app/[locale]/awooop/runs/page.tsx'
|
||||
NEXT_PUBLIC_API_URL=https://awoooi.wooo.work pnpm --dir apps/web run build
|
||||
```
|
||||
|
||||
**T183b production smoke hotfix**:
|
||||
|
||||
- 首次 production smoke `/api/v1/platform/runs/callback-replies?project_id=awoooi&per_page=2` 回傳 HTTP 500。
|
||||
- root cause:`list_callback_replies()` 的 API 頂層 coverage `summary` 被每筆 callback event 的 KM completion `summary` 區域變數覆蓋,FastAPI response validation 收到 `km_stale_owner_review_completion_callback_summary_v1`,因此不符合 `telegram_callback_reply_audit_summary_v1` schema。
|
||||
- 修正:
|
||||
- API 頂層 coverage 改名為 `audit_summary`。
|
||||
- 每筆事件的 KM completion summary 改名為 `km_summary`。
|
||||
- response 固定回傳 `"summary": audit_summary`。
|
||||
- 新增 regression test 防止 audit summary / KM summary 再次 shadowing。
|
||||
- hotfix local validation:
|
||||
|
||||
```text
|
||||
python3 -m py_compile apps/api/src/services/platform_operator_service.py apps/api/tests/test_awooop_operator_timeline_labels.py
|
||||
git diff --check
|
||||
PYTHONPATH=. DATABASE_URL='postgresql+asyncpg://test:test@localhost/test' /Users/ogt/.pyenv/shims/pytest tests/test_awooop_operator_timeline_labels.py -q
|
||||
52 passed in 0.80s
|
||||
```
|
||||
|
||||
**目前整體進度**:
|
||||
|
||||
- AwoooP 告警可觀測鏈:約 99.52%。
|
||||
|
||||
Reference in New Issue
Block a user