pub enum RuntimeError {
ActorGone,
Core(CoreError),
Grammar(CommandError),
ReadOnly,
SourcesChangedOnDisk {
paths: Vec<PathBuf>,
},
}Expand description
Failure modes a runtime caller can observe. Kept narrow so the UI can branch on the failure shape rather than a generic message.
Variants§
ActorGone
The actor task has terminated (panic, drop, or graceful shutdown) before it could respond. Treated as a permanent failure – the caller should re-spawn the document.
Core(CoreError)
An inner [lattice_core::CoreError] from
Document::apply_edit / undo / redo. The actor is healthy;
the operation itself was invalid.
Grammar(CommandError)
A [lattice_grammar::CommandError] from a
lattice_grammar::execute dispatch (unknown command, bad
args, motion out-of-bounds, …). The actor is healthy; the
invocation was invalid.
ReadOnly
M.1 (2026-05-31): write attempted against a read-only
document. Returned by MultibufferDocumentHandle’s
mutating methods until M.3 lands edit propagation.
Distinguishes “this buffer doesn’t accept writes by
design” from ActorGone (transient / recoverable) and
Core / Grammar (the write was tried but invalid).
SourcesChangedOnDisk
SS.3 (2026-08-11): a multibuffer save refused one or more sources because the file changed on disk after the view snapshotted it.
Typed rather than a message blob because the caller wants the
paths: the user has to go look at those files, and the recovery
(refresh the view — gr / :copen / :search — which re-reads
from disk) is per-view, not per-error-string.
The other sources in the same save DID persist; this is a
partial-success report, not a failed write. See
docs/dev/architecture/multibuffer-stale-sources.md §2.1.
Trait Implementations§
Source§impl Debug for RuntimeError
impl Debug for RuntimeError
Source§impl Display for RuntimeError
impl Display for RuntimeError
Source§impl Error for RuntimeError
impl Error for RuntimeError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()