Skip to content

Commit 3e158b8

Browse files
author
masoncai
committed
fix: streamable http initialization stage negotiation failed
1 parent 8f5b048 commit 3e158b8

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

client/transport/streamable_http.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -420,6 +420,9 @@ func (c *StreamableHTTP) readSSE(ctx context.Context, reader io.ReadCloser, hand
420420
event = strings.TrimSpace(strings.TrimPrefix(line, "event:"))
421421
} else if strings.HasPrefix(line, "data:") {
422422
data = strings.TrimSpace(strings.TrimPrefix(line, "data:"))
423+
} else {
424+
// Server may response with arbitrary data
425+
data = line
423426
}
424427
}
425428
}

0 commit comments

Comments
 (0)