I have a Angular project that embedds the official Rasa widget in one page. The site uses Nginx as a reverse proxy to forward requests to a Rasa Docker container, and I use Rasa’s socketio channel for the communication. The widget also uses the “data-initial-payload” parameter to trigger the bot - it will respond with three messages.
When I use the widget I experience unstable behavior. There are these three cases what can happen:
- The widget works as as expected, i.e., the three initial messages appear and I can chat with the bot.
- One or two of the three messages appear and I can chat with the bot.
- No message appears and I cannot chat.
In the last case, the browser indicates that it cannot create a websocket connection. This is the error that I see:
WebSocket connection to 'ws://hostabcd/aa/socket.io/?EIO=4&transport=websocket&sid=j4L50ULhQQuLOUeUAAAi' failed: Error during WebSocket handshake: Unexpected response code: 200
Does anyone have ideas why this happens or has similar experiences?