@cocorograph/hub-agent 0.7.82 → 0.7.83
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1154,7 +1154,12 @@ class ClaudeStreamSession {
|
|
|
1154
1154
|
_drainPending() {
|
|
1155
1155
|
if (this._closed || this._busy) return
|
|
1156
1156
|
if (this._pendingMessages.length === 0) {
|
|
1157
|
-
|
|
1157
|
+
// 症状1 自己修復 (2026-07-21): drain の started emit (キューを空にした単発 broadcast) が
|
|
1158
|
+
// WS チャーンで落ちると、frontend は空になったキューを学習できず送信待ちチップが force
|
|
1159
|
+
// resync まで stale 残留する。最後の 1 件を drain した直後の空状態は sig="0:" が前回と
|
|
1160
|
+
// 同一で dedup されて再送されないため、ターン settle 毎に force で現状態を再表明し、
|
|
1161
|
+
// 落ちた broadcast を次のターン境界で必ず補正する (空 emit は count=0 で安価・冪等)。
|
|
1162
|
+
this._emitQueueState([], { force: true })
|
|
1158
1163
|
return
|
|
1159
1164
|
}
|
|
1160
1165
|
const next = this._pendingMessages.shift()
|
|
@@ -1351,7 +1356,9 @@ class ClaudeStreamSession {
|
|
|
1351
1356
|
async _drainResidentPending() {
|
|
1352
1357
|
if (this._closed) return
|
|
1353
1358
|
if (this._pendingMessages.length === 0) {
|
|
1354
|
-
|
|
1359
|
+
// 症状1 自己修復 (2026-07-21): _drainPending と同旨。落ちた drain broadcast で送信待ち
|
|
1360
|
+
// チップが stale 残留するのを、ターン settle 毎の force 再表明で補正する (空 = count=0)。
|
|
1361
|
+
this._emitQueueState([], { force: true })
|
|
1355
1362
|
return
|
|
1356
1363
|
}
|
|
1357
1364
|
const next = this._pendingMessages.shift()
|