subconscious: a failed pass must not report as a quiet one
The Err branch surfaced the same 'no anomalies detected' text as the success path, at Low urgency. A subconscious erroring on every turn was indistinguishable from one noticing nothing. The only record of the real cause was a tracing::warn on a stderr whose socket has no reader. Carry the error in-band at High, and say the pass failed.
This commit is contained in:
parent
29ec9fe223
commit
3175700ea2
1 changed files with 17 additions and 10 deletions
|
|
@ -454,16 +454,23 @@ impl ConsciousnessEngine {
|
|||
tracing::warn!("subconscious queue failed: {}", e);
|
||||
}
|
||||
}
|
||||
// Always surface at least a heartbeat so the user can see the
|
||||
// subconscious is trying — even when subconscious errors out.
|
||||
if heuristics.is_empty() {
|
||||
let _ = inbox
|
||||
.queue(InboxItem::new(
|
||||
"surface",
|
||||
Urgency::Low,
|
||||
"Subconscious pass ran — no anomalies detected.",
|
||||
))
|
||||
.await;
|
||||
// A failed pass must never be reported as a quiet one. The old
|
||||
// text here ("pass ran — no anomalies detected") was
|
||||
// indistinguishable from the success heartbeat, so a
|
||||
// subconscious that errored on every turn read to the primary
|
||||
// as a subconscious that simply noticed nothing. It stayed
|
||||
// that way for a full session: the only report of the real
|
||||
// cause was a `tracing::warn!` on a stderr with no reader.
|
||||
//
|
||||
// Carry the error in-band instead, at an urgency that is not
|
||||
// ignorable, and say plainly that the pass did not run.
|
||||
let beat = format!("Subconscious pass FAILED — {e}");
|
||||
let _ = inbox
|
||||
.queue(InboxItem::new("surface", Urgency::High, beat.clone()))
|
||||
.await;
|
||||
// Durable too — the inner-voice file survives the socket.
|
||||
if let Err(e) = inbox.surface_to_conscious(Urgency::High, &beat).await {
|
||||
tracing::warn!("inner voice failure-beat delivery failed: {}", e);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue