mirror of
https://github.com/ruvnet/RuView
synced 2026-07-31 18:51:42 +00:00
521a012d84
New crate wifi-densepose-worldgraph: - model.rs: WorldNode (10 kinds) + WorldEdge (7 relations) as serde enums (no trait objects → deterministic RVF persistence); WorldId, EnuPoint, ZoneBoundsEnu (with point-in-bounds), SemanticProvenance (house-rule tuple) - graph.rs: WorldGraph over petgraph StableDiGraph; upsert/add_edge/neighbors, room_for_area (HomeCore area_id linkage), observed_by/contents_of queries, add_semantic_state (append-with-provenance DerivedFrom), add_contradiction (both beliefs retained), apply_privacy_mode → PrivacyRollup, JSON persistence - 7 tests (upsert/replace, linkage, unknown-endpoint, location, provenance+ contradiction, privacy rollup, deterministic JSON round-trip) - workspace 0 errors Co-Authored-By: claude-flow <ruv@ruv.net>
16 lines
410 B
Rust
16 lines
410 B
Rust
//! WorldGraph error type.
|
|
|
|
use crate::model::WorldId;
|
|
|
|
/// Errors from WorldGraph operations.
|
|
#[derive(Debug, thiserror::Error)]
|
|
pub enum WorldGraphError {
|
|
/// An edge endpoint referenced an unknown node.
|
|
#[error("unknown node {0:?}")]
|
|
UnknownNode(WorldId),
|
|
|
|
/// (De)serialisation of the persisted graph failed.
|
|
#[error("serialization error: {0}")]
|
|
Serde(#[from] serde_json::Error),
|
|
}
|