Skip to main content

WorkspaceError

Enum WorkspaceError 

Source
pub enum WorkspaceError {
Show 48 variants ConfigMissing { path: PathBuf, }, ConfigParse { path: PathBuf, at: String, message: String, }, ConfigInvalid { path: PathBuf, message: String, }, NoOrgsConfigured { path: PathBuf, }, NoProjectsConfigured { path: PathBuf, }, NoAccountsConfigured { path: PathBuf, }, DuplicateAccount { path: PathBuf, name: String, }, AccountsMissingProvider { path: PathBuf, names: Vec<String>, }, OpenrouterBaseUrlNotApiRoot { path: PathBuf, name: String, }, ProjectInvalidPermissionMode { path: PathBuf, name: String, value: String, }, ProjectDocumentRootRelative { path: PathBuf, name: String, root: String, }, GatewayPortInvalid { path: PathBuf, }, GatewayRotationInvalid { path: PathBuf, key: &'static str, }, ModelAutoCompactWindowInvalid { path: PathBuf, model: String, value: i64, }, HandoffAtPercentInvalid { path: PathBuf, scope: String, value: u32, }, HandoffAfterCompactionsInvalid { path: PathBuf, scope: String, }, DocumentCeilingInvalid { path: PathBuf, value: u64, }, DocumentCeilingTooLarge { path: PathBuf, value: u64, }, UsagePollIntervalInvalid { path: PathBuf, }, SessionsHealAttemptsInvalid { path: PathBuf, }, SessionsDurationInvalid { path: PathBuf, key: &'static str, value: String, }, SessionsBackoffEmpty { path: PathBuf, }, ServerPortInvalid { path: PathBuf, }, ServerPortTakenByGateway { path: PathBuf, port: u16, }, ClientNameUnknown { path: PathBuf, key: &'static str, value: String, }, AccountProviderNeedsBaseUrl { path: PathBuf, name: String, }, AccountTokenRequired { path: PathBuf, name: String, }, AccountModelsRequired { path: PathBuf, name: String, }, AccountSlugUndeclared { path: PathBuf, slug: String, }, AccountSlugBlank { path: PathBuf, slug: String, }, AccountAliasUndeclared { path: PathBuf, alias: String, }, AccountAliasEmpty { path: PathBuf, alias: String, }, ProjectModelUndeclared { path: PathBuf, name: String, model: String, }, DuplicateOrg { path: PathBuf, name: String, }, DuplicateProject { path: PathBuf, name: String, }, EmptyOrg { path: PathBuf, org: String, }, EmptyOrgAccounts { path: PathBuf, org: String, }, NoAccountServesProjectModel { project: String, org: String, model: String, accounts: String, }, AllAccountsCooling { project: String, org: String, model: String, seconds: u64, }, ProjectModelMissing { project: String, org: String, }, SpawnResolvesToNoProject { slot: String, }, SeatClosedDuringSpawn { slot: String, }, SpawnRoleSlotDisagree { role: SpawnRole, slot: String, }, UnknownOrgAccount { path: PathBuf, org: String, account: String, valid: String, }, ProjectNotFound { name: String, path: PathBuf, }, SessionStoreUnreadable { org: String, project: String, label: String, }, DataDirUnavailable { path: PathBuf, source: Error, }, AlreadyRunning { pid: Option<u32>, },
}
Expand description

Reasons Workspace::new may fail.

Variants§

§

ConfigMissing

Fields

§path: PathBuf
§

ConfigParse

The parse failure as a reader acts on it: where it is, and why. message is the error’s own words with any quoted value scrubbed and at its line and column (empty when it has none) - a value on the offending line can be a token, so neither the snippet nor the toml error itself (whose Debug carries the whole document) rides along (#2267).

Fields

§path: PathBuf
§message: String
§

ConfigInvalid

Fields

§path: PathBuf
§message: String
§

NoOrgsConfigured

Fields

§path: PathBuf
§

NoProjectsConfigured

Fields

§path: PathBuf
§

NoAccountsConfigured

Fields

§path: PathBuf
§

DuplicateAccount

Fields

§path: PathBuf
§name: String
§

AccountsMissingProvider

Fields

§path: PathBuf
§names: Vec<String>
§

OpenrouterBaseUrlNotApiRoot

Fields

§path: PathBuf
§name: String
§

ProjectInvalidPermissionMode

Fields

§path: PathBuf
§name: String
§value: String
§

ProjectDocumentRootRelative

Fields

§path: PathBuf
§name: String
§root: String
§

GatewayPortInvalid

Fields

§path: PathBuf
§

GatewayRotationInvalid

Fields

§path: PathBuf
§key: &'static str
§

ModelAutoCompactWindowInvalid

Fields

§path: PathBuf
§model: String
§value: i64
§

HandoffAtPercentInvalid

Fields

§path: PathBuf
§scope: String
§value: u32
§

HandoffAfterCompactionsInvalid

Fields

§path: PathBuf
§scope: String
§

DocumentCeilingInvalid

Fields

§path: PathBuf
§value: u64
§

DocumentCeilingTooLarge

Fields

§path: PathBuf
§value: u64
§

UsagePollIntervalInvalid

Fields

§path: PathBuf
§

SessionsHealAttemptsInvalid

Fields

§path: PathBuf
§

SessionsDurationInvalid

Fields

§path: PathBuf
§key: &'static str
§value: String
§

SessionsBackoffEmpty

Fields

§path: PathBuf
§

ServerPortInvalid

Fields

§path: PathBuf
§

ServerPortTakenByGateway

Fields

§path: PathBuf
§port: u16
§

ClientNameUnknown

Fields

§path: PathBuf
§key: &'static str
§value: String
§

AccountProviderNeedsBaseUrl

Fields

§path: PathBuf
§name: String
§

AccountTokenRequired

Fields

§path: PathBuf
§name: String
§

AccountModelsRequired

Fields

§path: PathBuf
§name: String
§

AccountSlugUndeclared

Fields

§path: PathBuf
§slug: String
§

AccountSlugBlank

Fields

§path: PathBuf
§slug: String
§

AccountAliasUndeclared

Fields

§path: PathBuf
§alias: String
§

AccountAliasEmpty

Fields

§path: PathBuf
§alias: String
§

ProjectModelUndeclared

Fields

§path: PathBuf
§name: String
§model: String
§

DuplicateOrg

Fields

§path: PathBuf
§name: String
§

DuplicateProject

Fields

§path: PathBuf
§name: String
§

EmptyOrg

Fields

§path: PathBuf
§

EmptyOrgAccounts

Fields

§path: PathBuf
§

NoAccountServesProjectModel

Fields

§project: String
§model: String
§accounts: String
§

AllAccountsCooling

Fields

§project: String
§model: String
§seconds: u64
§

ProjectModelMissing

Fields

§project: String
§

SpawnResolvesToNoProject

Fields

§slot: String
§

SeatClosedDuringSpawn

A recovery spawn found the seat closed: the reader stopped it while the spawn was being prepared, and only an opening door may undo that.

Fields

§slot: String
§

SpawnRoleSlotDisagree

The stated spawn role and the target slot name different sessions. Both are caller statements, so a disagreement is a caller bug rather than something to resolve.

Fields

§slot: String
§

UnknownOrgAccount

Fields

§path: PathBuf
§account: String
§valid: String
§

ProjectNotFound

Fields

§name: String
§path: PathBuf
§

SessionStoreUnreadable

Fields

§project: String
§label: String
§

DataDirUnavailable

Fields

§path: PathBuf
§source: Error
§

AlreadyRunning

Fields

Trait Implementations§

Source§

impl Debug for WorkspaceError

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Display for WorkspaceError

Source§

fn fmt(&self, __formatter: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Error for WorkspaceError

Source§

fn source(&self) -> Option<&(dyn Error + 'static)>

Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§

fn description(&self) -> &str

👎Deprecated since 1.42.0:

use the Display impl or to_string()

1.0.0 · Source§

fn cause(&self) -> Option<&dyn Error>

👎Deprecated since 1.33.0:

replaced by Error::source, which can support downcasting

Source§

fn provide<'a>(&'a self, request: &mut Request<'a>)

🔬This is a nightly-only experimental API. (error_generic_member_access)
Provides type-based access to context intended for error reports. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<T> Any for T
where T: Any,

§

fn into_any(self: Box<T>) -> Box<dyn Any>

§

fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>

§

fn type_name(&self) -> &'static str

§

impl<T> AnySync for T
where T: Any + Send + Sync,

§

fn into_any_arc(self: Arc<T>) -> Arc<dyn Any + Sync + Send> ⓘ

Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

§

impl<S, T> Duplex<S> for T
where T: FromSample<S> + ToSample<S>,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<S> FromSample<S> for S

§

fn from_sample_(s: S) -> S

§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self> ⓘ

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self> ⓘ

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
§

impl<T> Pointable for T

§

const ALIGN: usize

The alignment of pointer.
§

type Init = T

The type for initializers.
§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
§

impl<T> PolicyExt for T
where T: ?Sized,

§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns [Action::Follow] only if self and other return Action::Follow. Read more
§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns [Action::Follow] if either self or other returns Action::Follow. Read more
§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
§

impl<T, U> ToSample<U> for T
where U: FromSample<T>,

§

fn to_sample_(self) -> U

Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘ
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self> ⓘ

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more