I'm using the simplest example to connect:
`from pybit.unified_trading import WebSocket
from time import sleep
ws = WebSocket(
testnet=True,
channel_type="linear",
)
def handle_message(message):
print(message)
ws.orderbook_stream(
depth=50,
symbol="BTCUSDT",
callback=handle_message
)
while True:
sleep(1)`
websocket._exceptions.WebSocketTimeoutException: WebSocket Unified V5 (Auth) (wss://stream.bybit.com/v5/private) connection failed. Too many connection attempts. pybit will no longer try to reconnect.
This error is only on vm win 2019 server. Сode good works on home PS. REST api works well exactly the same. A more detailed study shows error:
[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate.
trying
python -m pip install --trusted-host pypi.python.org --trusted-host files.pythonhosted.org --trusted-host pypi.org --upgrade certifi / pycryptodome / cryptography / requests / pybit and anather sh**, install OpenSSL, IIS (for what?).
I read the entire thread on this problem, tried a lot of things, but still couldn't find a solution. What certificate is missing and where? What is missing from vm win 2019 server? It could be a problem with bybit on server? I have seen many requests with this problem and not 1 solution!