-
-
Notifications
You must be signed in to change notification settings - Fork 52.6k
Closed
Description
GitHub Issue: Slack Channel with Invalid Bot Causes Gateway Hang
Priority: Critical/High
Summary
When a Slack bot is removed from a Slack workspace while still configured in OpenClaw channels, the gateway enters an infinite retry loop and becomes completely unresponsive. The entire gateway hangs and cannot be restarted until the invalid channel is manually removed via CLI.
Steps to Reproduce
- Configure a Slack channel with a bot (e.g.,
coderchannel) - Remove the bot from the Slack workspace (or deactivate the bot account)
- The OpenClaw config still has the channel configured
- Try to start or restart the gateway
Expected Behavior
- Gateway should log the error once
- Gateway should skip the invalid channel and continue running
- Other channels should work normally
- Invalid channel should be automatically disabled or flagged
Actual Behavior
- Gateway retries the invalid channel every ~1.5 seconds indefinitely
- Entire gateway becomes unresponsive
- Cannot restart gateway
- Must manually run
openclaw channels remove <channel>to recover
Log Evidence
[slack] [coder] starting provider
Unhandled promise rejection: Error: An API error occurred: account_inactive
[slack] [coder] starting provider
Unhandled promise rejection: Error: An API error occurred: account_inactive
[ERROR] socket-mode:SocketModeClient:0 Failed to retrieve a new WSS URL (error: Error: An API error occurred: invalid_auth)
[slack] socket mode failed to start. retry 1/12 in 2s (An API error occurred: invalid_auth)
[slack] [coder] starting provider
Unhandled promise rejection: Error: An API error occurred: account_inactive
... (repeats indefinitely)
Environment
- OpenClaw version: (fill in with
openclaw --version) - OS: macOS (Darwin 25.3.0 arm64)
- Slack channel type: bot user
Impact
- Severity: High - Causes complete gateway outage
- User Experience: Poor - Requires manual CLI intervention to recover
- Workaround: Manual - Must run
openclaw channels remove <channel>from CLI
Suggested Fixes
Short-term
- Catch
account_inactiveandinvalid_autherrors specifically - Log error once and skip the channel (don't retry)
- Continue gateway startup for other valid channels
Long-term
- Add auto-disable for invalid channels
- Add health check on startup to validate channels
- Add retry limit with exponential backoff (max 3 retries, then skip)
- Add CLI command to list invalid channels:
openclaw channels validate
Workaround for Users
# List channels
openclaw channels list
# Remove invalid channel
openclaw channels remove <channel-name>
# Restart gateway
openclaw gateway restartRelated Files
- Slack provider initialization code
- Channel configuration validation
- Error handling for Slack API errors
Date Reported
2026-03-02
Reported By
OpenClaw user (Joe Curry)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels