Skip to content

[Bug]: Slack provider crashes on startup — Bolt 4.6 rejects message.channels/message.groups event registration #32032

@mahopan

Description

@mahopan

Bug type

Regression (introduced by #31701 / #31758)

Summary

After PR #31701 and #31758 were merged, all Slack accounts enter a crash loop on startup. The root cause is that @slack/bolt@4.6.0 explicitly rejects app.event() calls with event names starting with "message." (such as "message.channels" and "message.groups"), throwing AppInitializationError.

The error message from Bolt:

Although the document mentions "message.channels", it is not a valid event type. Use "message" instead. If you want to filter message events, you can use event.channel_type for it.

Root cause

PR #31701 assumed that Slack dispatches events with typed names like message.channels to Bolt handlers. In reality:

  • message.channels, message.groups, etc. are Slack Event Subscription names (configured in the Slack App manifest)
  • The actual event payload always arrives with type: "message" — the channel_type field ("channel" | "group" | "im" | "mpim") distinguishes the source
  • The existing app.event("message") handler already receives all message events regardless of subscription type

Steps to reproduce

  1. Run OpenClaw with @slack/bolt@4.6.0 and code from after Slack: handle message.channels and message.groups events #31701 merge
  2. Observe all Slack accounts fail to start with exponential backoff retries

Expected behavior

Slack providers connect successfully via Socket Mode.

Actual behavior

All Slack accounts crash loop:

[slack] [daru] starting provider
[slack] [daru] auto-restart attempt 1/10 in 5s
[slack] [default] starting provider
[slack] [default] auto-restart attempt 1/10 in 5s
...

Environment

  • OpenClaw: v2026.3.2
  • @slack/bolt: 4.6.0
  • OS: macOS (Apple Silicon)

Impact

Critical — All Slack connectivity is broken. No Slack messages can be sent or received.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions