From 16a6cdaf79587fea6db651ddc5667f8107f0b6aa Mon Sep 17 00:00:00 2001 From: Linghong Date: Sat, 12 Sep 2026 07:11:40 +0000 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E7=AD=96=E5=88=92=E5=AE=A1?= =?UTF-8?q?=E6=89=B9=E5=9B=9E=E8=B0=83=E8=B7=A8=E9=A1=B9=E7=9B=AE=E6=B1=A1?= =?UTF-8?q?=E6=9F=93?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 为审批响应增加项目路径与请求身份校验 防止旧项目回调覆盖当前会话并清理新项目状态 --- apps/ai-game-creator-shell/src/App.tsx | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/apps/ai-game-creator-shell/src/App.tsx b/apps/ai-game-creator-shell/src/App.tsx index 9ad52805c..21ab10253 100644 --- a/apps/ai-game-creator-shell/src/App.tsx +++ b/apps/ai-game-creator-shell/src/App.tsx @@ -11647,12 +11647,36 @@ export function App({ approved, }) .then((view) => { + if ( + localProjectPathRef.current !== nextProjectPath || + designAgentTurnRef.current?.projectPath !== + nextProjectPath || + designAgentTurnRef.current?.clientTurnId !== clientTurnId + ) { + return; + } applyDesignView(view, nextProjectPath); }) .catch((error) => { + if ( + localProjectPathRef.current !== nextProjectPath || + designAgentTurnRef.current?.projectPath !== + nextProjectPath || + designAgentTurnRef.current?.clientTurnId !== clientTurnId + ) { + return; + } setPlanGddError(String(error)); }) .finally(() => { + if ( + localProjectPathRef.current !== nextProjectPath || + designAgentTurnRef.current?.projectPath !== + nextProjectPath || + designAgentTurnRef.current?.clientTurnId !== clientTurnId + ) { + return; + } designAgentTurnRef.current = null; setPlanningV2TransientReply(''); setChatAgentBusy(false);