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

bug: websockets.exceptions.ConnectionClosedError: no close frame received or sent #84

Open
mikeshultz opened this issue May 15, 2024 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@mikeshultz
Copy link
Contributor

What went wrong?

Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/silverback_platform/runner.py", line 238, in _process_events
    async for raw_event in self.subscriptions.get_subscription_data(sub_id):
  File "/usr/local/lib/python3.11/site-packages/silverback/subscriptions.py", line 123, in get_subscription_data
    await self.__anext__()
  File "/usr/local/lib/python3.11/site-packages/silverback/subscriptions.py", line 49, in __anext__
    message = await self.connection.recv()
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/websockets/legacy/protocol.py", line 568, in recv
    await self.ensure_open()
  File "/usr/local/lib/python3.11/site-packages/websockets/legacy/protocol.py", line 939, in ensure_open
    raise self.connection_closed_exc()
websockets.exceptions.ConnectionClosedError: no close frame received or sent

How can it be fixed?

Would be good to have better error handling and recovery for Websockets. For long running processes, these errors are inevitable.

@mikeshultz mikeshultz added the bug Something isn't working label May 15, 2024
@fubuloubu
Copy link
Member

p.s. was trying to tackle this in #78 if you want to take the torch on that

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants