From c28bf53217d6d5eb3b1b0e5b7c78d542ce498c7c Mon Sep 17 00:00:00 2001 From: stswangzhiping <59632378+stswangzhiping@users.noreply.github.com> Date: Fri, 3 Apr 2026 16:06:34 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20WS=20=E5=A4=9A=E6=AC=A1=E5=A4=B1?= =?UTF-8?q?=E8=B4=A5=E6=97=B6=E7=BB=9F=E4=B8=80=E6=98=BE=E7=A4=BA=20AP?= =?UTF-8?q?=EF=BC=8C=E7=A7=BB=E9=99=A4=20Err0=20=E5=88=86=E6=94=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit WS 失败 ≥ 3 次无论是否有网络均显示 showAP, 不再区分"有网但 VPS 不可达"时显示 showErr0。 Made-with: Cursor --- lib/client.js | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/lib/client.js b/lib/client.js index f965d70..855ecbb 100644 --- a/lib/client.js +++ b/lib/client.js @@ -304,12 +304,7 @@ class ClawClient { this._wsFailCount++; log.warn('clawd', `连接断开 (${code}),失败次数=${this._wsFailCount},${this._backoff / 1000}s 后重连...`); if (this._hasEverConnected && this._wsFailCount >= 3) { - const inAp = this._provisionMgr && this._provisionMgr.isApMode(); - if (inAp || (!hasInternet() && !hasWiredInternetProbe())) { - led.display.showAP(); // AP 模式 或 无网(有线探测也无则视为无上行) - } else { - led.display.showErr0(); // STA 模式 + 有网 但 VPS 不可达 - } + led.display.showAP(); } if (this._certTimeError) { // NTP 未同步:固定 5s 重试,等时钟校正