agent: lumotia-rebrand — drop MagnotiaError prefix, now lumotia_core::Error
Phase 3 of the rebrand cascade per locked decision D4. MagnotiaError -> Error in crates/core/src/error.rs (the crate name already qualifies it). 92 usages across 14 .rs files renamed via word-boundary sed. One collision required disambiguation: lumotia_storage already had its own local Error type (introduced by the slop-pass Area A residuals work). crates/storage/src/error.rs aliases the imported core error as CoreError on import; the From<Error> for CoreError boundary impl and the CoreError::Storage construction site use the alias. cargo build --workspace passes. cargo test --workspace: 330 pass, 0 fail. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -9,7 +9,7 @@ use crate::types::ModelId;
|
||||
/// Implements `Serialize` so errors can be sent to the frontend as
|
||||
/// structured JSON rather than opaque strings.
|
||||
#[derive(Debug, thiserror::Error, Serialize)]
|
||||
pub enum MagnotiaError {
|
||||
pub enum Error {
|
||||
#[error("model not found: {0}")]
|
||||
ModelNotFound(ModelId),
|
||||
|
||||
@@ -55,7 +55,7 @@ pub enum MagnotiaError {
|
||||
},
|
||||
}
|
||||
|
||||
/// Coarse discriminator for `MagnotiaError::Storage`. The storage crate maps
|
||||
/// Coarse discriminator for `Error::Storage`. The storage crate maps
|
||||
/// its full typed error onto one of these kinds at the boundary. Backend code
|
||||
/// that wants finer-grained branching pattern-matches on
|
||||
/// `lumotia_storage::Error` directly.
|
||||
@@ -70,7 +70,7 @@ pub enum StorageKind {
|
||||
Filesystem,
|
||||
}
|
||||
|
||||
impl From<std::io::Error> for MagnotiaError {
|
||||
impl From<std::io::Error> for Error {
|
||||
fn from(err: std::io::Error) -> Self {
|
||||
Self::Io {
|
||||
kind: format!("{:?}", err.kind()),
|
||||
@@ -80,4 +80,4 @@ impl From<std::io::Error> for MagnotiaError {
|
||||
}
|
||||
}
|
||||
|
||||
pub type Result<T> = std::result::Result<T, MagnotiaError>;
|
||||
pub type Result<T> = std::result::Result<T, Error>;
|
||||
|
||||
@@ -9,7 +9,7 @@ pub mod recommendation;
|
||||
pub mod tuning;
|
||||
pub mod types;
|
||||
|
||||
pub use error::{MagnotiaError, Result};
|
||||
pub use error::{Error, Result};
|
||||
pub use types::{
|
||||
AudioSamples, DownloadProgress, EngineName, Megabytes, ModelId, Segment, Transcript,
|
||||
TranscriptionOptions,
|
||||
|
||||
Reference in New Issue
Block a user