Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CrossUnrealizedPnL is not Correct after upgrading to Version 10.0.0 - 27 Jul 2024 UsdFuturesApi.Account.GetBalancesAsync to V3 #1404

Open
dante1989 opened this issue Aug 12, 2024 · 6 comments

Comments

@dante1989
Copy link

i'm using Isolated Mode Margin

Dim ItemFuturesAccountBalance = Await clientBinance.UsdFuturesApi.Account.GetBalancesAsync
Dim BalanceUSD = Array.Find(ItemFuturesAccountBalance.Data.ToArray(), Function(m) m.Asset = "USDT")
In older version: the BalanceUSD.CrossUnrealizedPnl = 0 is correct because i'm using Isolated Mode Margin
After upgrading to Version 10.0.0 - 27 Jul 2024 UsdFuturesApi.Account.GetBalancesAsync to V3. BalanceUSD.CrossUnrealizedPnl <> 0 when i have a isolated position. It is not correct

@JKorf
Copy link
Owner

JKorf commented Aug 12, 2024

Hm that seems weird. Is it possible for you to share the response data of the request using OutputOriginalData in the client options?

@dante1989
Copy link
Author

dante1989 commented Aug 13, 2024

i'm using Isolated Mode Margin

MsgBox(ItemFuturesAccountBalance.OriginalData.ToString)

image

                        MsgBox(BalanceUSD.CrossUnrealizedPnl)

image

I think GetBalancesAsync V3 have problem, this problem from binance, V2 is better

@dante1989
Copy link
Author

We could integrate Both V2 and V3

@JKorf
Copy link
Owner

JKorf commented Aug 13, 2024

I've asked Binance about this, seems it's a bug:
image

I'd rather not implement multiple versions of the same functionality unless there is a good reason. I'm assuming they'll fix this on their end which should make the V3 endpoint the same as V2 right?

@dante1989
Copy link
Author

yeah, I also think it's not necessary to make multiple versions if binance fixes the error for us

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants
@JKorf @dante1989 and others