Skip to content

ANT-500: fix agent comments not syncing to Jira#5

Merged
0xHexE merged 1 commit into
mainfrom
agent/grok/5ed48c94
Jul 14, 2026
Merged

ANT-500: fix agent comments not syncing to Jira#5
0xHexE merged 1 commit into
mainfrom
agent/grok/5ed48c94

Conversation

@0xHexE

@0xHexE 0xHexE commented Jul 14, 2026

Copy link
Copy Markdown
Member

Summary

  • Agent comments created via TaskService.createAgentComment publish comment:created with a map[string]any payload.
  • Outbound issue-sync listeners only type-asserted handler.CommentResponse, so those events were dropped before enqueueing push_comment outbox rows.
  • Result: human comments mirrored to Jira/GitHub/GitLab, agent comments did not.

Fix

  • Normalize both payload shapes in enqueueCommentOutbox via extractCommentFields (same dual-shape contract as notification/subscriber listeners).
  • Regression tests cover map + CommentResponse extraction and end-to-end outbox enqueue when issue-sync tables are present.

Test plan

  • go test ./cmd/server -run TestExtractCommentFields (pass)
  • Integration test seeds and asserts outbox rows when issue_sync_source exists (skips cleanly on unmigrated DBs)
  • On a Jira-synced issue: post an agent comment and confirm it appears in Jira with **AgentName (via Multica):** prefix

Closes ANT-500

TaskService.createAgentComment publishes comment:created with a map payload,
while enqueueCommentOutbox only accepted handler.CommentResponse. Agent
comments were therefore never mirrored to external trackers.

Accept both payload shapes (matching notification/subscriber listeners) and
add regression coverage for the map path and author-label resolution.

Closes ANT-500
@0xHexE
0xHexE merged commit 6e07b83 into main Jul 14, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant