https://mainnet.infura.io/v3/key,
when I connect to the ETH main network with web3py, I use Web3.HTTPProvider to call the function web3.is_connected ().It returned True.
WSS://mainnet.infura.io/ws/v3/key
When I switched to Web3.WebsocketProvider, I called the function web3.is_connected () and returned False.
please help me
w3s = Web3(Web3.WebsocketProvider('wss://mainnet.infura.io/ws/v3/***********key*******',websocket_timeout=120))
for i in range(10):
time.sleep(5)
a = w3s.is_connected()
print(a)