JKorf / Binance.Net

A C# .netstandard client library for the Binance REST and Websocket Spot and Futures API focusing on clear usage and models
https://jkorf.github.io/Binance.Net/
MIT License
1.05k stars 429 forks source link

SubscribeToOrderBookUpdatesAsync not working #1152

Closed yetiwolf closed 1 year ago

yetiwolf commented 2 years ago

SubscribeToOrderBookUpdatesAsync Doesn't seem to be working.

It returns the error: "No response on subscription request received"

yetiwolf commented 2 years ago

Dim myAction As New Action(Of DataEvent(Of Interfaces.IBinanceEventOrderBook))(AddressOf binance_websocket_orderbook_diff_handler)

Dim success = Await socketClient.SpotStreams.SubscribeToOrderBookUpdatesAsync(symbols, 1000, myAction)

yetiwolf commented 2 years ago

Everything else seems to work except for this.

JKorf commented 2 years ago

This might be caused by sending too much symbols in a single call. There is a limit on the max message size on the server side, which is around 4kb. If you're trying to subscribe too much symbols in a single call you might hit this limit and no answer will come

yetiwolf commented 2 years ago

Thanks for the reply. I'm only subscribing to 1 coin and getting this.

JKorf commented 2 years ago

Well that's interesting.. I can't reproduce this unfortunately. Can you look at the trace logging? Set LogLevel = LogLevel.Trace in the options when creating the socket client and look for the debug looking

yetiwolf commented 2 years ago

I changed the order of my other subscriptions and it started working now. Thank you for your assistance.