question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Uniswap V1 ABI "duplicate output parameter "out" in function removeLiquidity" error thrown

See original GitHub issue

When using ethers@v5 and loading the Uniswap V1 ABI I get “duplicate output parameter “out” in function removeLiquidity” error thrown.

ABI Culprit

{
    "name": "removeLiquidity",
    "outputs": [
      { "type": "uint256", "name": "out" },
      { "type": "uint256", "name": "out" }
    ],
    "inputs": [
      { "type": "uint256", "name": "amount" },
      { "type": "uint256", "name": "min_eth" },
      { "type": "uint256", "name": "min_tokens" },
      { "type": "uint256", "name": "deadline" }
    ],
    "constant": false,
    "payable": false,
    "type": "function",
    "gas": 116814
  },

Not sure if I should report this error here, because it seems like a Uniswap problem when Vyper compiles the ABI, but seeing as it’s unlikely to change, I thought it would be worth reporting because Uniswap is obviously super popular and people are going to use the generated ABI when V5 gets released.

Reference to the Vyper Smart Contract

https://github.com/Uniswap/uniswap-v1/blob/master/contracts/uniswap_exchange.vy#L83

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:7 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
ricmoocommented, May 14, 2020

Coolio. I’ll close this now then, but if you still have any problem, please re-open.

Thanks! 😃

1reaction
ricmoocommented, May 13, 2020

This has been added to 5.0.0-beta.187. Try it out and let me know if you still have any problems. 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Uniswap V1 Factory contract with ethers.js not working
The error message says out of gas , if you copied your ABI from Uniswap docs, some functions have a gas definition as...
Read more >
Common Errors - Uniswap Docs
This document covers a few error codes frequently encountered while building ... These functions succeed by adjusting the “amountOutMin” parameter to check ...
Read more >
Router | Address ... - Polygonscan
function removeLiquidity ( - function prepare( - function fulfill( - function ... operations that throw on failure (when the token * contract returns...
Read more >
Binance Contract Diff Checker - BscScan
Each holding of 100,000,000,000 KICH results in 1 ticket to the lottery. ... set the rest of the contract variables in the global...
Read more >
Balancer: Vault - Arbiscan.io
Finally, the large number of tasks carried out by the Vault means its bytecode is very large, close to exceeding * the contract...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found