{"record":{"id":"110aa7efdb6e2b5a","repo":"zellij-org/zellij","slug":"failed-to-get-running-plugin","errorCode":null,"errorMessage":"Failed to get running plugin","messagePattern":"Failed to get running plugin","errorType":"exception","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"zellij-server/src/plugins/wasm_bridge.rs","lineNumber":1803,"sourceCode":"            };\n        }\n    }\n    pub fn cache_plugin_permissions(\n        &mut self,\n        plugin_id: PluginId,\n        client_id: Option<ClientId>,\n        permissions: Vec<PermissionType>,\n        status: PermissionStatus,\n        cache_path: Option<PathBuf>,\n    ) -> Result<()> {\n        let err_context = || format!(\"Failed to write plugin permission {plugin_id}\");\n\n        let running_plugin = self\n            .plugin_map\n            .lock()\n            .unwrap()\n            .get_running_plugin(plugin_id, client_id)\n            .ok_or_else(|| anyhow!(\"Failed to get running plugin\"))?;\n\n        let mut running_plugin = running_plugin.lock().unwrap();\n\n        let permissions = if status == PermissionStatus::Granted {\n            permissions\n        } else {\n            vec![]\n        };\n\n        running_plugin\n            .store\n            .data_mut()\n            .set_permissions(HashSet::from_iter(permissions.clone()));\n\n        let mut permission_cache = PermissionCache::from_path_or_default(cache_path);\n        permission_cache.cache(\n            running_plugin.store.data().plugin.location.to_string(),\n            permissions,","sourceCodeStart":1785,"sourceCodeEnd":1821,"githubUrl":"https://github.com/zellij-org/zellij/blob/a162323384dff3fbd9c68a4c0971f4f6efca424a/zellij-server/src/plugins/wasm_bridge.rs#L1785-L1821","documentation":"Error \"Failed to get running plugin\" thrown in zellij-org/zellij.","triggerScenarios":"Occurs at zellij-server/src/plugins/wasm_bridge.rs:1762 when the operation fails: \"Failed to get running plugin\". Currently there is no defensive handling preventing or contextualizing this failure before it surfaces.","commonSituations":"Race between plugin unload and a pending message or command.","solutions":["Ensure the plugin is loaded/started before sending it messages.","Handle plugin unload events so no messages are sent to gone plugins."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"a162323384dff3fbd9c68a4c0971f4f6efca424a","analyzedAt":"2026-08-19T07:42:58.758Z","contentChangedAt":"2026-08-19T07:42:58.758Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}