From a218005525ce0c19bfa45f05a59858317c5c5390 Mon Sep 17 00:00:00 2001 From: Jonathan Gamble <101470903+schlawg@users.noreply.github.com> Date: Mon, 30 Dec 2024 14:52:32 -0600 Subject: [PATCH] permalog out of order message versions --- ui/common/src/socket.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ui/common/src/socket.ts b/ui/common/src/socket.ts index 7e98298817df..eecd56c007ac 100644 --- a/ui/common/src/socket.ts +++ b/ui/common/src/socket.ts @@ -3,6 +3,7 @@ import { idleTimer, browserTaskQueueMonitor } from './timing'; import { storage, once, type LichessStorage } from './storage'; import { pubsub, type PubsubEvent } from './pubsub'; import { myUserId } from './common'; +import { log } from './permalog'; let siteSocket: WsSocket | undefined; @@ -279,7 +280,7 @@ class WsSocket { console.debug('version gap, retrying', m.v, this.version, retries); setTimeout(() => this.handle(m, retries - 1), 200); } else { - console.log('version gap, reloading'); + log(`${this.lastUrl}: version mismatch incoming ${m.v} vs current ${this.version}`); site.reload(); } return;