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

Websocket is disconnected after aprox. 60 seconds #89

Open
dpvro opened this issue Oct 13, 2022 · 0 comments
Open

Websocket is disconnected after aprox. 60 seconds #89

dpvro opened this issue Oct 13, 2022 · 0 comments
Assignees

Comments

@dpvro
Copy link

dpvro commented Oct 13, 2022

Hello everyone,

recently I have noticed that my websocket is not working anymore. It was working fine for 2 weeks and out of a sudden, is not working anymore.

I am adding all callbacks

websocket = websocket.WebSocketApp( url=websocket_link, on_open=on_open, on_message=on_message, on_error=on_error, on_close=on_close, on_ping=on_ping, on_pong=on_pong )

I am starting the websocket with the ping configuration which I got by calling the "bullet-public" endpoint:

` msg = {
'id': str(int(time.time() * 1000)),
'type': 'ping'
}

           websocket.run_forever(ping_interval=pingInterval,
                                              ping_timeout=pingTimeout,
                                              ping_payload=json.dumps(msg))`

I get data for 60 seconds and after that it gets disconnected.

websocket - ERROR - Connection to remote host was lost. - goodbye

and after this error message the on_error callback is called and after that the "on_close" callback is called.
For the on_error callback I get one error message: "Error: Connection to remote host was lost"

Is the handling of ping an issue or something is changed in the last days? I have tried this script of connection and getting data from websocket using other IP but same result.

@ISAAC-XXYYZZ ISAAC-XXYYZZ self-assigned this Aug 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants