Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding new pairs error #63

Open
Sshimaninja opened this issue Feb 28, 2022 · 2 comments
Open

Adding new pairs error #63

Sshimaninja opened this issue Feb 28, 2022 · 2 comments

Comments

@Sshimaninja
Copy link

Attempting to add new (common) pairs; UNI, LINK I add addresses.ts entries, directly queried from 1inch Polygon API:

UNI: { symbol:"UNI", name:"Uniswap", decimals:18, address:"0xb33eaad8d922b1083446dc23f610c2567fb5180f", logoURI: "https://tokens.1inch.io/0x1f9840a85d5af5bf1d1762f925bdaddc4201f984.png" }, LINK: { symbol:"LINK", name:"ChainLink Token", decimals:18, address:"0x53e0bca35ec356bd5dddfebbd1fc0fd03fabad39", logoURI: "https://tokens.1inch.io/0x514910771af9ca656af840dff83e8264ecf986ca.png", },
and add trading pairs to config.ts:

export const tradingTokens = [
  ERC20Token.DAI,
  ERC20Token.WETH,
  ERC20Token.USDC,
  ERC20Token.USDT,
  ERC20Token.WMATIC,
  ERC20Token.UNI,
  ERC20Token.LINK
];

Results in the following errors during testing:

yarn test results sample:

  ● Uniswap price check › POLYGON_UNISWAP_V3 › DAI -> LINK

    missing revert data in call exception (error={"reason":"processing response error","code":"SERVER_ERROR","body":"{\"jsonrpc\":\"2.0\",\"id\":50,\"error\":{\"code\":-32000,\"message\":\"execution reverted\"}}\n","error":{"code":-32000},"requestBody":"{\"method\":\"eth_call\",\"params\":[{\"to\":\"0xb27308f9f90d607463bb33ea1bebb41c27ce5ab6\",\"data\":\"0xf7729d430000000000000000000000008f3cf7ad23cd3cadbd9735aff958023239c6a06300000000000000000000000053e0bca35ec356bd5dddfebbd1fc0fd03fabad390000000000000000000000000000000000000000000000000000000000000bb80000000000000000000000000000000000000000000000000de0b6b3a76400000000000000000000000000000000000000000000000000000000000000000000\"},\"latest\"],\"id\":50,\"jsonrpc\":\"2.0\"}","requestMethod":"POST","url":"<MY ALCHEMY ADDRESS>"}, data="0x", code=CALL_EXCEPTION, version=providers/5.5.2)

      at Logger.Object.<anonymous>.Logger.makeError (node_modules/@ethersproject/logger/src.ts/index.ts:225:28)
      at Logger.Object.<anonymous>.Logger.throwError (node_modules/@ethersproject/logger/src.ts/index.ts:237:20)
      at checkError (node_modules/@ethersproject/providers/src.ts/json-rpc-provider.ts:34:16)
      at JsonRpcProvider.<anonymous> (node_modules/@ethersproject/providers/src.ts/json-rpc-provider.ts:562:20)
      at step (node_modules/@ethersproject/providers/lib/json-rpc-provider.js:48:23)
      at Object.throw (node_modules/@ethersproject/providers/lib/json-rpc-provider.js:29:53)
      at rejected (node_modules/@ethersproject/providers/lib/json-rpc-provider.js:21:65)

  ● Uniswap price check › POLYGON_UNISWAP_V3 › USDT -> LINK

    call revert exception (method="quoteExactInputSingle(address,address,uint24,uint256,uint160)", errorArgs=["Unexpected error"], errorName="Error", errorSignature="Error(string)", reason="Unexpected error", code=CALL_EXCEPTION, version=abi/5.5.0)

      at Logger.Object.<anonymous>.Logger.makeError (node_modules/@ethersproject/logger/src.ts/index.ts:225:28)
      at Logger.Object.<anonymous>.Logger.throwError (node_modules/@ethersproject/logger/src.ts/index.ts:237:20)
      at Interface.Object.<anonymous>.Interface.decodeFunctionResult (node_modules/@ethersproject/abi/src.ts/interface.ts:425:23)
      at Object.<anonymous> (node_modules/@ethersproject/contracts/src.ts/index.ts:392:44)
      at step (node_modules/@ethersproject/contracts/lib/index.js:48:23)
      at Object.next (node_modules/@ethersproject/contracts/lib/index.js:29:53)
      at fulfilled (node_modules/@ethersproject/contracts/lib/index.js:20:58)

  ● Uniswap price check › POLYGON_UNISWAP_V3 › USDT -> LINK

    call revert exception (method="quoteExactInputSingle(address,address,uint24,uint256,uint160)", errorArgs=["Unexpected error"], errorName="Error", errorSignature="Error(string)", reason="Unexpected error", code=CALL_EXCEPTION, version=abi/5.5.0)

      at Logger.Object.<anonymous>.Logger.makeError (node_modules/@ethersproject/logger/src.ts/index.ts:225:28)
      at Logger.Object.<anonymous>.Logger.throwError (node_modules/@ethersproject/logger/src.ts/index.ts:237:20)
      at Interface.Object.<anonymous>.Interface.decodeFunctionResult (node_modules/@ethersproject/abi/src.ts/interface.ts:425:23)
      at Object.<anonymous> (node_modules/@ethersproject/contracts/src.ts/index.ts:392:44)
      at step (node_modules/@ethersproject/contracts/lib/index.js:48:23)
      at Object.next (node_modules/@ethersproject/contracts/lib/index.js:29:53)
      at fulfilled (node_modules/@ethersproject/contracts/lib/index.js:20:58)

Test Suites: 1 failed, 3 passed, 4 total
Tests:       18 failed, 133 passed, 151 total
Snapshots:   0 total
Time:        109.821 s
Ran all test suites.

All exchanges have the same error for UNI and LINK pairs.

@polyfooly
Copy link

I've got "-32000 execution reverted" error on Alchemy when gas price value was too low. Even if it was gasless contract call. Try to increase gas price value from 30 to some other value in src/config.ts

@Sshimaninja
Copy link
Author

Gas is up at 120. :/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants