From f1a2abddb0a053a2911030ce6e7151a9eb32bdfe Mon Sep 17 00:00:00 2001 From: Brandon McAnsh Date: Wed, 24 Jun 2026 14:41:12 -0400 Subject: [PATCH] fix(streaming): stop reporting retryable ClosedSendChannelException to Bugsnag MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The initial-request send in openBidirectionalStream already treats ClosedSendChannelException as retryable, but the trace() call was passing `error = e` which routed through ErrorUtils → Bugsnag.notify(). Inline the message instead so the retry path no longer produces false-positive Bugsnag warnings. Signed-off-by: Brandon McAnsh --- .../kotlin/com/getcode/opencode/internal/bidi/OpenStream.kt | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/services/opencode/src/main/kotlin/com/getcode/opencode/internal/bidi/OpenStream.kt b/services/opencode/src/main/kotlin/com/getcode/opencode/internal/bidi/OpenStream.kt index 21502e226..3d5597c9f 100644 --- a/services/opencode/src/main/kotlin/com/getcode/opencode/internal/bidi/OpenStream.kt +++ b/services/opencode/src/main/kotlin/com/getcode/opencode/internal/bidi/OpenStream.kt @@ -124,9 +124,8 @@ fun openBidirectionalStream( } catch (e: Exception) { trace( tag = tag, - message = "Failed to send initial request", + message = "Failed to send initial request: ${e.message}", type = TraceType.Error, - error = e ) collectionJob.cancel() requestChannel.close()