{"record":{"id":"5eba5e6ceb93e132","repo":"nautechsystems/nautilus_trader","slug":"not-running","errorCode":null,"errorMessage":"Not running","messagePattern":"Not running","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/live/src/node/mod.rs","lineNumber":525,"sourceCode":"\n        if !self.finish_startup_trader(None).await? {\n            return Ok(());\n        }\n\n        Ok(())\n    }\n\n    /// Stop the live node.\n    ///\n    /// This method stops the trader, waits for the configured grace period to allow\n    /// residual events to be processed, then finalizes the shutdown sequence.\n    ///\n    /// # Errors\n    ///\n    /// Returns an error if shutdown fails.\n    pub async fn stop(&mut self) -> anyhow::Result<()> {\n        if !self.state().is_running() {\n            anyhow::bail!(\"Not running\");\n        }\n\n        self.handle.set_shutting_down();\n\n        #[cfg(feature = \"plugin\")]\n        let controller_stop_result = self.plugins.stop_controllers();\n        #[cfg(not(feature = \"plugin\"))]\n        let controller_stop_result: anyhow::Result<()> = Ok(());\n\n        self.kernel.stop_trader();\n        let delay = self.kernel.delay_post_stop();\n        log::info!(\"Awaiting residual events ({delay:?})...\");\n\n        let residual_events = self.process_runner_for(delay).await;\n        if residual_events > 0 {\n            log::debug!(\"Processed {residual_events} residual events during shutdown\");\n        }\n","sourceCodeStart":507,"sourceCodeEnd":543,"githubUrl":"https://github.com/nautechsystems/nautilus_trader/blob/18893faf8b356be3320add8de2f861b0b647cf06/crates/live/src/node/mod.rs#L507-L543","documentation":"Lifecycle guard in LiveNode::stop: the node's state is not Running, so there is nothing to shut down and stop was called outside an active run. The call is rejected rather than performing a spurious shutdown.","triggerScenarios":"Thrown at crates/live/src/node/mod.rs:525 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Check the node state before calling stop","Only call stop after a successful start/run"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"18893faf8b356be3320add8de2f861b0b647cf06","analyzedAt":"2026-09-08T20:49:34.690Z","contentChangedAt":"2026-09-08T20:49:34.690Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}