pub enum SettingsError {
Show 21 variants
ParseError(String),
InvalidModel {
agent: String,
model: String,
error: String,
},
MissingField {
agent: String,
field: String,
},
InvalidContextWindow {
agent: String,
context_window: u32,
},
EmptyAgentName {
index: usize,
},
ReservedAgentName {
name: String,
},
DuplicateAgentName {
name: String,
},
NoInvocationSurface {
agent: String,
},
AgentPromptSource {
agent: String,
source: PromptSourceError,
},
PromptSource(PromptSourceError),
NoPromptsDeclared {
agent: String,
},
AllOptionalPromptsMissing {
agent: String,
},
InvalidMcpConfigPath {
path: String,
},
UnresolvedMcpConfigVariable {
path: String,
variable: String,
},
IoError(String),
AgentNotFound {
name: String,
},
EmptyAgents,
NoUserInvocableAgents,
InvalidAgentSelector {
name: String,
},
NonUserInvocableAgentSelector {
name: String,
},
DuplicatePromptName {
name: String,
},
}Expand description
Errors that can occur during settings loading and agent resolution.
Variants§
ParseError(String)
The settings file exists but could not be parsed.
InvalidModel
An agent entry has an invalid model string.
MissingField
An agent entry is missing required fields.
InvalidContextWindow
An agent entry has an invalid context window.
EmptyAgentName
An agent entry has an empty name.
ReservedAgentName
An agent entry uses a reserved name.
DuplicateAgentName
Duplicate agent names.
NoInvocationSurface
An agent has no invocation surface enabled.
AgentPromptSource
A prompt source on a specific agent failed validation.
PromptSource(PromptSourceError)
A prompt source failed validation outside an agent context.
NoPromptsDeclared
An agent has no prompts declared (neither inherited nor local).
AllOptionalPromptsMissing
An agent declared prompts but every entry was optional and matched no files.
InvalidMcpConfigPath
An MCP config path does not exist or is invalid.
UnresolvedMcpConfigVariable
A ${VAR} reference in an MCP config path could not be resolved.
IoError(String)
I/O error while reading files.
AgentNotFound
An agent was not found in the catalog.
EmptyAgents
The authored config contains no agents.
NoUserInvocableAgents
The authored config contains no user-invocable agents.
InvalidAgentSelector
The configured agent selector did not match an agent.
NonUserInvocableAgentSelector
The configured agent selector matched an agent that users cannot invoke.
DuplicatePromptName
Duplicate prompt names in the catalog.
Trait Implementations§
Source§impl Debug for SettingsError
impl Debug for SettingsError
Source§impl Display for SettingsError
impl Display for SettingsError
Source§impl Error for SettingsError
impl Error for SettingsError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()