Open 1163849662 opened 1 year ago
import logging import time from binance.lib.utils import config_logging from binance.websocket.spot.websocket_api import SpotWebsocketAPIClient
config_logging(logging, logging.DEBUG)
def onclose(): logging.info("Do custom stuff when connection is closed")
sample code,error in print(1/0) def messagehandler(, message): logging.info(message) print(1/0)
my_client = SpotWebsocketAPIClient(on_message=message_handler, on_close=on_close)
my_client.aggregate_trades(symbol="BNBBUSD", limit=1, fromId=0)
time.sleep(2)
logging.info("closing ws connection") my_client.stop()
@1163849662 Are you still experiencing this error with the latest version? I tried to replicate it but couldn't.