Ignore WS heartbeats and reject empty chat messages #32

Merged
westfarn merged 1 commits from fix/31-ignore-ws-heartbeat-empty-messages into master 2026-07-28 05:12:13 -07:00
Owner

Summary

Test plan

  • UserPromptGuardTestCase, PromptSerializerTestCase blank/whitespace cases
  • WebSocketReceiveGuardTestCase ping ignore + empty message rejection (both WS routes)
  • Deploy to beta; leave idle tab open and confirm no new rogue conversations
  • Confirm normal chat send still works

Related FE: ai_ml_operations/chat_web_app#51

## Summary - Closes #31 - Ignore WebSocket `type: ping` heartbeats so keepalives no longer create conversations or hit title/LLM pipelines - Reject empty/whitespace user messages in both chat consumers, `PromptSerializer`, and REST conversation prompt POST ## Test plan - [x] `UserPromptGuardTestCase`, `PromptSerializerTestCase` blank/whitespace cases - [x] `WebSocketReceiveGuardTestCase` ping ignore + empty message rejection (both WS routes) - [ ] Deploy to beta; leave idle tab open and confirm no new rogue conversations - [ ] Confirm normal chat send still works Related FE: https://git.aimloperations.com/ai_ml_operations/chat_web_app/issues/51
westfarn added 1 commit 2026-07-28 05:07:51 -07:00
Ignore WS heartbeats and reject empty chat messages.
CI / test (pull_request) Successful in 11s
Unit Tests / test (pull_request) Successful in 10s
e52c6519f8
Closes #31. Prevent ping keepalives and blank/whitespace prompts from creating conversations or hitting the LLM.
westfarn merged commit ee3d47c8c3 into master 2026-07-28 05:12:13 -07:00
westfarn deleted branch fix/31-ignore-ws-heartbeat-empty-messages 2026-07-28 05:12:13 -07:00
Sign in to join this conversation.
No Reviewers
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: ai_ml_operations/chat_backend#32