Skip to main content

RunnerRootError

Enum RunnerRootError 

Source
pub enum RunnerRootError {
Show 19 variants SystemDirectoryUnavailable { source: Error, }, SystemDirectoryUnusable { got: String, source: LocalPathError, }, ApplicationRuntimeDirectoryUnusable { got: PathBuf, source: LocalPathError, }, NonUnicode { got: PathBuf, }, ForeignPlatform { got: String, platform: PathPlatform, }, Inspect { path: PathBuf, source: Error, }, ExistingFile { path: PathBuf, }, Symlinked { path: PathBuf, }, MissingParents { path: PathBuf, deepest_existing: PathBuf, }, ParentIsNotADirectory { parent: PathBuf, }, NotWritable { path: PathBuf, remediation: String, }, DeniedByPrivacyPolicy { requested: PathBuf, refused: PathBuf, remediation: String, }, ParentNotWritable { parent: PathBuf, leaf: PathBuf, remediation: String, }, RemoteFilesystem { path: PathBuf, filesystem: String, }, UnprovableFilesystem { path: PathBuf, filesystem: String, }, ResolvesToFilesystemRoot { path: PathBuf, canonical: PathBuf, }, Overlaps { candidate: PathBuf, relation: Overlap, other: PathBuf, other_owner: String, detail: &'static str, }, Escapes { root: PathBuf, child: PathBuf, resolved: PathBuf, }, DerivedName { source: LocalPathError, },
}
Expand description

Why a runner root cannot be resolved, or cannot be used.

One type for every caller: CLI, TUI, daemon startup and restart recovery all reach the same decision, and 02-target-architecture.md requires them to reach it with the same messages. No variant may ever be handed a token or a JIT configuration — these are paths, and they are printed verbatim.

Variants§

§

SystemDirectoryUnavailable

Fields

§source: Error
§

SystemDirectoryUnusable

Fields

§

ApplicationRuntimeDirectoryUnusable

Fields

§

NonUnicode

Fields

§

ForeignPlatform

Fields

§platform: PathPlatform
§

Inspect

Fields

§path: PathBuf
§source: Error
§

ExistingFile

Fields

§path: PathBuf
§

Symlinked

Fields

§path: PathBuf
§

MissingParents

Fields

§path: PathBuf
§deepest_existing: PathBuf
§

ParentIsNotADirectory

Fields

§parent: PathBuf
§

NotWritable

Fields

§path: PathBuf
§remediation: String
§

DeniedByPrivacyPolicy

Fields

§requested: PathBuf

The root the operator asked for, which may not exist yet.

§refused: PathBuf

The deepest existing directory, which is the one that refused.

§remediation: String
§

ParentNotWritable

Fields

§parent: PathBuf
§leaf: PathBuf
§remediation: String
§

RemoteFilesystem

Fields

§path: PathBuf
§filesystem: String
§

UnprovableFilesystem

Fields

§path: PathBuf
§filesystem: String
§

ResolvesToFilesystemRoot

Fields

§path: PathBuf
§canonical: PathBuf
§

Overlaps

Fields

§candidate: PathBuf
§relation: Overlap
§other: PathBuf
§other_owner: String
§detail: &'static str
§

Escapes

Fields

§root: PathBuf
§child: PathBuf
§resolved: PathBuf
§

DerivedName

Fields

Implementations§

Source§

impl RunnerRootError

Source

pub const fn kind(&self) -> &'static str

Which refusal this is, as a closed-vocabulary token.

The agent’s log sink redacts by field name and then by value shape (crate::logging), and a RunnerRootError’s Display is mostly filesystem paths – so the sentence an operator needs cannot travel on a daemon log line, and the one that tried arrived as [redacted]. This is the part that can travel: a fixed identifier, on an allow-listed field, naming which refusal happened. It tells an operator staring at runner_start_failed reason=other which of a dozen causes they have, which is the difference between a diagnosis and a guess.

Every value here must stay a short snake_case token, for the reason the vocabulary is closed at all: crate::logging::redact scrubs anything that looks like a path or an opaque run, and a token that acquired a slash would be replaced on its way out.

Trait Implementations§

Source§

impl Debug for RunnerRootError

Source§

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

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

impl Display for RunnerRootError

Source§

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

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

impl Error for RunnerRootError

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
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
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

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

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

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> Same for T

Source§

type Output = T

Should always be Self
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.
Source§

impl<T> WithSubscriber for T

Source§

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
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

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