Closed gianalarcon closed 6 months ago
@gianalarcon if you're in devnet it takes time to refresh the balance, it's a blockchain thing If you're in sepolia that also takes time to refresh (it happened a lot using Argent)
Same challenge, Other finding, it shows balance of the contract is 4.05eth instead of 4.5eth
After exploring the code I found the bug here https://github.com/Quantum3-Labs/speedrunstark/blob/602082df2daabbf90449798bb8b6646e96c1f7c8/packages/nextjs/hooks/scaffold-stark/useScaffoldEthBalance.ts#L35
Issue Overview
During testing of challenge-1. After I deploy the contract the UI shows the correct balance of user account,it is 1000 eth
Then, I do a stake 0.5 operation(I clicked in stake0.5 button ) , so it should decrease the balance of the current user account by 0.5 eth
In the right top corner of this pic I expect to see 999.499 eth but UI shows 999.0499 eth On the same picture you can see I called fn
balanceOf
and it retrieves the balance from the blockchain, it shows 9994993......After that I call withdraw operation (click on withdraw button) and I expect to see 999.998 eth but UI shows 999.0998 eth
Proposed Solutions or Ideas
Fix on UI.