0

I'm trying to deploy UniswapV2Router02 to one of testnets https://github.com/Uniswap/v2-periphery/blob/master/contracts/UniswapV2Router02.sol

I continuously get ProviderError: max code size exceeded. I tried to set hardhat optimization to true like here with 200 runs but it's still not working ProviderError: max code size exceeded

2
  • You have to use a higher number for the runs.
    – Ismael
    Oct 12, 2023 at 17:30
  • 1
    The contract size was changed meanwhile. I needed to remove some unused functions from Router and then it worked. Dec 6, 2023 at 20:27

0

Browse other questions tagged or ask your own question.