Treat a stream that ends without [DONE] as an error
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 2/5
- 見積もり時間
- 1〜3時間
- 初心者へのやさしさ
- 85/100
- issue の種類
- バグ
- 明瞭さ
- 明確に書かれている
- 活発さ
- 活発
- 技術スタック
- typescript
調査の方向性
Start in packages/widget/src/api/client.ts at the read loop and its current { done: true } result, then review packages/widget/tests/api/client.test.ts and the mockChatStream helper in tests/helpers/stream.ts. Add coverage for streams ending with and without [DONE]; done looks like the completed case still succeeds, an incomplete stream yields { error: 'network' }, and timeout handling remains intact. Add the requested patch changeset for @chatcops/widget.
索引モデルが issue の本文から書いたものです。
説明
All three server adapters end a reply with data: [DONE]. The widget's client treats the end of the stream as success either way: after the read loop it yields { done: true } (packages/widget/src/api/client.ts, lines 129 and 130). When a proxy or the server cuts the connection mid-reply, the visitor gets a half answer with no error and no Retry button.
What to do
- If the stream ends without a
[DONE]line, yield{ error: 'network' }instead of{ done: true }. - A
[DONE]that arrives keeps working as today, and so does the timeout handling.
Acceptance criteria
- Tests in
packages/widget/tests/api/client.test.ts(themockChatStreamhelper intests/helpers/stream.tsbuilds the fake stream): ending with[DONE]givesdone, ending without it giveserror: 'network' - Changeset for
@chatcops/widget(patch) -
pnpm -r build,pnpm testandpnpm -r typecheckpass
Want to work on this? Comment below and I'll assign it to you. Please take one issue at a time, branch off dev, and open your PR against dev with Closes #<this issue number>. Setup notes (pnpm, build before test) are in CONTRIBUTING.md.
- 主要言語
- TypeScript
- スター
- 13
- フォーク
- 7
- 平均マージ
- 3時間 28分
- マージ済み PR(30日)
- 182
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
codercops/chatcops のほかの issue
-
Type-check the TypeScript samples in the docs対応中かも @An16og が 3 日前に担当しました。 オープンdocumentation hacktoberfest help wanted testing
難易度 4/5 3〜5日 初心者へのやさしさ 70/100
codercops/chatcops#201 · コメント 7 件 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
-
hacktoberfest
難易度 1/5 1時間未満 初心者へのやさしさ 35/100
メンテナーはふだん 1 日以内に返信
-
Add built-in translations to the widget対応中かも @piyusshhjangid が 2 日前に担当しました。 オープンhelp wanted widget
難易度 4/5 3〜5日 初心者へのやさしさ 52/100
codercops/chatcops#55 · コメント 3 件 ·
メンテナーはふだん 1 日以内に返信
codercops/chatcops の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 85/100
farion1231/cc-switch#8829 ·
メンテナーはふだん 1 日以内に返信
-
[core-client] Remove unused hand-maintained transport helpers after the definition-table cutoverオープンdoc-audit enhancement
難易度 2/5 1〜3時間 初心者へのやさしさ 88/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 85/100
-
Snapshot capture failure (EPERM spawning git) fails the whole step despite the best-effort contractオープンreproduced
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
anomalyco/opencode#58685 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信