Skip to content

Latest version 5.12.0 is throwing error on close #1429

@vinod-canihelp

Description

@vinod-canihelp

IMPORTANT: If you have a question, or you are not sure if you have found a bug in this package, then you are in the wrong place. Hit back in your web browser, and then open a GitHub Discussion instead. Likewise, if you are unable to provide the information requested below, open a discussion to troubleshoot your issue.

Describe the bug
A clear and concise description of what the bug is. If you are getting errors, please include the complete error message, including the stack trace.

I use fastapi with socketio. I recently upgraded to 5.12.0. In localhost, on closing the app I see the logs below in console:

Traceback (most recent call last):
  File "/Users/vinodkumar/.pyenv/versions/3.11.8/envs/mono-311/lib/python3.11/site-packages/engineio/async_server.py", line 509, in run_async_handler
    return await self.handlers[event](*args)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: InstrumentedAsyncServer._handle_eio_disconnect() takes 2 positional arguments but 3 were given

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/vinodkumar/.pyenv/versions/3.11.8/envs/mono-311/lib/python3.11/site-packages/engineio/async_server.py", line 515, in run_async_handler
    return await self.handlers[event](args[0])
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/vinodkumar/.pyenv/versions/3.11.8/envs/mono-311/lib/python3.11/site-packages/socketio/async_admin.py", line 297, in _handle_eio_disconnect
    return await self.sio._handle_eio_disconnect(eio_sid)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: AsyncServer._handle_eio_disconnect() missing 1 required positional argument: 'reason'

To Reproduce
Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior
A clear and concise description of what you expected to happen.

Logs
Please provide relevant logs from the server and the client. On the Python server and client, add the logger=True and engineio_logger=True arguments to your Server() or Client() objects to get logs dumped on your terminal. If you are using the JavaScript client, see here for how to enable logs.

Additional context
Add any other context about the problem here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions