Title: fix(http): accept CR line endings in SSE streams by Elon-Jiang · Pull Request #198 · agentclientprotocol/python-sdk · GitHub
Open Graph Title: fix(http): accept CR line endings in SSE streams by Elon-Jiang · Pull Request #198 · agentclientprotocol/python-sdk
X Title: fix(http): accept CR line endings in SSE streams by Elon-Jiang · Pull Request #198 · agentclientprotocol/python-sdk
Description: Summary The public Streamable HTTP transport never delivers an SSE event delimited by CR while the connection stays open. LF and CRLF controls deliver normally. SSE permits all three line endings (WHATWG). Normalize CR and CRLF before the existing line parser. Remember a trailing CR across chunks so the following LF is consumed once, without delaying delivery until another chunk or EOF. The regression covers split CRLF, empty chunks, multibyte UTF-8, multiple data fields and mixed endings; U+0085/U+2028 inside JSON stay unchanged. Related issues N/A; found through the Streamable HTTP receive path. Existing #183 handles JSON-RPC batches, not CR framing. Testing Public create_http_stream() → initialize → receive, with the real HTTPX2 client and a controlled long-lived response stream: unchanged main 4 fail / 3 controls pass, fixed 7 pass. Related HTTP client/SSE tests: 36 passed. make check: passed. NO_PROXY=localhost,127.0.0.1,::1 no_proxy=localhost,127.0.0.1,::1 make test: 547 passed, 1 skipped (optional Gemini), one existing code-generator warning. The initial run had five WebSocket failures because the local environment routed loopback through a SOCKS proxy without its optional dependency; direct loopback passed without source/dependency changes. Only the external HTTP response is supplied by MockTransport; no live agent/model was used. No schema or public API changes. AI assistance: Codex prepared the patch and ran the listed checks. No human review is claimed. Docs & screenshots No public API or schema changes. This restores existing SSE framing behavior; no new configuration, guide or screenshot is needed. Checklist Conventional Commit title. Tests cover the change. Docs/examples considered; no API change. No schema regeneration required.
Open Graph Description: Summary The public Streamable HTTP transport never delivers an SSE event delimited by CR while the connection stays open. LF and CRLF controls deliver normally. SSE permits all three line endings (...
X Description: Summary The public Streamable HTTP transport never delivers an SSE event delimited by CR while the connection stays open. LF and CRLF controls deliver normally. SSE permits all three line endings (...
Opengraph URL: https://github.com/agentclientprotocol/python-sdk/pull/198
X: @github
Domain: github.com
IPv4 address: 140.82.113.4
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:1edd2d86-1261-8bfd-87d4-761a20f637ef |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | D760:311933:11CBDB:187B9D:6B0464F7 |
| html-safe-nonce | 677c96d9cdaa7dee7296ab8d2a2df38faac964d8d08f6468b6384b61f680fb6e |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJENzYwOjMxMTkzMzoxMUNCREI6MTg3QjlEOjZCMDQ2NEY3IiwidmlzaXRvcl9pZCI6IjMyNDk5NDEyMTcxMTQ2MTI5ODMiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | d9d7461c3c4352a9e9c8ec52de31091355dc4b697592183ff6866608944d80e2 |
| hovercard-subject-tag | pull_request:5353436966 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/agentclientprotocol/python-sdk/pull/198/files |
| twitter:image | https://avatars.githubusercontent.com/u/191222665?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/191222665?s=400&v=4 |
| og:image:alt | Summary The public Streamable HTTP transport never delivers an SSE event delimited by CR while the connection stays open. LF and CRLF controls deliver normally. SSE permits all three line endings (... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | 83e4c0e58c5162177f3c161c5fbad38527ae04c11ac14980f9f9d85ae2027b1f |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/agentclientprotocol/python-sdk git https://github.com/agentclientprotocol/python-sdk.git |
| octolytics-dimension-user_id | 235308037 |
| octolytics-dimension-user_login | agentclientprotocol |
| octolytics-dimension-repository_id | 1051445009 |
| octolytics-dimension-repository_nwo | agentclientprotocol/python-sdk |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 1051445009 |
| octolytics-dimension-repository_network_root_nwo | agentclientprotocol/python-sdk |
| turbo-body-classes | logged-out env-production page-responsive full-width |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | ca4d07a7cef4e4b75f821dc25e7300d80c1450a9 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
| Server | github.com |
| Content-Type | text/html; charset=utf-8 |
| Cache-Control | no-cache |
Viewport: width=device-width