From 746b96e71dc11cec4bf86b9ce9cdaa69c46657b1 Mon Sep 17 00:00:00 2001 From: Suzumiya Date: Thu, 10 Sep 2026 16:45:29 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B5=84=E6=BA=90=E7=BC=96=E8=BE=91=20400=20?= =?UTF-8?q?=E5=90=8C=E6=97=B6=E9=80=8F=E5=87=BA=E5=B9=B3=E5=8F=B0=E9=94=99?= =?UTF-8?q?=E8=AF=AF=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - editor_api_rejection_reason 额外读取响应体 error.code,过滤掉等价于通用文案的 BAD_REQUEST 后拼成「原因|错误码 CODE」 - 背景:http_error.rs 把所有 4xx 兜底为同一条「请求参数不合法」,只透 message 会丢掉唯一可用于定位的信息 --- .../src-tauri/src/project/resource_editor.rs | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/apps/ai-game-creator-shell/src-tauri/src/project/resource_editor.rs b/apps/ai-game-creator-shell/src-tauri/src/project/resource_editor.rs index 245b3ec82..b729c979f 100644 --- a/apps/ai-game-creator-shell/src-tauri/src/project/resource_editor.rs +++ b/apps/ai-game-creator-shell/src-tauri/src/project/resource_editor.rs @@ -2483,7 +2483,19 @@ async fn editor_api_rejection_reason(response: reqwest::Response) -> Option format!("{reason}|错误码 {code}"), + None => reason, + }) } async fn submit_resource_edit_remote(