pancakeswap / pancake-frontend

:pancakes: Pancake main features (farms, pools, IFO, lottery, profiles)
https://pancakeswap.finance
GNU General Public License v3.0
2.69k stars 3.54k forks source link

[BUG] Incorrect Liquidity Calculation #10778

Open gades opened 1 month ago

gades commented 1 month ago

Is there an existing issue for this?

Product

Other

Current Behavior

The liquidity volume is being calculated incorrectly. The account holds 110.4 ZEC with an exchange rate of $26.011 per ZEC. However, instead of showing the expected value of $110.4, the system displays an incorrect value of $16,768.26.

https://pancakeswap.finance/liquidity/1318667?chain=bsc&persistChain=1

Expected Behavior

The liquidity volume is being calculated incorrectly. The account holds 110.4 ZEC, with an exchange rate of $26.011. It is expected to display $2871.6144, but in fact, it shows $16,768.26.

https://pancakeswap.finance/liquidity/1318667?chain=bsc&persistChain=1

Steps To Reproduce

  1. Please create LP ZEC/USDT 1%
  2. Open LP and check

https://pancakeswap.finance/liquidity/1318667?chain=bsc&persistChain=1

Environment

- Device: Mac
- OS: v15 
- Browser: Chrome Version 129.0.6668.90 (Official Build) (arm64)
- Wallet: Metamask

Anything else?

This issue only with ZEC 0x1Ba42e5193dfA8B03D15dd1B86a3113bbBEF8Eeb

gades commented 2 weeks ago

API - https://wallet-api.pancakeswap.com/v1/prices/list/56%3A0x1ba42e5193dfa8b03d15dd1b86a3113bbbef8eeb Doesn't work correctly it't return {"56:0x1ba42e5193dfa8b03d15dd1b86a3113bbbef8eeb":70921408984.36331} instead of real price