Reputation: 65
Have a simple method in my solidity contract with just one method were I am testing to get a UniswapV3Pool
value for a token and just through testing the method on BinanceSmartChain-Testnet
the method always returns:
The method is just:
/// @notice
/// 📝 calculates USD token price from main UniswapV3Pool
function calculatePriceInStableCoinV2
(
address _adrUsdtPool
)
public view
returns
(
uint160
)
{
(uint160 sqrtPriceX96, , , , , , ) = IUniswapV3Pool(_adrUsdtPool).slot0();
return sqrtPriceX96;
}
I don't know, but I have tried it many times and the method just fails to execute, is this an issue with the .slot0()
method in the UniswapV3Pool
contract ?
Upvotes: 0
Views: 54