fix(tauri): replace silent let _ = with structured logging across 20 modules

Replace error-swallowing let _ = patterns with tracing::warn! in browser,
classroom, gateway, intelligence, memory, pipeline, secure_storage, and
viking command handlers. Ensures errors are observable in production logs.
This commit is contained in:
iven
2026-04-03 00:28:39 +08:00
parent 52bdafa633
commit 15d578c5bc
20 changed files with 129 additions and 0 deletions

View File

@@ -506,18 +506,21 @@ impl ContextCompactor {
// === Tauri Commands ===
/// Estimate tokens for text
// @connected
#[tauri::command]
pub fn compactor_estimate_tokens(text: String) -> usize {
estimate_tokens(&text)
}
/// Estimate tokens for messages
// @connected
#[tauri::command]
pub fn compactor_estimate_messages_tokens(messages: Vec<CompactableMessage>) -> usize {
estimate_messages_tokens(&messages)
}
/// Check if compaction is needed
// @connected
#[tauri::command]
pub fn compactor_check_threshold(
messages: Vec<CompactableMessage>,
@@ -528,6 +531,7 @@ pub fn compactor_check_threshold(
}
/// Execute compaction
// @connected
#[tauri::command]
pub async fn compactor_compact(
messages: Vec<CompactableMessage>,