-
Notifications
You must be signed in to change notification settings - Fork 674
TypeError: Cannot read properties of undefined (reading 'type') at SocketModeClient.onWebSocketMessage #2167
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
HI @levenleven! Thanks for bringing this to our attention. Unfortunately, we'll need more information in order to begin to debug and remedy what is going on here. If you're able to provide which event(s) that this error is occurring for, that'd be a great start. |
@misscoded thanks for looking into this. We subscribe to message events using bolt sdk (e.g. |
Are message events the only events that your app listens for/subscribes to then? On your end and with your own logs, are you able to narrow down which specific message event type is causing the issue? |
Sorry, missed we also have This is not reproducible (at least now), we've got ~ 20 such errors between Mar 5, 2025 10:40:00 PM UTC and Mar 6, 2025 10:51:30 PM UTC
No, as this is happening not in application but in framework code. |
No worries! If you provide us your app ID, we might be able to look into the logs and figure out what the event in question is. |
Thanks! App id is |
Few other occasions
|
@misscoded Is there anything else I can do to help with the investigation? |
Sometimes we get an error due to
event.payload.event
being undefinednode-slack-sdk/packages/socket-mode/src/SocketModeClient.ts
Line 344 in 039bd05
Packages:
Select all that apply:
@slack/web-api
@slack/rtm-api
@slack/webhooks
@slack/oauth
@slack/socket-mode
@slack/types
Reproducible in:
The Slack SDK version
"@slack/socket-mode": "1.3.6"
Node.js runtime version
OS info
Steps to reproduce:
N/A
Expected result:
Missing payload handled gracefully
Actual result:
Unhandled error
Requirements
For general questions/issues about Slack API platform or its server-side, could you submit questions at https://my.slack.com/help/requests/new instead. 🙇
Please read the Contributing guidelines and Code of Conduct before creating this issue or pull request. By submitting, you are agreeing to those rules.
The text was updated successfully, but these errors were encountered: