From a350c82893fce7a894983fba0497d0878fc9f9b3 Mon Sep 17 00:00:00 2001 From: Smittix Date: Tue, 24 Feb 2026 08:46:17 +0000 Subject: [PATCH] Use monotonic audio start tokens across page reloads --- static/js/modes/waterfall.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/static/js/modes/waterfall.js b/static/js/modes/waterfall.js index 7851144..c98de8f 100644 --- a/static/js/modes/waterfall.js +++ b/static/js/modes/waterfall.js @@ -2784,6 +2784,9 @@ const Waterfall = (function () { let monitorDevice = altDevice || selectedDevice; const biasT = !!document.getElementById('wfBiasT')?.checked; const usingSecondaryDevice = !!altDevice; + // Use a high monotonic token so backend start ordering remains + // valid across page reloads (local nonces reset to small values). + const requestToken = Math.trunc((Date.now() * 4096) + (nonce & 0x0fff)); if (!retuneOnly) { _monitorFreqMhz = centerMhz; @@ -2814,7 +2817,7 @@ const Waterfall = (function () { gain, device: monitorDevice, biasT, - requestToken: nonce, + requestToken, }); if (nonce !== _audioConnectNonce) return; @@ -2839,7 +2842,7 @@ const Waterfall = (function () { gain, device: monitorDevice, biasT, - requestToken: nonce, + requestToken, })); if (nonce !== _audioConnectNonce) return; if (payload?.superseded === true || payload?.status === 'stale') return;