From 1b2747abb1c4027e84fb070fafbc8c818be040a4 Mon Sep 17 00:00:00 2001 From: Shawn Date: Tue, 16 Jun 2026 20:02:57 -0400 Subject: [PATCH] fix: audio params timeout - increase API timeout for JACK restart The setAudioParams call restarts JACK which takes up to 10 seconds. The default API timeout was 6s, causing the request to abort and leaving JACK in a broken state. - Changed setAudioParams to use API._fetch directly with timeout:15000 - Also calls loadAudioParams() after success to refresh dropdown values --- src/web/ui-v2-dist/index.html | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/web/ui-v2-dist/index.html b/src/web/ui-v2-dist/index.html index e6486b2..3d131d0 100644 --- a/src/web/ui-v2-dist/index.html +++ b/src/web/ui-v2-dist/index.html @@ -804,8 +804,9 @@ async function setAudioParams(){ const btn=document.querySelector('.sn-btn[data-section="audio"]'); if(btn)btn.textContent='⏳ Applying...'; try{ - await API.setAudioProfile({period,rate}); + await API._fetch('/api/audio/profile',{method:'POST',body:JSON.stringify({period,rate}),timeout:15000}); toast('Audio: '+rate+'Hz / '+period+'fr'); + loadAudioParams(); }catch(e){toast('Failed: '+e.message);} if(btn)btn.textContent='🎛 Audio'; }