heya, trying here maybe i'll get some help :S (it's related to balancer but i'm not getting any response from them).
I'm trying to make a swap via balancer and it's failing and I have no clue into why
This is what i'm trying to do:
(swaps ,myBalamountOut) = BalancerProxy.viewSplitExactIn(tokenIn, tokenOut, amount, 10);
//TIERC20TokenIn.approve(address(BalancerProxy), amount);
//balancerPayable.transfer(amount);
_wrapEth(amount);
WETH.approve(address(BalancerProxy), amount);
//totalAmountOut = BalancerProxy.batchSwapExactIn{value: amount}(swaps, ERC20TokenIn, ERC20TokenOut, amount, myBalamountOut);
totalAmountOut = BalancerProxy.smartSwapExactIn(TIERC20TokenIn, TIERC20TokenOut, amount, myBalamountOut, 10);
I'm trying many things but none worked :-(
the call just fail with " Warning! Error encountered during contract execution [Bad instruction] "
Jan 16, 2021, 9:55 PM
*sorry for the long message
I know for a fact the issue is with BalancerProxy.smartSwapExactIn(TIERC20TokenIn, TIERC20TokenOut, amount, myBalamountOut, 10);
because when I comment it out everything works. I just can't understand what's the problem. Anything I can do to debug this or get a more indicative error somehow?
because when I comment it out everything works. I just can't understand what's the problem. Anything I can do to debug this or get a more indicative error somehow?
Anyone? 🙄
Jan 17, 2021, 8:04 AM