Files
gochat/docs/parity/placeholder-audit.md
T
rogee 0dabb8cfa5 docs: 整理文档目录结构 — 清理过时文档、归集功能子目录、统一命名规范
清理:
- 删除 34 份过时文档(gap reports/QA临时报告/验收报告/阶段性文档)
- 删除 docs/.hermes/skills 第三方 skills 副本(16 文件)
- 删除 skills-lock.json

目录归集:
- 根目录仅保留 README.md 索引
- product/ — 产品与架构设计(PRD + ARCHITECTURE + P2设计文档 + AI/企业路线图)
- tracking/ — Chatwoot parity 开发跟踪
- requirements/ — M01-M12 模块需求
- plans/ — 历史实现计划
- parity/ — 路由 parity 与前端契约
- qa/ — QA 报告与测试计划
- ops/ — 运维部署

命名规范:
- 全小写 kebab-case,禁止全大写文件名
- product/tracking/ops 用 NN- 序号前缀
- requirements 用 MNN- 两位零填充模块号
- plans/qa 用 YYYY-MM-DD- 日期前缀
- requirements M1-M9 零填充为 M01-M09(修复字典序)

同步更新:
- backend/cmd/route_parity/main.go 路径默认值
- backend/scripts/parity_frontend_smoke.sh 报告路径
- 所有 docs 内部交叉引用
- .gitignore 排除编译产物 (backend/gochat, backend/route_parity)
- 新增迁移 000052/000053
- 前端 WS 相关修改
2026-07-09 14:53:27 +08:00

42 lines
2.7 KiB
Markdown

# Phase 6 Placeholder Audit
Updated: 2026-06-07
## Commands
```bash
rg -n "chatwootParityStub" internal/handler internal/service internal/router internal/channel
rg -n "chatwootParityStub" internal/router/router.go | wc -l
rg -n "chatwootParityStub|TODO|placeholder|stub|not implemented|unsupported" internal/handler internal/service internal/router -g'*.go'
scripts/parity_frontend_smoke.sh --check
```
## Result
`chatwootParityStub` has been removed from product code. The exact scan returns no matches.
The broader placeholder scan still has no reused-frontend critical account/contact/conversation/message/inbox/widget/public handler placeholder. Non-stub matches are test doubles, expected validation errors such as unsupported file/search/bulk-action operations, excluded SSO/SAML placeholder notes, or explicit assertions that nil webhook fallbacks do not return placeholder bodies.
The previously remaining call sites were nil-handler guards for public webhook registration paths:
- Telegram webhook callback.
- WhatsApp verify and event callbacks.
- TikTok verify and event callbacks.
- LINE event callback.
- Twilio SMS, delivery status, and root callback aliases.
- Twitter CRC and event callbacks, including legacy aliases.
- Instagram verify and event callbacks.
- Shopify webhook callback.
No `chatwootParityStub` call site remains on any reused dashboard account/contact/conversation/message/inbox API path, widget API path, public help-center path, public inbox/contact/conversation/message API path, enterprise settings API path, or webhook fallback path.
## Classification
The former defensive nil-handler fallbacks now return explicit `503 { error: "webhook provider unavailable", message: "webhook handler is not configured" }` responses instead of placeholder/not-implemented bodies. In normal app bootstrap the matching provider handlers are wired and these branches do not define the route behavior. Provider-specific webhook behavior remains owned by the existing webhook/channel parity slices and future B12 or provider fixture failures.
Phase 6 is therefore in Review for the inspected placeholder surface. Reopen it only if a fresh `rg` audit or reused frontend smoke identifies a frontend-reachable `chatwootParityStub`, `not implemented`, or placeholder success response in account/contact/conversation/message/inbox/widget/public critical paths.
## B12 Readiness
`scripts/parity_frontend_smoke.sh --check` passed and refreshed `docs/parity/frontend-smoke-report.md`. The first check attempt failed because `/tmp` was full; rerunning with workspace-local `GOCACHE`, `GOTMPDIR`, and `TMPDIR` succeeded. Live API/browser/enterprise smoke remains pending because it requires the full PostgreSQL, Redis, Meilisearch, GoChat, Vite, and Chrome stack.