Skip to content

fix(dataexchange): emit event on WriteFrame failure in handleConn (PILOT-184)#2

Merged
TeoSlayer merged 1 commit into
mainfrom
openclaw/pilot-184-20260528-034500
May 28, 2026
Merged

fix(dataexchange): emit event on WriteFrame failure in handleConn (PILOT-184)#2
TeoSlayer merged 1 commit into
mainfrom
openclaw/pilot-184-20260528-034500

Conversation

@matthew-pilot
Copy link
Copy Markdown
Collaborator

Problem (PILOT-184)

When handleConn's ACK WriteFrame fails, the loop silently returns — no metric, event, or log is surfaced. Operators have zero visibility into ACK write failures on the wire.

Fix

Emit s.deps.Events.Publish("dataexchange.ack_failed", ...) with remote address, frame type, and error string before returning. Uses the same nil-guarded event-emission pattern already established by file.received and message.received in this file.

Scope

  • 1 file, +7 lines
  • service.go:181-188handleConn WriteFrame error path

Verification

go vet ./...     # clean
go test ./...    # all pass (0.542s)

🔗 PILOT-184

…LOT-184)

When the ACK WriteFrame fails in handleConn, the loop silently
returns — no metric, event, or log is surfaced. Operators have
no visibility into ACK write failures on the wire.

Fix: emit s.deps.Events.Publish("dataexchange.ack_failed", ...)
with remote address, frame type, and error before returning.
Matches the existing event-emission pattern used by file.received
and message.received.
@codecov
Copy link
Copy Markdown

codecov Bot commented May 28, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@TeoSlayer TeoSlayer merged commit 5aeac63 into main May 28, 2026
2 checks passed
@TeoSlayer TeoSlayer deleted the openclaw/pilot-184-20260528-034500 branch May 28, 2026 16:50
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.

2 participants