You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
filter=state.interface.get_order_filter(symbol)
increment=filter["market_order"]["base_increment"]
decimals=abs(Decimal(str(increment)).as_tuple().exponent() # I forget from where; but this is taken from the Blankly source
Hmm - I think you're right there should be a significantly easier way to access the decimal count especially for people checking the order filter. I'm also looking into the base decimal differences between our response what's shown at exchangeInfo. We've never had an issue with our filters being inaccurate but maybe these lower price symbols have a more complex order filter to deal with.
XRP-USDT pair on Binance' LOT_SIZE from
https://api.binance.com/api/v1/exchangeInfo
:Calculating amount of decimals like this:
Decimals is 1 but should be 0 (?)
When creating a market buy order Binance returns LOT_SIZE error.
My current solution is wrapping the market buy order in two try/except statements like this:
Is there a more proper/elegant way of doing this?
The text was updated successfully, but these errors were encountered: