I am trying to connect to a websocket api, bybit's websocket for the ones that are interested. I tried everything and read every documantation I could find, it's still giving me and Error:
[SSL: TLSV1_ALERT_INTERNAL_ERROR] tlsv1 alert internal error (_ssl.c:1076)
My code looks as followed:
import websocket
def on_message(ws, message):
print(message)
def on_error(ws, error):
print(error)
def on_close(ws):
print("### closed ###")
def on_open(ws):
ws.send("{'op': 'subscribe', 'args': ['orderBookL2_25.BTCUSDT']}")
ws = websocket.WebSocketApp(url="wss://stream-testnet.bybit.com/realtime_public",
on_message=on_message,
on_error=on_error,
on_close=on_close,
on_open=on_open)
ws.run_forever()
I anyone knows what the problem is or could be, please tell me/helm me, I have been banging my head agains the wall for the past 2 days because of this. Thanks in advance :)