Skip to content

Connection Issue: socket-mode:SlackWebSocket:14 A pong wasn't received from the server before the timeout of 5000ms! #2496

Description

@Bart3on

(Filling out the following with as much detail as you can provide will help us solve your issue sooner.)

@slack/bolt version

4.2.1

Your App and Receiver Configuration

const slackAppProvider = {
provide: App,
useFactory: (configService: ConfigService) => {
const botToken = configService.get('SLACK_BOT_TOKEN');
const signingSecret = configService.get('SLACK_SIGNING_SECRET');
const appToken = configService.get('SLACK_APP_LEVEL_TOKEN');

if (!botToken || !signingSecret || !appToken) {
  throw new Error('Missing required Slack environment variables');
}

return new App({
  token: botToken,
  signingSecret: signingSecret,
  appToken: appToken,
  socketMode: true,
});

},
inject: [ConfigService],
};

Node.js runtime version

node:22-alpine

Steps to reproduce:

(Share the commands to run, source code, and project settings)

Expected result:

Hello i get sometimes issues with the connection to the slack server which leads that my customers can use my app till it reconnects correctly.
It is often like it has issue for 60 seconds then it reconnects agian correctly and it works then correctly till next connection Issue comes

Actual result:

Here is what my app logs

[WARN] socket-mode:SlackWebSocket:13 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:13 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:13 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:13 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:13 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:13 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:14 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:14 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:14 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:14 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:14 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:14 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:14 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:14 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:14 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:14 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:14 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:14 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:14 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:14 A ping wasn't received from the server before the timeout of 30000ms!
[WARN] socket-mode:SlackWebSocket:14 A pong wasn't received from the server before the timeout of 5000ms!
[WARN] socket-mode:SlackWebSocket:14 A pong wasn't received from the server before the timeout of 5000ms!
[ERROR] socket-mode:SocketModeClient:0 Failed to send a message as the client has no active connection
[NestWinston] 18 2025-04-11 11:35:59 ERROR In DynamicIssueSelectedActionService in execute method method Ticket went something wrong Error: Failed to send a WebSocket message as the client is not ready - { stack: [ null ] }
[ERROR] bolt-app UnknownError: In DynamicIssueSelectedActionService in execute method method Ticket went something wrong Error: Failed to send a WebSocket message as the client is not ready
at asCodedError (/app/node_modules/@slack/bolt/dist/errors.js:47:12)
at App.handleError (/app/node_modules/@slack/bolt/dist/App.js:691:59)
at App.processEvent (/app/node_modules/@slack/bolt/dist/App.js:676:25)
at process.processTicksAndRejections (node:internal/process/task_queues:105:5)
at async SocketModeClient. (/app/node_modules/@slack/bolt/dist/receivers/SocketModeReceiver.js:142:17) {
code: 'slack_bolt_unknown_error',
original: Error: In DynamicIssueSelectedActionService in execute method method Ticket went something wrong Error: Failed to send a WebSocket message as the client is not ready
at DynamicIssueSelectedActionService.execute (/app/dist/slack/actions/dynamic-issue-selected-action.service.js:226:19)
at process.processTicksAndRejections (node:internal/process/task_queues:105:5)
at async SlackActionController.handleDynamicChildIssueSelect (/app/dist/slack/actions/slack.action.controller.js:31:9)
at async Array. (/app/node_modules/@slack/bolt/dist/middleware/builtin.js:161:9)
at async Array.onlyActions (/app/node_modules/@slack/bolt/dist/middleware/builtin.js:30:9)
at async Promise.allSettled (index 5)
at async /app/node_modules/@slack/bolt/dist/App.js:662:48
at async Array. (/app/node_modules/@slack/bolt/dist/conversation-store.js:67:9)
at async Array.ignoreSelf (/app/node_modules/@slack/bolt/dist/middleware/builtin.js:264:5)
at async App.processEvent (/app/node_modules/@slack/bolt/dist/App.js:640:13)
}
[ERROR] An unhandled error occurred while Bolt processed (type: block_actions, error: Error: In DynamicIssueSelectedActionService in execute method method Ticket went something wrong Error: Failed to send a WebSocket message as the client is not ready)
[ERROR] socket-mode:SocketModeClient:0 Failed to send a message as the client has no active connection

Metadata

Metadata

Labels

auto-triage-staleneeds infoAn issue that is claimed to be a bug and hasn't been reproduced, or otherwise needs more infoserver-side-issue

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions