I have one question regarding a code I found online. I'm looking for ways to overcome the rebase transfer-on-fee issues with uniswap v3. While exploring options of contracts like Volt, I noticed that they have a different way of opening trade on uniswap. Can anyone explain how this works in the control panel of remix?
Feb 10, 2023, 2:26 AM
this is the part I need help with
this is not generating a pair
Feb 10, 2023, 2:36 AM
Is there already one created? Is there any error message?
Feb 10, 2023, 2:40 AM
yes, its deployed, contract funded on testnet, just says transaction reversed when I try to create a pair.
should I use the uniswap router interface to add liquidity first? I'm a little bit confused with this type of contract
interface IUniswapV2Router01 {
function factory() external pure returns (address);
function WETH() external pure returns (address);
function addLiquidity(
address tokenA,
address tokenB,
uint256 amountADesired,
uint256 amountBDesired,
uint256 amountAMin,
uint256 amountBMin,
address to,
uint256 deadline
)
external
returns (
uint256 amountA,
uint256 amountB,
uint256 liquidity
);
function addLiquidityETH(
address token,
uint256 amountTokenDesired,
uint256 amountTokenMin,
uint256 amountETHMin,
address to,
uint256 deadline
)
external
payable
returns (
uint256 amountToken,
uint256 amountETH,
uint256 liquidity
);
function factory() external pure returns (address);
function WETH() external pure returns (address);
function addLiquidity(
address tokenA,
address tokenB,
uint256 amountADesired,
uint256 amountBDesired,
uint256 amountAMin,
uint256 amountBMin,
address to,
uint256 deadline
)
external
returns (
uint256 amountA,
uint256 amountB,
uint256 liquidity
);
function addLiquidityETH(
address token,
uint256 amountTokenDesired,
uint256 amountTokenMin,
uint256 amountETHMin,
address to,
uint256 deadline
)
external
payable
returns (
uint256 amountToken,
uint256 amountETH,
uint256 liquidity
);
Feb 10, 2023, 4:09 AM
these won't work for v3
and tokens with fees are not supported ok v3
you should simulate a transfer until it get blocked
but you can''t be sure 100% that it revert for a maxTx or a maxWallet
but you can''t be sure 100% that it revert for a maxTx or a maxWallet
so it is just an possible cause
Feb 10, 2023, 8:53 AM
Thanks
Feb 10, 2023, 8:55 AM