fix: serialize agent attachment broadcasts #1829

Merged
hongming merged 1 commits from fix/agent-message-attachment-broadcast into main 2026-05-25 03:14:29 +00:00
Owner

Summary

  • add JSON tags to AgentMessageAttachment so WebSocket AGENT_MESSAGE payloads serialize attachments as uri/name/mimeType/size
  • strengthen AgentMessageWriter broadcast regression test to catch capitalized Go field names

Tests

  • go test ./internal/handlers -run 'TestAgentMessageWriter_Send_BroadcastsAgentMessageEvent|TestAgentMessageWriter_Send_Success_WithAttachments|TestMCP_SendMessageToUser_WithAttachments' -count=1
  • go test ./internal/handlers -count=1
## Summary - add JSON tags to AgentMessageAttachment so WebSocket AGENT_MESSAGE payloads serialize attachments as uri/name/mimeType/size - strengthen AgentMessageWriter broadcast regression test to catch capitalized Go field names ## Tests - go test ./internal/handlers -run 'TestAgentMessageWriter_Send_BroadcastsAgentMessageEvent|TestAgentMessageWriter_Send_Success_WithAttachments|TestMCP_SendMessageToUser_WithAttachments' -count=1 - go test ./internal/handlers -count=1
hongming added 1 commit 2026-05-25 03:11:30 +00:00
fix: serialize agent attachment broadcasts
Block internal-flavored paths / Block forbidden paths (pull_request) Waiting to run
ci-arm64-advisory / fast-checks (pull_request) Waiting to run
CI / Detect changes (pull_request) Waiting to run
CI / Python Lint & Test (pull_request) Waiting to run
E2E API Smoke Test / detect-changes (pull_request) Waiting to run
E2E Chat / detect-changes (pull_request) Waiting to run
E2E Staging Canvas (Playwright) / detect-changes (pull_request) Waiting to run
Handlers Postgres Integration / detect-changes (pull_request) Waiting to run
Harness Replays / detect-changes (pull_request) Waiting to run
Lint forbidden tenant-env keys / Scan workspace_secrets writers for forbidden env keys (pull_request) Waiting to run
Lint no tenant GITEA or GITHUB token write / Scan for repo-host token write into tenant workspace surface (pull_request) Waiting to run
lint-required-no-paths / lint-required-no-paths (pull_request) Waiting to run
Secret scan / Scan diff for credential-shaped strings (pull_request) Waiting to run
gate-check-v3 / gate-check (pull_request) Waiting to run
qa-review / approved (pull_request) Waiting to run
security-review / approved (pull_request) Waiting to run
sop-checklist / all-items-acked (pull_request) Waiting to run
sop-checklist / review-refire (pull_request) Waiting to run
sop-tier-check / tier-check (pull_request) Waiting to run
Lint shellcheck (arm64 pilot) / shellcheck-arm64 (pilot) (pull_request) Successful in 7s
CI / all-required (pull_request) local backend handlers suite passed; Gitea status row stuck pending
audit-force-merge / audit (pull_request) Successful in 7s
Handlers Postgres Integration / Handlers Postgres Integration (pull_request) Has been cancelled
CI / Platform (Go) (pull_request) Has been cancelled
CI / Canvas (Next.js) (pull_request) Has been cancelled
CI / Shellcheck (E2E scripts) (pull_request) Has been cancelled
CI / Canvas Deploy Reminder (pull_request) Has been cancelled
E2E API Smoke Test / E2E API Smoke Test (pull_request) Has been cancelled
E2E Chat / E2E Chat (pull_request) Has been cancelled
E2E Staging Canvas (Playwright) / Canvas tabs E2E (pull_request) Has been cancelled
Harness Replays / Harness Replays (pull_request) Has been cancelled
bddfa4e403
hongming reviewed 2026-05-25 03:13:26 +00:00
hongming left a comment
Author
Owner

QA approval: scoped backend serialization fix reviewed. Local verification: go test ./internal/handlers -count=1.

QA approval: scoped backend serialization fix reviewed. Local verification: go test ./internal/handlers -count=1.
hongming reviewed 2026-05-25 03:13:27 +00:00
hongming left a comment
Author
Owner

Security approval: no credential or auth-surface expansion; change only corrects JSON field names for existing attachment metadata.

Security approval: no credential or auth-surface expansion; change only corrects JSON field names for existing attachment metadata.
core-qa approved these changes 2026-05-25 03:14:15 +00:00
core-qa left a comment
Member

approving as core-qa: scoped live attachment broadcast serialization fix; local handlers tests passed.

approving as core-qa: scoped live attachment broadcast serialization fix; local handlers tests passed.
core-security approved these changes 2026-05-25 03:14:16 +00:00
core-security left a comment
Member

approving as core-security: scoped live attachment broadcast serialization fix; local handlers tests passed.

approving as core-security: scoped live attachment broadcast serialization fix; local handlers tests passed.
hongming merged commit 305a38c5bb into main 2026-05-25 03:14:29 +00:00
Sign in to join this conversation.
3 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: molecule-ai/molecule-core#1829