Files
gochat/docs/QA_REPORT_2026-07-08_cdp_round2.md
T
2026-07-09 13:59:31 +08:00

9.2 KiB

QA Report — CDP Full-Page Testing (Round 2)

Date: 2026-07-08 Environment: backend (:3000) + frontend Vite (:3036), CDP browser at :9222 Login: admin@gochat.local / changeme Test Plan: TEST_PLAN_2026-07-08_cdp_full_page_testing.md


Summary

All 23 pages in the test plan were tested via click-based navigation (no direct URL input except the initial login page). Every page passed with zero console errors and zero console warnings. A message was sent in a conversation and appeared instantly via WebSocket — confirming the BUG-4 prop-type fix works correctly.

One new critical bug was found and fixed during testing: missing database tables causing 500 errors on 6 API endpoints, which prevented the frontend app from mounting at all.


Bugs Fixed This Round

BUG-7 (P0 Critical) — Missing database tables causing 500 errors on 6 API endpoints

Symptom: After backend restart, the frontend app failed to mount (#app had 0 children). Network inspection showed 500 errors on:

  • GET /api/v1/accounts/1/conversations/unread_counts — relation "conversation_labels" does not exist
  • GET /api/v1/accounts/1/notifications — column "snoozed_until" does not exist
  • GET /api/v1/accounts/1/custom_attribute_definitions/ — relation "custom_attribute_definitions" does not exist
  • GET /api/v1/accounts/1/agent_bots — relation "agent_bots" does not exist
  • GET /api/v1/accounts/1/custom_filters/?filter_type=conversation — relation "custom_filters" does not exist
  • GET /api/v1/accounts/1/custom_filters/?filter_type=contact — relation "custom_filters" does not exist

Root Cause: The Bootstrap() function in bootstrap.go runs SQL migrations via database.RunMigrations() but never calls autoMigrate() (the GORM AutoMigrate function defined in app.go). The app.New() function (which does call autoMigrate) is not used in the main code path. As a result, any model table not created by a numbered SQL migration file was missing from the database.

The missing tables included: conversation_labels, agent_bots, agent_bot_inboxes, agent_bot_presence_events, custom_attribute_definitions, custom_filters, conversation_participants, csat_templates, delivery_statuses, draft_messages, email_channel_migrations, inbox_limits, notes, contact_notes, notification_subscriptions, sso_sessions, whatsapp_calls, plus many tables already in the AutoMigrate list but also never created (pre_chat_forms, widget_theme_configs, working_hours, direct_uploads, etc.).

Additionally, the notifications table (created by a migration) was missing the snoozed_until column that was added to the Notification model but never migrated.

Fix: Created migration 000053_add_missing_model_tables which creates all missing tables using CREATE TABLE IF NOT EXISTS (idempotent) and adds the snoozed_until column via ALTER TABLE ... ADD COLUMN IF NOT EXISTS.

Files changed:

  • backend/migrations/000053_add_missing_model_tables.up.sql (new)
  • backend/migrations/000053_add_missing_model_tables.down.sql (new)

Verification: All 6 previously-failing API endpoints now return HTTP 200. Frontend app mounts correctly after login.

BUG-5 (P1 High) — NotificationSetting handler not registered (fixed by prior agent)

Fix applied by prior agent: Added NotificationSettingHandler registration to bootstrap.go. Verified working — GET /api/v1/accounts/1/notification_settings returns 200.

Files changed:

  • backend/internal/app/bootstrap.go (lines 198, 560, 836)

BUG-4 (P3 Low) — Vue prop type mismatch on message ID (fixed by prior agent)

Fix applied by prior agent: Changed id prop type from Number to [Number, String] in Message.vue and MessageList.vue.

Verification this round: Sent a message ("CDP test round 3 - verifying WS delivery") in conversation #1. Message appeared instantly in the chat. Zero Vue warnings in the console — confirming the prop type fix works.

Files changed:

  • frontend/app/javascript/dashboard/components-next/message/Message.vue (line 104)
  • frontend/app/javascript/dashboard/components-next/message/MessageList.vue (line 25)

Page-by-Page Test Results

All pages tested via click-based navigation (sidebar links, JS click on hidden sidebar links, profile dropdown). No direct URL input except login.

# Page URL Console Network Status
1 Dashboard /app/accounts/1/dashboard 0 errors, 0 warnings Clean PASS
2 Conversation detail /app/accounts/1/conversations/1 0 errors, 0 warnings Clean, message sent OK PASS
3 Contacts /app/accounts/1/contacts 0 errors, 0 warnings Clean PASS
4 Reports — Overview /app/accounts/1/reports/overview 0 errors, 0 warnings Clean PASS
5 Reports — Conversations /app/accounts/1/reports/conversation 0 errors, 0 warnings Clean PASS
6 Reports — Agents /app/accounts/1/reports/agents_overview 0 errors, 0 warnings Clean PASS
7 Reports — Labels /app/accounts/1/reports/labels_overview 0 errors, 0 warnings Clean PASS
8 Reports — Inboxes /app/accounts/1/reports/inboxes_overview 0 errors, 0 warnings Clean PASS
9 Reports — Teams /app/accounts/1/reports/teams_overview 0 errors, 0 warnings Clean PASS
10 Reports — CSAT /app/accounts/1/reports/csat 0 errors, 0 warnings Clean PASS
11 Reports — SLA /app/accounts/1/reports/sla 0 errors, 0 warnings Clean PASS
12 Reports — Bot /app/accounts/1/reports/bot 0 errors, 0 warnings Clean PASS
13 Activity (live_chat) /app/accounts/1/campaigns/live_chat 0 errors, 0 warnings Clean PASS
14 Help Center /app/accounts/1/portals/.../articles 0 errors, 0 warnings Clean PASS
15 Settings — General /app/accounts/1/settings/general 0 errors, 0 warnings Clean PASS
16 Settings — Agents /app/accounts/1/settings/agents/list 0 errors, 0 warnings Clean PASS
17 Settings — Teams /app/accounts/1/settings/teams/list 0 errors, 0 warnings Clean PASS
18 Settings — Assignment /app/accounts/1/settings/assignment-policy/index 0 errors, 0 warnings Clean PASS
19 Settings — Inboxes /app/accounts/1/settings/inboxes/list 0 errors, 0 warnings Clean PASS
20 Settings — Labels /app/accounts/1/settings/labels/list 0 errors, 0 warnings Clean PASS
21 Settings — Custom Attributes /app/accounts/1/settings/custom-attributes/list 0 errors, 0 warnings Clean PASS
22 Settings — Automation /app/accounts/1/settings/automation/list 0 errors, 0 warnings Clean PASS
23 Settings — Agent Bots /app/accounts/1/settings/agent-bots 0 errors, 0 warnings Clean PASS
24 Settings — Macros /app/accounts/1/settings/macros 0 errors, 0 warnings Clean PASS
25 Settings — Canned Responses /app/accounts/1/settings/canned-response/list 0 errors, 0 warnings Clean PASS
26 Settings — Integrations /app/accounts/1/settings/integrations 0 errors, 0 warnings Clean PASS
27 Settings — Conversation Workflow /app/accounts/1/settings/conversation-workflow 0 errors, 0 warnings Clean PASS
28 Profile /app/accounts/1/profile/settings 0 errors, 0 warnings Clean PASS

WebSocket Verification

  • Backend logs: No ws: authentication failed errors observed.
  • Browser console: No WebSocket connection errors, no 401 on /cable.
  • Network: No /cable reconnect loops. The WebSocket connection is stable (ActionCable consumer created with access-token query param).
  • Real-time delivery: Sent message "CDP test round 3 - verifying WS delivery" in conversation #1. Message appeared instantly in the chat UI with timestamp "now".
  • BUG-4 verification: Zero Vue warnings after sending the message — the [Number, String] prop type fix on Message.vue and MessageList.vue resolves the previous warning about string message IDs.

Known Issues (Verified Non-Issues)

BUG-1 (P2) — Activity sidebar navigation

Status: Working correctly. Clicking the "活动" (Activity) sidebar group navigates to /app/accounts/1/campaigns/live_chat and expands sub-items. No console errors.

BUG-6 (P3) — Profile dropdown close

Status: Working correctly. The profile dropdown opens and closes properly via v-on-click-outside. No sidebar link occlusion.


Infinite Network Request Monitoring

No infinite request loops were detected on any page. Each page's network activity settled within 3-5 seconds of navigation. The worker pool's background job polling (SELECT * FROM background_jobs WHERE status IN ('queued','retrying')...) runs every 500ms on the backend but does not generate any frontend network traffic.


Conclusion

All 28 pages (23 from the test plan + 5 additional report sub-pages) pass with zero console errors and zero warnings. The WebSocket connection is stable and messages are delivered in real-time. The critical missing-tables bug (BUG-7) has been fixed via migration 000053. The prior fixes (BUG-4, BUG-5) are verified working.