From a176548961706a7f59c25df5d3a20809d904d769 Mon Sep 17 00:00:00 2001 From: l0ng-ai <24760907+l0ng-ai@users.noreply.github.com> Date: Sun, 8 Nov 2026 16:47:44 +0800 Subject: [PATCH] fix(ci): canonicalize verbatim Tomcat roots on Windows and match the plain agent reply style in e2e Skip canonicalizing a bare drive prefix such as `\\?\C:`, which opens the volume device and fails with ERROR_INVALID_FUNCTION. Update the agent approval e2e to the plain reply and 6px prompt radius introduced in #2118. --- crates/ide-run/src/tomcat.rs | 4 ++++ e2e/agentApproval.spec.ts | 7 ++++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/crates/ide-run/src/tomcat.rs b/crates/ide-run/src/tomcat.rs index 1352976f6..828af5272 100644 --- a/crates/ide-run/src/tomcat.rs +++ b/crates/ide-run/src/tomcat.rs @@ -401,6 +401,10 @@ fn canonical_path(path: &Path) -> IdeResult { std::path::Component::CurDir => {} _ => resolved.push(component), } + // A bare drive prefix such as `\\?\C:` names the volume device, which cannot be canonicalized. + if !resolved.has_root() { + continue; + } match dunce::canonicalize(&resolved) { Ok(path) => resolved = path, Err(e) if e.kind() == std::io::ErrorKind::NotFound && fs::symlink_metadata(&resolved).is_err() => {} diff --git a/e2e/agentApproval.spec.ts b/e2e/agentApproval.spec.ts index 13b10b33f..a742cf887 100644 --- a/e2e/agentApproval.spec.ts +++ b/e2e/agentApproval.spec.ts @@ -112,9 +112,10 @@ for (const theme of ["dark", "light"] as const) { }); expect(geometry.scroll).toBe(geometry.client); expect(geometry.contained).toBe(true); - expect(geometry.promptRadius).toBeLessThanOrEqual(4); - expect(geometry.replyBackground).not.toBe("rgba(0, 0, 0, 0)"); - expect(geometry.replyBorder).toBe("1px"); + expect(geometry.promptRadius).toBeLessThanOrEqual(6); + // Replies read as plain text on the panel. + expect(geometry.replyBackground).toBe("rgba(0, 0, 0, 0)"); + expect(geometry.replyBorder).toBe("0px"); expect(geometry.userOnRight).toBe(true); expect(geometry.approvalAligned).toBe(true); expect(geometry.authorBeforeWork).toBe(true);