Skip to content

Slack message tool: agent loops on message_not_found / fileId errors, burns API quota #37544

Description

@PamelaFernandez2

Problem

When the Slack message tool encounters message_not_found or fileId required errors, the agent retries in a tight loop rather than failing fast. This burns through API rate limits and cascades into failures for all other sessions (cron jobs, heartbeats, etc).

What happened

A Slack session got stuck retrying message_not_found (9 rapid retries) and fileId required (4 retries) on a thread target. This exhausted the Anthropic API rate limit, which then caused every subsequent heartbeat (every 15 min) and cron job to fail for ~4 hours.

Suggested fixes

  1. Fail fast on non-retryable Slack errors: message_not_found, fileId required, channel_not_found are permanent errors — retrying won't help. The tool should return an error to the agent immediately instead of retrying.

  2. Rate limit isolation: Ideally, rate limit budget for cron/heartbeat sessions should be isolated from interactive/Slack sessions, so one runaway session can't starve everything else.

  3. Circuit breaker for message tool: After N consecutive failures on the same target, stop retrying and surface the error.

Environment

  • OpenClaw version: 2026.3.2
  • Channel: Slack (Socket Mode)
  • Model: anthropic/claude-opus-4-6

Logs

[tools] message failed: fileId required (x4)
[tools] message failed: message_not_found (x9)
API rate limit reached (every 15 min, 4-5 retries each, ~4 hours total)

Metadata

Metadata

Assignees

No one assigned

    Labels

    staleMarked as stale due to inactivity

    Type

    No type

    Fields

    Priority

    None yet

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions