{"record":{"id":"be405efead3ae9d7","repo":"zeroclaw-labs/zeroclaw","slug":"slack-reactions-remove-failed-status-sanitiz","errorCode":null,"errorMessage":"Slack reactions.remove failed ({status}): {sanitized}","messagePattern":"Slack reactions\\.remove failed \\((.+?)\\): (.+?)","errorType":"exception","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"crates/zeroclaw-channels/src/slack.rs","lineNumber":5553,"sourceCode":"            \"channel\": channel_id,\n            \"timestamp\": ts,\n            \"name\": name\n        });\n\n        let resp = self\n            .http_client()\n            .post(\"https://slack.com/api/reactions.remove\")\n            .bearer_auth(&self.bot_token)\n            .json(&body)\n            .send()\n            .await?;\n\n        let status = resp.status();\n        let text = resp.text().await.unwrap_or_default();\n\n        if !status.is_success() {\n            let sanitized = zeroclaw_providers::sanitize_api_error(&text);\n            anyhow::bail!(\"Slack reactions.remove failed ({status}): {sanitized}\");\n        }\n\n        let parsed: serde_json::Value = serde_json::from_str(&text).unwrap_or_default();\n        if parsed.get(\"ok\") == Some(&serde_json::Value::Bool(false)) {\n            let err = parsed\n                .get(\"error\")\n                .and_then(|e| e.as_str())\n                .unwrap_or(\"unknown\");\n            if err != \"no_reaction\" {\n                anyhow::bail!(\"Slack reactions.remove failed: {err}\");\n            }\n        }\n\n        Ok(())\n    }\n\n    async fn listen(&self, tx: tokio::sync::mpsc::Sender<ChannelMessage>) -> anyhow::Result<()> {\n        // Cache the bot user id on the struct so `self_handle` (sync,","sourceCodeStart":5535,"sourceCodeEnd":5571,"githubUrl":"https://github.com/zeroclaw-labs/zeroclaw/blob/88bb9c8533fc57ed7a03e36ca7c9ed2bf8336dcc/crates/zeroclaw-channels/src/slack.rs#L5535-L5571","documentation":"Error \"Slack reactions.remove failed ({status}): {sanitized}\" thrown in zeroclaw-labs/zeroclaw.","triggerScenarios":"Thrown at crates/zeroclaw-channels/src/slack.rs:5553 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Verify the reaction exists on the message and the token has reactions:write scope; check the returned status."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"88bb9c8533fc57ed7a03e36ca7c9ed2bf8336dcc","analyzedAt":"2026-08-23T01:07:41.857Z","schemaVersion":2},"datasetVersion":"2026-08-23T08:06:27.607Z"}