{"record":{"id":"02c7620e88209d5f","repo":"Hmbown/CodeWhale","slug":"trigger-trigger-id-not-found","errorCode":null,"errorMessage":"Trigger '{trigger_id}' not found","messagePattern":"Trigger '(.+?)' not found","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/tui/src/automation_manager.rs","lineNumber":1386,"sourceCode":"                CURRENT_TRIGGER_SCHEMA_VERSION\n            );\n        }\n        Ok(record)\n    }\n\n    /// Load a trigger only when it belongs to the given session.\n    ///\n    /// Foreign, ownerless legacy, unreadable, and absent records share the same\n    /// result so trigger existence cannot be disclosed across sessions.\n    pub fn get_trigger_for_owner(\n        &self,\n        trigger_id: &str,\n        owner_session_id: &str,\n    ) -> Result<DelayedTriggerRecord> {\n        self.get_trigger(trigger_id)\n            .ok()\n            .filter(|record| record.owner_session_id.as_deref() == Some(owner_session_id))\n            .ok_or_else(|| anyhow::anyhow!(\"Trigger '{trigger_id}' not found\"))\n    }\n\n    /// Atomically persist a trigger record.\n    pub fn save_trigger(&self, record: &DelayedTriggerRecord) -> Result<()> {\n        let path = self.trigger_path(&record.trigger_id)?;\n        write_json_atomic(&path, record)\n    }\n\n    /// List triggers, newest first.  Pass `status_filter` to restrict results.\n    pub fn list_triggers(\n        &self,\n        status_filter: Option<DelayedTriggerStatus>,\n        limit: Option<usize>,\n    ) -> Result<Vec<DelayedTriggerRecord>> {\n        let mut out = Vec::new();\n        if !self.triggers_dir.exists() {\n            return Ok(out);\n        }","sourceCodeStart":1368,"sourceCodeEnd":1404,"githubUrl":"https://github.com/Hmbown/CodeWhale/blob/0c42157ee52f9d55af2b506d71b46249910f77d3/crates/tui/src/automation_manager.rs#L1368-L1404","documentation":"get_trigger_for_owner found no delayed-trigger record for trigger_id that is owned by owner_session_id. Per the documented contract, absent, foreign, ownerless-legacy, and unreadable records all collapse into this one not-found error so cross-session trigger existence cannot be probed.","triggerScenarios":"Thrown at crates/tui/src/automation_manager.rs:1386 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Verify the trigger id before calling — it may have fired and been deleted","Confirm the trigger belongs to the current session; foreign triggers are intentionally invisible","List the session's triggers to get a valid id"],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"0c42157ee52f9d55af2b506d71b46249910f77d3","analyzedAt":"2026-08-20T21:50:45.477Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}