pub enum InitError {
UnknownPlatform(String),
McpBinaryNotFound {
searched: Vec<PathBuf>,
},
McpBinaryInvalid(String),
WalPathInvalid(String),
TraeIncompatiblePath(String),
}Expand description
生成失败。全部 fail-closed:宁可拒生成,绝不产出一份装不上/对不上账的配置。
Variants§
UnknownPlatform(String)
未知平台,报错列全矩阵。
McpBinaryNotFound
PATH 上找不到 wanning-mcp 可执行文件;searched = 搜过的目录(报错点名)。
McpBinaryInvalid(String)
显式 --bin 指向的路径不是文件。
WalPathInvalid(String)
WAL 路径解析失败(默认路径解析不出家目录,或当前目录不可得)。
TraeIncompatiblePath(String)
Trae 的 command 不能含空格(官方明示),解析出的路径含空格 = 拒绝生成。
Implementations§
Trait Implementations§
impl Eq for InitError
impl StructuralPartialEq for InitError
Auto Trait Implementations§
impl Freeze for InitError
impl RefUnwindSafe for InitError
impl Send for InitError
impl Sync for InitError
impl Unpin for InitError
impl UnsafeUnpin for InitError
impl UnwindSafe for InitError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more