Skip to main content

MemoryError

Enum MemoryError 

Source
#[non_exhaustive]
pub enum MemoryError {
Show 28 variants Storage(Error), Memory(AgentMemoryError), EmptyFact, UnknownMemory(u64), FactTooLarge { bytes: usize, max: usize, }, ZeroTtl, SelfRelation(u64), ReservedKey(String), MetadataTooLarge { bytes: usize, max: usize, }, Embed(EmbedError), Extract(ExtractError), Rerank(RerankError), MigrationCapture(String), Unsupported(&'static str), InvalidFilter(String), InvalidRelation(String), ContextBudget { budget: u64, reserve: u64, }, ContextOverLimit(String), SegmentationError(String), UnknownHandle(String), FragmentIndexOutOfBounds { index: usize, len: usize, }, FragmentNotFound(u64), EmptyWorkingContext, WorkingContextCodec { detail: String, source: Option<Box<Error>>, }, IngestDisabled, IngestOutsideRoots(String), IngestPath(String), RollbackFailed { cause: Box<MemoryError>, rollback: Box<MemoryError>, },
}
Expand description

Errors returned by crate::service::MemoryService.

non_exhaustive: adapters classify through MemoryError::category, never by variant, so new variants must be a non-event downstream — which is also what lets a variant’s payload gain structure one minor release at a time instead of in one breaking batch.

§String payloads are a decision here, not a debt

Every adapter consumes this type through MemoryError::category plus Display; no payload is read programmatically outside this crate. So a variant earns a structured payload only when structure is being lost — a source error flattened out of the source() chain, or an in-crate consumer parsing prose — and Self::WorkingContextCodec is the one that qualified (it had both). The others carry prose on purpose: their messages are heterogeneous narratives written for the person reading them (Self::IngestPath additionally cites the requested path and never the canonical one, a security decision its module documents), and forcing one struct template over them would flatten exactly the nuance they exist to deliver. Re-litigating this per variant is what this paragraph is for.

Variants (Non-exhaustive)§

This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
§

Storage(Error)

Failure in the underlying VelesDB storage engine.

§

Memory(AgentMemoryError)

Failure in the Agent Memory SDK. Only constructible with the persistence feature (the native, file-backed store) — a persistence-free backend (e.g. velesdb-wasm’s in-memory one) never touches velesdb-core’s agent module, so this variant can’t arise.

§

EmptyFact

A fact was empty or whitespace-only.

§

UnknownMemory(u64)

A remember link or a relate endpoint referenced a memory id that does not exist.

§

FactTooLarge

A fact was longer than crate::limits::MAX_EMBEDDABLE_TEXT_BYTES, the size an embedding model still accepts. Refused BEFORE the embedder is called, so the caller learns the limit and its own size instead of an opaque backend fault (ollama embeddings call failed).

Fields

§bytes: usize

The size of the rejected fact, in bytes.

§max: usize

The cap that was exceeded (crate::limits::MAX_EMBEDDABLE_TEXT_BYTES).

§

ZeroTtl

crate::service::MemoryService::remember_with_ttl was given Some(0). An explicit per-call 0 used to be normalised to “no expiry”, i.e. a caller who meant “expire immediately” silently got a permanent fact — the exact opposite intent, with no signal. A TTL supplied as configuration (with_default_ttl, a compile policy’s source_ttl_seconds) still reads 0 as “no TTL policy”: that is a default, not an intent about one fact.

§

SelfRelation(u64)

crate::service::MemoryService::relate was asked to link a memory to itself. A self-loop states nothing and is traversed by why like any other edge, so it only adds noise to the evidence trail.

§

ReservedKey(String)

Caller metadata or a recall filter named a reserved key (content or a _veles_-prefixed system key), which callers may not set or filter on. crate::storage::AUTO_DATE_FIELD is the one documented exception: a caller MAY set it (e.g. to date a fact retroactively), so it never raises this error.

§

MetadataTooLarge

Caller-supplied metadata (on remember/remember_with_ttl or a context-compiler fragment) exceeded crate::limits::MAX_METADATA_BYTES — a DoS guard, since metadata is a keyed lookup facet, not a payload.

Fields

§bytes: usize

The serialized size of the rejected metadata, in bytes.

§max: usize

The cap that was exceeded (crate::limits::MAX_METADATA_BYTES).

§

Embed(EmbedError)

Failure producing a text embedding.

§

Extract(ExtractError)

Failure extracting facts from raw text in crate::service::MemoryService::remember_extracted.

§

Rerank(RerankError)

Failure reranking a fused-recall candidate pool in crate::service::MemoryService::recall_fused_reranked.

§

MigrationCapture(String)

The online-migration observer could not durably classify a mutation. The source write has not run when this error is returned.

§

Unsupported(&'static str)

The storage backend in use does not support the requested operation. A static description, not prose: the set of refusable operations is closed and known at compile time, and adapters display it verbatim.

§

InvalidFilter(String)

A fused-recall filter referenced a field name that is not a plain identifier, named a reserved key, or carried a non-scalar value.

§

InvalidRelation(String)

A relation label supplied to crate::service::MemoryService::relate or a crate::model::Link in crate::service::MemoryService::remember was invalid — empty, too long, or contained non-printable characters.

§

ContextBudget

A context-compile request carried a token budget that cannot hold any context: zero, or not larger than the response reserve the policy keeps aside for the model’s answer.

Fields

§budget: u64

The caller-supplied token budget.

§reserve: u64

The response reserve the policy subtracts from the budget.

§

ContextOverLimit(String)

A context-compile request exceeded a resource cap from crate::limits — too many fragments, or one fragment larger than the per-fragment byte ceiling.

§

SegmentationError(String)

A transcript segmentation request failed because of the transcript’s FORMAT, not its size — e.g. segmentation.format: "jsonl" forced on a line that does not parse as a {role, content} JSON object (see crate::context::segment::segment_transcript). Deliberately distinct from Self::ContextOverLimit (issue #1516, m2): a parsing failure is not a budget/cap breach, so a caller filtering on the error message no longer sees the misleading “over limit” wording for what is really a malformed-input error. Same ErrorCategory::InvalidInput classification as ContextOverLimit (both map to INVALID_PARAMS over MCP) — only the variant, and the message, differ.

§

UnknownHandle(String)

A ctx://source/<hash> handle was malformed or nothing is stored under it (the source was never stored, expired, or was forgotten).

§

FragmentIndexOutOfBounds

crate::service::MemoryService::explain_compilation’s fragment_index named a position beyond request.fragments.

Fields

§index: usize

The out-of-bounds index the caller supplied.

§len: usize

The actual number of fragments in the request.

§

FragmentNotFound(u64)

crate::service::MemoryService::explain_compilation found no decision matching the requested fragment_id (and no fragment_index was given, or it selected nothing new to check).

§

EmptyWorkingContext

crate::service::MemoryService::save_working_context was given a WorkingContext with nothing in it. The write is an idempotent upsert, so an empty save would replace — that is, destroy — the rich state already stored under this project and session. The one tool whose whole job is surviving a context loss must not be able to cause one on a call that carries nothing.

§

WorkingContextCodec

A persisted working context could not be (de)serialized — the stored payload predates or postdates this crate’s schema.

The one String-payload variant that gained structure, because it is the one that had lost some: half its construction sites flattened a serde_json::Error into prose, destroying the source() chain thiserror exists to preserve — and it is also the only variant matched programmatically (the index reader falls back to an empty index on it rather than failing a load). source is None where the corruption is structural (a marker with no body) rather than a codec refusal.

Fields

§detail: String

What was being encoded or decoded, and for which slot.

§source: Option<Box<Error>>

The codec’s own refusal, when there is one to preserve.

§

IngestDisabled

A context fragment carried a path (V2b-1 path ingestion) but no filesystem root is configured (VELESDB_MEMORY_INGEST_ROOTS unset or empty) — the tool is always advertised, but ingestion itself is opt-in. Also the fallback the pure compiler core reports when a path fragment reaches it unresolved (e.g. a binding that has no ingest adapter, such as the WASM build): crate::context never performs I/O itself, so an un-cleared path field always means the adapter that should have resolved or rejected it was skipped.

§

IngestOutsideRoots(String)

A path-referenced fragment resolved (after following symlinks) to a location outside every configured ingest root. Carries the caller-supplied path VERBATIM, never the canonicalized target — the resolved location may be filesystem structure the caller has no business learning about (e.g. that a symlink escapes).

§

IngestPath(String)

A path-referenced fragment could not be read for any reason other than escaping the ingest roots: a relative path (an MCP server’s working directory is unpredictable, so only absolute paths are accepted), a path that does not exist or is not a plain file (directories are rejected), a path fragment combined with non-empty content or a media payload (path is exclusive, though content and media may travel together), a fragment carrying none of the three, or a file whose bytes are not valid UTF-8.

§

RollbackFailed

A remember link failed after the fact was stored AND the compensating rollback delete also failed — unlike every other error from remember, the fact remains stored. Both errors are carried so the caller can see why the write failed and why the cleanup couldn’t undo it.

Neither field is #[source] — deliberately: the Display message already embeds both errors, and a source chain would double-print them in chain-style reports (anyhow, miette). Match on the variant to inspect the two errors programmatically.

Fields

§cause: Box<MemoryError>

The link failure that triggered the rollback.

§rollback: Box<MemoryError>

The storage failure that prevented the rollback delete.

Implementations§

Source§

impl MemoryError

Source

pub fn category(&self) -> ErrorCategory

Classify this error into a transport-neutral ErrorCategory. Adapters map the category, not the variant, so the client-facing taxonomy stays identical across the MCP server and every binding.

Trait Implementations§

Source§

impl Debug for MemoryError

Source§

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

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

impl Display for MemoryError

Source§

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

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

impl Error for MemoryError

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

impl From<AgentMemoryError> for MemoryError

Source§

fn from(source: AgentMemoryError) -> Self

Converts to this type from the input type.
Source§

impl From<EmbedError> for MemoryError

Source§

fn from(source: EmbedError) -> Self

Converts to this type from the input type.
Source§

impl From<Error> for MemoryError

Source§

fn from(source: CoreError) -> Self

Converts to this type from the input type.
Source§

impl From<ExtractError> for MemoryError

Source§

fn from(source: ExtractError) -> Self

Converts to this type from the input type.
Source§

impl From<RerankError> for MemoryError

Source§

fn from(source: RerankError) -> Self

Converts to this type from the input type.

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

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

Source§

fn fg(&self, value: Color) -> Painted<&T>

Returns a styled value derived from self with the foreground set to value.

This method should be used rarely. Instead, prefer to use color-specific builder methods like red() and green(), which have the same functionality but are pithier.

§Example

Set foreground color to white using fg():

use yansi::{Paint, Color};

painted.fg(Color::White);

Set foreground color to white using white().

use yansi::Paint;

painted.white();
Source§

fn primary(&self) -> Painted<&T>

Returns self with the fg() set to [Color :: Primary].

§Example
println!("{}", value.primary());
Source§

fn fixed(&self, color: u8) -> Painted<&T>

Returns self with the fg() set to [Color :: Fixed].

§Example
println!("{}", value.fixed(color));
Source§

fn rgb(&self, r: u8, g: u8, b: u8) -> Painted<&T>

Returns self with the fg() set to [Color :: Rgb].

§Example
println!("{}", value.rgb(r, g, b));
Source§

fn black(&self) -> Painted<&T>

Returns self with the fg() set to [Color :: Black].

§Example
println!("{}", value.black());
Source§

fn red(&self) -> Painted<&T>

Returns self with the fg() set to [Color :: Red].

§Example
println!("{}", value.red());
Source§

fn green(&self) -> Painted<&T>

Returns self with the fg() set to [Color :: Green].

§Example
println!("{}", value.green());
Source§

fn yellow(&self) -> Painted<&T>

Returns self with the fg() set to [Color :: Yellow].

§Example
println!("{}", value.yellow());
Source§

fn blue(&self) -> Painted<&T>

Returns self with the fg() set to [Color :: Blue].

§Example
println!("{}", value.blue());
Source§

fn magenta(&self) -> Painted<&T>

Returns self with the fg() set to [Color :: Magenta].

§Example
println!("{}", value.magenta());
Source§

fn cyan(&self) -> Painted<&T>

Returns self with the fg() set to [Color :: Cyan].

§Example
println!("{}", value.cyan());
Source§

fn white(&self) -> Painted<&T>

Returns self with the fg() set to [Color :: White].

§Example
println!("{}", value.white());
Source§

fn bright_black(&self) -> Painted<&T>

Returns self with the fg() set to [Color :: BrightBlack].

§Example
println!("{}", value.bright_black());
Source§

fn bright_red(&self) -> Painted<&T>

Returns self with the fg() set to [Color :: BrightRed].

§Example
println!("{}", value.bright_red());
Source§

fn bright_green(&self) -> Painted<&T>

Returns self with the fg() set to [Color :: BrightGreen].

§Example
println!("{}", value.bright_green());
Source§

fn bright_yellow(&self) -> Painted<&T>

Returns self with the fg() set to [Color :: BrightYellow].

§Example
println!("{}", value.bright_yellow());
Source§

fn bright_blue(&self) -> Painted<&T>

Returns self with the fg() set to [Color :: BrightBlue].

§Example
println!("{}", value.bright_blue());
Source§

fn bright_magenta(&self) -> Painted<&T>

Returns self with the fg() set to [Color :: BrightMagenta].

§Example
println!("{}", value.bright_magenta());
Source§

fn bright_cyan(&self) -> Painted<&T>

Returns self with the fg() set to [Color :: BrightCyan].

§Example
println!("{}", value.bright_cyan());
Source§

fn bright_white(&self) -> Painted<&T>

Returns self with the fg() set to [Color :: BrightWhite].

§Example
println!("{}", value.bright_white());
Source§

fn bg(&self, value: Color) -> Painted<&T>

Returns a styled value derived from self with the background set to value.

This method should be used rarely. Instead, prefer to use color-specific builder methods like on_red() and on_green(), which have the same functionality but are pithier.

§Example

Set background color to red using fg():

use yansi::{Paint, Color};

painted.bg(Color::Red);

Set background color to red using on_red().

use yansi::Paint;

painted.on_red();
Source§

fn on_primary(&self) -> Painted<&T>

Returns self with the bg() set to [Color :: Primary].

§Example
println!("{}", value.on_primary());
Source§

fn on_fixed(&self, color: u8) -> Painted<&T>

Returns self with the bg() set to [Color :: Fixed].

§Example
println!("{}", value.on_fixed(color));
Source§

fn on_rgb(&self, r: u8, g: u8, b: u8) -> Painted<&T>

Returns self with the bg() set to [Color :: Rgb].

§Example
println!("{}", value.on_rgb(r, g, b));
Source§

fn on_black(&self) -> Painted<&T>

Returns self with the bg() set to [Color :: Black].

§Example
println!("{}", value.on_black());
Source§

fn on_red(&self) -> Painted<&T>

Returns self with the bg() set to [Color :: Red].

§Example
println!("{}", value.on_red());
Source§

fn on_green(&self) -> Painted<&T>

Returns self with the bg() set to [Color :: Green].

§Example
println!("{}", value.on_green());
Source§

fn on_yellow(&self) -> Painted<&T>

Returns self with the bg() set to [Color :: Yellow].

§Example
println!("{}", value.on_yellow());
Source§

fn on_blue(&self) -> Painted<&T>

Returns self with the bg() set to [Color :: Blue].

§Example
println!("{}", value.on_blue());
Source§

fn on_magenta(&self) -> Painted<&T>

Returns self with the bg() set to [Color :: Magenta].

§Example
println!("{}", value.on_magenta());
Source§

fn on_cyan(&self) -> Painted<&T>

Returns self with the bg() set to [Color :: Cyan].

§Example
println!("{}", value.on_cyan());
Source§

fn on_white(&self) -> Painted<&T>

Returns self with the bg() set to [Color :: White].

§Example
println!("{}", value.on_white());
Source§

fn on_bright_black(&self) -> Painted<&T>

Returns self with the bg() set to [Color :: BrightBlack].

§Example
println!("{}", value.on_bright_black());
Source§

fn on_bright_red(&self) -> Painted<&T>

Returns self with the bg() set to [Color :: BrightRed].

§Example
println!("{}", value.on_bright_red());
Source§

fn on_bright_green(&self) -> Painted<&T>

Returns self with the bg() set to [Color :: BrightGreen].

§Example
println!("{}", value.on_bright_green());
Source§

fn on_bright_yellow(&self) -> Painted<&T>

Returns self with the bg() set to [Color :: BrightYellow].

§Example
println!("{}", value.on_bright_yellow());
Source§

fn on_bright_blue(&self) -> Painted<&T>

Returns self with the bg() set to [Color :: BrightBlue].

§Example
println!("{}", value.on_bright_blue());
Source§

fn on_bright_magenta(&self) -> Painted<&T>

Returns self with the bg() set to [Color :: BrightMagenta].

§Example
println!("{}", value.on_bright_magenta());
Source§

fn on_bright_cyan(&self) -> Painted<&T>

Returns self with the bg() set to [Color :: BrightCyan].

§Example
println!("{}", value.on_bright_cyan());
Source§

fn on_bright_white(&self) -> Painted<&T>

Returns self with the bg() set to [Color :: BrightWhite].

§Example
println!("{}", value.on_bright_white());
Source§

fn attr(&self, value: Attribute) -> Painted<&T>

Enables the styling Attribute value.

This method should be used rarely. Instead, prefer to use attribute-specific builder methods like bold() and underline(), which have the same functionality but are pithier.

§Example

Make text bold using attr():

use yansi::{Paint, Attribute};

painted.attr(Attribute::Bold);

Make text bold using using bold().

use yansi::Paint;

painted.bold();
Source§

fn bold(&self) -> Painted<&T>

Returns self with the attr() set to [Attribute :: Bold].

§Example
println!("{}", value.bold());
Source§

fn dim(&self) -> Painted<&T>

Returns self with the attr() set to [Attribute :: Dim].

§Example
println!("{}", value.dim());
Source§

fn italic(&self) -> Painted<&T>

Returns self with the attr() set to [Attribute :: Italic].

§Example
println!("{}", value.italic());
Source§

fn underline(&self) -> Painted<&T>

Returns self with the attr() set to [Attribute :: Underline].

§Example
println!("{}", value.underline());

Returns self with the attr() set to [Attribute :: Blink].

§Example
println!("{}", value.blink());

Returns self with the attr() set to [Attribute :: RapidBlink].

§Example
println!("{}", value.rapid_blink());
Source§

fn invert(&self) -> Painted<&T>

Returns self with the attr() set to [Attribute :: Invert].

§Example
println!("{}", value.invert());
Source§

fn conceal(&self) -> Painted<&T>

Returns self with the attr() set to [Attribute :: Conceal].

§Example
println!("{}", value.conceal());
Source§

fn strike(&self) -> Painted<&T>

Returns self with the attr() set to [Attribute :: Strike].

§Example
println!("{}", value.strike());
Source§

fn quirk(&self, value: Quirk) -> Painted<&T>

Enables the yansi Quirk value.

This method should be used rarely. Instead, prefer to use quirk-specific builder methods like mask() and wrap(), which have the same functionality but are pithier.

§Example

Enable wrapping using .quirk():

use yansi::{Paint, Quirk};

painted.quirk(Quirk::Wrap);

Enable wrapping using wrap().

use yansi::Paint;

painted.wrap();
Source§

fn mask(&self) -> Painted<&T>

Returns self with the quirk() set to [Quirk :: Mask].

§Example
println!("{}", value.mask());
Source§

fn wrap(&self) -> Painted<&T>

Returns self with the quirk() set to [Quirk :: Wrap].

§Example
println!("{}", value.wrap());
Source§

fn linger(&self) -> Painted<&T>

Returns self with the quirk() set to [Quirk :: Linger].

§Example
println!("{}", value.linger());
Source§

fn clear(&self) -> Painted<&T>

👎Deprecated since 1.0.1:

renamed to resetting() due to conflicts with Vec::clear(). The clear() method will be removed in a future release.

Returns self with the quirk() set to [Quirk :: Clear].

§Example
println!("{}", value.clear());
Source§

fn resetting(&self) -> Painted<&T>

Returns self with the quirk() set to [Quirk :: Resetting].

§Example
println!("{}", value.resetting());
Source§

fn bright(&self) -> Painted<&T>

Returns self with the quirk() set to [Quirk :: Bright].

§Example
println!("{}", value.bright());
Source§

fn on_bright(&self) -> Painted<&T>

Returns self with the quirk() set to [Quirk :: OnBright].

§Example
println!("{}", value.on_bright());
Source§

fn whenever(&self, value: Condition) -> Painted<&T>

Conditionally enable styling based on whether the Condition value applies. Replaces any previous condition.

See the crate level docs for more details.

§Example

Enable styling painted only when both stdout and stderr are TTYs:

use yansi::{Paint, Condition};

painted.red().on_yellow().whenever(Condition::STDOUTERR_ARE_TTY);
Source§

fn new(self) -> Painted<Self>
where Self: Sized,

Create a new Painted with a default Style. Read more
Source§

fn paint<S>(&self, style: S) -> Painted<&Self>
where S: Into<Style>,

Apply a style wholesale to self. Any previous style is replaced. Read more
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

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

Initializes a with the given initializer. Read more
Source§

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

Dereferences the given pointer. Read more
Source§

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

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
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 = Infallible

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

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

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