guke
|
347c4c7de4
|
feat(compare-alert): 卡点独立成列(AlertHit.stuck_point + 卡片第5列),reason 去重简化
- AlertHit 加 stuck_point: str | None = None 字段(格式化好的「平台·环节 帧/s」)
- classify_cancelled_fallback reason 简化为「深度放弃」(耗时/步数已在「用时」列,不重复)
- build_hits 加 _fmt_stuck helper;cancelled 卡死 stuck_point=「美团·加菜 110帧/32s」;
failed stuck_point=环节标签、reason 不再附「卡在 X」
- format_alert_card 列序改为 时间/手机号/用时/失败原因/卡点/版本/trace (7列)
- 同步更新 test_compare_alert_stuck_worker / _fallback / _format / _rules 断言
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
2026-08-05 16:47:23 +08:00 |
|
guke
|
924e40a84e
|
feat(compare-alert): 固化飞书卡片 table 格式(format_alert_card + send_feishu_card),worker 切换
- feishu_notifier: 新增 send_feishu_card(interactive msg_type,复用 _post_feishu)
- compare_alert_format: 新增 format_alert_card(schema 2.0, header red, markdown摘要+table 6列)
- 列序: 时间/手机号/用时/失败原因/版本/trace(lark_md);无 width 属性
- cost 列 helper _cost_cell: total_ms→Ns / step_count→M步 / 两者用" / "连 / 都无给"-"
- 截断: 超 max_total 只出摘要; 空 hits 返回「本期无异常」卡片
- 保留 format_alert_message / format_alert_post(有测试依赖)
- compare_alert_worker: _send(post) → _send_card(card); _scan_and_alert 调 format_alert_card
- SEND_EMPTY 分支: 传空 hits 给 format_alert_card 得「本期无异常」卡片
- webhook 空降级保留; build_hits/水位逻辑不动
- tests: format/feishu/worker 测试全适配新接口,86 passed 零回归
- 删除临时脚本 scripts/_test_alert_card.py
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
2026-08-05 15:37:13 +08:00 |
|