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

python-socketio and python-engineio versions are incompatible #8092

Closed
adrianvisovan opened this issue Mar 3, 2021 · 3 comments · Fixed by #8343
Closed

python-socketio and python-engineio versions are incompatible #8092

adrianvisovan opened this issue Mar 3, 2021 · 3 comments · Fixed by #8343
Assignees
Labels
area:rasa-oss 🎡 Anything related to the open source Rasa framework type:bug 🐛 Inconsistencies or issues which will cause an issue or problem for users or implementors.

Comments

@adrianvisovan
Copy link

adrianvisovan commented Mar 3, 2021

Rasa version: 2.3.4

Socket.IO Javacsript client version: 3.1.2

Operating system: osx

Issue: Connecting to Rasa 2.3.4 using socket.io is not possible due to the versions incompatibility of python-socketio and python-engineio.

According to the official python-socketio documentation, if the version of the python-socketio is 5.X, then the version of python-engineio should be 4.X.

Solution could be to increment the version of python-engineio dependency to at least 4.0.0

Error:

message async handler error
Traceback (most recent call last):
  File "/opt/venv/lib/python3.8/site-packages/engineio/asyncio_server.py", line 423, in _trigger_event
    ret = await self.handlers[event](*args)
  File "/opt/venv/lib/python3.8/site-packages/socketio/asyncio_server.py", line 524, in _handle_eio_message
    await self._handle_connect(eio_sid, pkt.namespace)
  File "/opt/venv/lib/python3.8/site-packages/socketio/asyncio_server.py", line 408, in _handle_connect
    sid = self.manager.connect(eio_sid, namespace)
  File "/opt/venv/lib/python3.8/site-packages/socketio/base_manager.py", line 46, in connect
    sid = self.server.eio.generate_id()
AttributeError: 'AsyncServer' object has no attribute 'generate_id'

Command or request that led to error:

Connecting to Rasa 2.3.4 using socketio from the Javascript socket.io-client:

io('http://localhost:5005', {
      path: '/socket.io/',
      transports: ['websocket']
    })

Content of configuration file (credentials.yml)

socketio:
  user_message_evt: user_uttered
  bot_message_evt: bot_uttered
  session_persistence: false
@adrianvisovan adrianvisovan added area:rasa-oss 🎡 Anything related to the open source Rasa framework type:bug 🐛 Inconsistencies or issues which will cause an issue or problem for users or implementors. labels Mar 3, 2021
@sara-tagger
Copy link
Collaborator

Thanks for raising this issue, @samsucik will get back to you about it soon✨

Please also check out the docs and the forum in case your issue was raised there too 🤗

@mrka124
Copy link

mrka124 commented Mar 24, 2021

Is this fixed in 2.4.0?

@nmhjoyal
Copy link

nmhjoyal commented Mar 28, 2021

We are also awaiting a fix for this. Our project uses pip-tools so we can't upgrade Rasa until dependencies are compatible

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:rasa-oss 🎡 Anything related to the open source Rasa framework type:bug 🐛 Inconsistencies or issues which will cause an issue or problem for users or implementors.
Projects
None yet
5 participants