Skip to content
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

Websockets mode with custom receiver #780

Closed
4 of 10 tasks
jimmyhlee94 opened this issue Feb 4, 2021 · 6 comments
Closed
4 of 10 tasks

Websockets mode with custom receiver #780

jimmyhlee94 opened this issue Feb 4, 2021 · 6 comments
Labels
docs M-T: Documentation work only

Comments

@jimmyhlee94
Copy link

Description

I was testing out socket mode with an existing bot but was met with dispatch_failed errors. Turns out this was because the bot was using a custom express receiver, which takes the place of SocketModeReceiver in the framework code. I don't think I encountered any mention of this while I was reading about socket mode... Or if this is mentioned somewhere, I'd recommend calling this out somewhere a little more discoverable.

What type of issue is this? (place an x in one of the [ ])

  • bug
  • enhancement (feature request)
  • question
  • documentation related
  • example code related
  • testing related
  • discussion

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

Filling out the following details about bugs will help us solve your issue sooner.

Reproducible in:

package version: 3.0.0

node version: 14

OS version(s):

Steps to reproduce:

  1. Go back in time and create a bolt app with a custom express receiver before websocket mode was released
  2. migrate to Bolt v3
  3. enable socket mode
  4. confusion

Expected result:

It would be cool if the bolt framework could somehow tell you that the express receiver provided wasn't a correct implementation of a websocket receiver if App is initialized with socketMode flipped on. Not sure of the feasibility of this though.

I had turned on developerMode at some point hoping to see some kind of error message but saw none. It wasn't until I actually got socket mode working that I realized that I was supposed to get additional socket-related logs.

Actual result:

What actually happened

Attachments:

Logs, screenshots, screencast, sample project, funny gif, etc.

@gitwave gitwave bot added the untriaged label Feb 4, 2021
@stevengill stevengill added docs M-T: Documentation work only and removed untriaged labels Feb 5, 2021
@stevengill
Copy link
Member

Hey @jimmyhlee94,

Good point. We should add something to the documentation or a warning in the code about not being able to use expressReceiver and socketModeReceiver.

@seratch
Copy link
Member

seratch commented Mar 23, 2021

@stevengill @mwbrooks @misscoded @shaydewael Perhaps, we can add some mention about socket mode in https://slack.dev/bolt-js/tutorial/getting-started What do you think?

@seratch
Copy link
Member

seratch commented Mar 24, 2021

^ updates on my last comment - we may want to simply mention Socket Mode in the Getting Started document for reducing some possible confusion.

@smoneta
Copy link

smoneta commented May 21, 2021

In the bolt js documentation it mentions a code for SocketModeReceiver but does not provide an example for a custom route.. any change to add one? . I tested the code there but it fails to start saying that :

const socket_mode = new SocketModeReceiver({
                    ^

TypeError: SocketModeReceiver is not a constructor

@stevengill
Copy link
Member

@smoneta custom routes aren't currently supported by socketModeReceiver. See #866

@seratch
Copy link
Member

seratch commented Aug 18, 2021

To track the progress in a single place, let us close this issue now. Please check #866 for this topic.

@seratch seratch closed this as completed Aug 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs M-T: Documentation work only
Projects
None yet
Development

No branches or pull requests

4 participants