bookclerk_plugin_manifest::error

Development These docs follow the development version and change with every merge.

Last updated View as Markdown

Manifest parse and semantic-validation errors.

All fallible entry points in this crate (crate::parse, crate::validate_plugin_id, crate::validate_logo, crate::format_manifest, and so on) return Result with this enum@Error type. TOML serde failures are preserved via Error::TomlDe / Error::TomlSer; semantic rules use Error::Message.

Item Kind Summary
Error enum Errors produced while deserializing or validating plugin.toml.
Result type alias Result alias for manifest parse, validate, and format operations.

Enums

Error

pub enum Error {
    Message(String),
    TomlDe(Error),
    TomlSer(Error),
}

Errors produced while deserializing or validating plugin.toml.

Display implementations are operator-facing (prefixed where useful, e.g. toml: …). There is no structured error code; callers typically match on the variant or format the message for CLI / doctor output.

Variants

  • Message: Operator-facing semantic failure with no structured code.

    Used for id grammar, runtime field requirements, network domain rules, logo validation, and similar checks after TOML deserialize succeeds.

  • TomlDe: TOML deserialize failure from toml::from_str.

  • TomlSer: TOML serialize failure from canonical crate::format_manifest.

Error::message

pub fn message(msg: impl Into<String>) -> Self

Builds an Error::Message from any string-like value.

Arguments
  • msg - Human-readable explanation (often prefixed with plugin.toml:).
Returns

An Error::Message wrapping the owned string.

Implements: Debug, Display, Error, From<Error>

Type aliases

Result

pub type Result<T> = Result<T, Error>;

Result alias for manifest parse, validate, and format operations.

Generated from crates/bookclerk-plugin-manifest at main · View as Markdown