From bdf87d824e254479a8534886f18b8d77148ec840 Mon Sep 17 00:00:00 2001 From: kim Date: Mon, 21 Sep 2026 22:18:26 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20=EC=9E=91=EC=97=85=EC=8B=A4/=EC=9D=98?= =?UTF-8?q?=EC=82=AC=20=EC=95=B1=20=EC=84=B8=EC=85=98=EC=9D=B4=20=EB=A9=94?= =?UTF-8?q?=EC=9D=B8=20=EC=B1=84=ED=8C=85=20=EC=82=AC=EC=9D=B4=EB=93=9C?= =?UTF-8?q?=EB=B0=94=EC=97=90=20=EB=85=B8=EC=B6=9C=EB=90=98=EB=8D=98=20?= =?UTF-8?q?=EB=B2=84=EA=B7=B8=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit APP_SESSION_PREFIXES 목록에 ws_(workshop-app.html)와 dr_(doctor-app.html)가 빠져 있어서 두 앱의 전용 채팅 세션이 메인 채팅 세션 목록에 그대로 섞여 보이고 있었음. 실제 8개 앱 HTML의 세션 프리픽스와 대조해서 누락분 추가. Co-Authored-By: Claude Sonnet 5 --- src/gateway/routes/routes-chat-sessions.ts | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/gateway/routes/routes-chat-sessions.ts b/src/gateway/routes/routes-chat-sessions.ts index ba501dd..7ed7108 100644 --- a/src/gateway/routes/routes-chat-sessions.ts +++ b/src/gateway/routes/routes-chat-sessions.ts @@ -8,10 +8,16 @@ import { getConfig } from '../../config/config'; // itself (the actual message/tool-execution loop) stays in server-v2.ts — // it's tightly coupled to handleChat, same reasoning as /api/code/round. export function registerChatSessionRoutes(app: express.Application): void { - // 'app_' style session IDs (iv_/dt_/lw_/mn_/ac_/wt_/music_/dental_) are created by + // 'app_' style session IDs (iv_/dt_/lw_/mn_/ac_/wt_/dr_/ws_/music_/dental_) are created by // dedicated per-app UIs and use the same session store as main-chat sessions // but belong to their own app UI — keep them out of the main chat sidebar. - const APP_SESSION_PREFIXES = ['iv_', 'dt_', 'lw_', 'mn_', 'ac_', 'wt_', 'music_', 'dental_']; + // + // 2026-09-21: dr_(doctor-app.html)와 ws_(workshop-app.html)가 이 목록에서 빠져있어서 두 앱의 + // 세션이 메인 채팅 사이드바에 그대로 노출되고 있었다(사용자 신고: "작업실 컨텍스트는 메인 + // 채팅 세션 창에 안 보이게 하자"). 앱별 프리픽스를 늘어놓는 이 방식 자체가 새 앱이 생길 때마다 + // 똑같이 깜빡할 수 있는 구조라는 게 근본 문제 — 앱 HTML들이 실제로 쓰는 프리픽스와 이 목록을 + // 대조해서 확인할 것(`grep -rn "Math.random" web-ui/html/*.html | grep sessionId`). + const APP_SESSION_PREFIXES = ['iv_', 'dt_', 'lw_', 'mn_', 'ac_', 'wt_', 'dr_', 'ws_', 'music_', 'dental_']; // GET /api/chat/sessions — list current user's sessions from disk app.get('/api/chat/sessions', async (req, res) => {