diff --git a/static/messages.js b/static/messages.js index 6c8ff82e..5d2812bf 100644 --- a/static/messages.js +++ b/static/messages.js @@ -910,7 +910,8 @@ async function send(){ if(!S.session){await newSession();await renderSessionList();} // Busy-control slash commands must be intercepted HERE, before the // busyMode routing block, so the user can always type /steer, /interrupt, - // or /queue while the agent is running and have them execute immediately. + // /queue, /terminal, /goal, or /yolo while the agent is running and have + // them execute immediately. // Without this intercept they fall through to the queue and execute after // the current turn ends — by which point there is no active stream and // cmdSteer / cmdInterrupt say "No active task to stop." diff --git a/tests/test_goal_command_webui.py b/tests/test_goal_command_webui.py index 1fb96d08..4a70cbde 100644 --- a/tests/test_goal_command_webui.py +++ b/tests/test_goal_command_webui.py @@ -408,7 +408,7 @@ def test_frontend_has_goal_slash_command_and_status_event_handler(): assert "goal'" in MESSAGES_JS assert "source.addEventListener('goal'" in MESSAGES_JS assert "source.addEventListener('goal_continue'" in MESSAGES_JS - assert "['steer','interrupt','queue','terminal','goal'].includes(_pc.name)" in MESSAGES_JS + assert "['steer','interrupt','queue','terminal','goal','yolo'].includes(_pc.name)" in MESSAGES_JS assert "queueSessionMessage" in MESSAGES_JS diff --git a/tests/test_issue467_yolo_mode_toggle.py b/tests/test_issue467_yolo_mode_toggle.py index 0e88b64a..b55f3f67 100644 --- a/tests/test_issue467_yolo_mode_toggle.py +++ b/tests/test_issue467_yolo_mode_toggle.py @@ -164,6 +164,7 @@ class TestYoloBusySendPath: busy_start = messages_js.find("S.busy||compressionRunning", send_idx) assert busy_start >= 0, "busy block not found in send()" intercept_start = messages_js.find("if(text.startsWith('/')", busy_start) + assert intercept_start >= 0, "busy slash intercept block not found in send()" intercept_idx = messages_js.find("'steer','interrupt','queue','terminal','goal','yolo'", intercept_start) busymode_idx = messages_js.find("_busyInputMode||'queue'", busy_start) assert intercept_idx >= 0, "Busy-path slash allowlist must include yolo in the mid-turn branch"