CircuitError

Enum CircuitError 

Source
pub enum CircuitError {
Show 16 variants Parse(String), Op { block: String, node: String, source: OpParseError, }, Format { block: String, edge: String, source: FormatError, }, WeightFormatOnEdge { block: String, edge: String, format: String, }, Shape { block: String, edge: String, detail: String, }, State { block: String, state: String, detail: String, }, Dim { block: String, source: DimError, }, DanglingInput { block: String, node: String, edge: String, }, DanglingOutput(String), Duplicate { block: String, name: String, }, FormatMismatch { node: String, op: String, edge: String, format: String, expected: Option<String>, }, MixedPrecision { node: String, detail: String, }, Binding { node: String, detail: String, }, Layout(String), Include { name: String, detail: String, }, ShapeMismatch(String),
}
Expand description

2026-09-28: Why a circuit did not load or instantiate.

Variants§

§

Parse(String)

2026-09-28: Not valid TOML, or not the schema.

§

Op

2026-09-28: An op the vocabulary does not have, or a bad role or format qualifier.

Fields

§block: String

2026-09-28: Template.

§node: String

2026-09-28: Node id.

§source: OpParseError

2026-09-28: The op error.

§

Format

2026-09-28: A format spelling no format matches.

Fields

§block: String

2026-09-28: Template.

§edge: String

2026-09-28: Edge.

§source: FormatError

2026-09-28: The format error.

§

WeightFormatOnEdge

2026-09-28: A weight-only scale layout (channel, block) on an edge.

Fields

§block: String

2026-09-28: Template.

§edge: String

2026-09-28: Edge.

§format: String

2026-09-28: The format.

§

Shape

2026-09-28: A shape that is not <rows> x <dim>, or a bad expression in it.

Fields

§block: String

2026-09-28: Template.

§edge: String

2026-09-28: Edge.

§detail: String

2026-09-28: What was wrong.

§

State

2026-09-30: A state declaration that does not parse or evaluate.

Fields

§block: String

2026-09-30: Template.

§state: String

2026-09-30: State id.

§detail: String

2026-09-30: What was wrong.

§

Dim

2026-09-28: A dimension the arch shape does not define, or an overflow.

Fields

§block: String

2026-09-28: Template.

§source: DimError

2026-09-28: The dimension error.

§

DanglingInput

2026-09-28: A node reads an edge nothing produced.

Fields

§block: String

2026-09-28: Template.

§node: String

2026-09-28: Node id.

§edge: String

2026-09-28: Edge.

§

DanglingOutput(String)

2026-09-28: An edge nothing reads that is not a declared output.

§

Duplicate

2026-09-28: Two producers of one edge, or two nodes with one id.

Fields

§block: String

2026-09-28: Template.

§name: String

2026-09-28: Edge or node id.

§

FormatMismatch

2026-09-28: An edge whose format a reader does not accept.

Fields

§node: String

2026-09-28: The reading node.

§op: String

2026-09-28: Its op.

§edge: String

2026-09-28: The edge.

§format: String

2026-09-28: The edge’s format.

§expected: Option<String>

2026-09-28: What the reader expects, when it is one format.

§

MixedPrecision

2026-09-28: The modules of one node resolve to different formats.

Fields

§node: String

2026-09-28: Node id.

§detail: String

2026-09-28: The two resolutions.

§

Binding

2026-09-28: A weight-reading node without a binding, or a binding on a node that reads no weight but is not a norm.

Fields

§node: String

2026-09-28: Node id.

§detail: String

2026-09-28: What was wrong.

§

Layout(String)

2026-09-28: A layout that names a missing template, or a model whose layers the layout does not describe.

§

Include

2026-09-28: An included block file that was not supplied, does not parse, or defines a block another file also defines.

Fields

§name: String

2026-09-28: The include’s name.

§detail: String

2026-09-28: What was wrong.

§

ShapeMismatch(String)

2026-09-28: A dim the circuit requires that the arch shape does not give, or one it gives that the circuit does not declare.

Trait Implementations§

Source§

impl Clone for CircuitError

Source§

fn clone(&self) -> CircuitError

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for CircuitError

Source§

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

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

impl Display for CircuitError

Source§

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

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

impl Error for CircuitError

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<CircuitError> for CheckpointError

Source§

fn from(source: CircuitError) -> Self

Converts to this type from the input type.
Source§

impl From<CircuitError> for LoadError

Source§

fn from(source: CircuitError) -> Self

Converts to this type from the input type.
Source§

impl PartialEq for CircuitError

Source§

fn eq(&self, other: &CircuitError) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Eq for CircuitError

Source§

impl StructuralPartialEq for CircuitError

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> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

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> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
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.