Skip to content

Instantly share code, notes, and snippets.

@MagRelo
Created April 13, 2022 14:59
Show Gist options
  • Save MagRelo/81e36196430a6f45a8a2996d76b1a7ee to your computer and use it in GitHub Desktop.
Save MagRelo/81e36196430a6f45a8a2996d76b1a7ee to your computer and use it in GitHub Desktop.
mattlovan@Matts-MacBook-Pro rara-protocol % node ./subgraph/scripts/functions/3_spendReaction.js
spending reactions...
<ref *1> Error: cannot estimate gas; transaction may fail or may require manual gas limit (error={"reason":"cannot estimate gas; transaction may fail or may require manual gas limit","code":"UNPREDICTABLE_GAS_LIMIT","error":{"reason":"processing response error","code":"SERVER_ERROR","body":"{\"jsonrpc\":\"2.0\",\"id\":49,\"error\":{\"code\":-32000,\"message\":\"execution reverted\"}}","error":{"code":-32000},"requestBody":"{\"method\":\"eth_estimateGas\",\"params\":[{\"type\":\"0x2\",\"maxFeePerGas\":\"0x9502f930\",\"maxPriorityFeePerGas\":\"0x9502f900\",\"from\":\"0x68c5119c92296a290140096b4b60205b62c6dd78\",\"to\":\"0x161354414b7ac43ded87bc1176146e9326ffc671\",\"data\":\"0x755443ce000000000000000000000000000000000000000000000000000000000001388100000000000000000000000007081c92ee04bd9ba46f18ed61e7c593f8d90951000000000000000000000000000000000000000000000000000000000000002c341c6ffe3493b3337dcde53c58aec123f85799a68d0dc4d2e46424f90bc3db0d000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000d34d4fb9b34b8d0281e4a24b4653794b266a9000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000002e516d563238387a4874744a4a7750425a4157334c393232644279705771756b464e577a656b543663687857344375000000000000000000000000000000000000\"}],\"id\":49,\"jsonrpc\":\"2.0\"}","requestMethod":"POST","url":"https://rpc-mumbai.maticvigil.com"},"method":"estimateGas","transaction":{"from":"0x68c5119c92296a290140096b4b60205b62c6dD78","maxPriorityFeePerGas":{"type":"BigNumber","hex":"0x9502f900"},"maxFeePerGas":{"type":"BigNumber","hex":"0x9502f930"},"to":"0x161354414b7aC43deD87Bc1176146e9326ffc671","data":"0x755443ce000000000000000000000000000000000000000000000000000000000001388100000000000000000000000007081c92ee04bd9ba46f18ed61e7c593f8d90951000000000000000000000000000000000000000000000000000000000000002c341c6ffe3493b3337dcde53c58aec123f85799a68d0dc4d2e46424f90bc3db0d000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000d34d4fb9b34b8d0281e4a24b4653794b266a9000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000002e516d563238387a4874744a4a7750425a4157334c393232644279705771756b464e577a656b543663687857344375000000000000000000000000000000000000","type":2,"accessList":null}}, tx={"data":"0x755443ce000000000000000000000000000000000000000000000000000000000001388100000000000000000000000007081c92ee04bd9ba46f18ed61e7c593f8d90951000000000000000000000000000000000000000000000000000000000000002c341c6ffe3493b3337dcde53c58aec123f85799a68d0dc4d2e46424f90bc3db0d000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000d34d4fb9b34b8d0281e4a24b4653794b266a9000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000002e516d563238387a4874744a4a7750425a4157334c393232644279705771756b464e577a656b543663687857344375000000000000000000000000000000000000","to":{},"from":"0x68c5119c92296a290140096b4b60205b62c6dD78","type":2,"maxFeePerGas":{"type":"BigNumber","hex":"0x9502f930"},"maxPriorityFeePerGas":{"type":"BigNumber","hex":"0x9502f900"},"nonce":{},"gasLimit":{},"chainId":{}}, code=UNPREDICTABLE_GAS_LIMIT, version=abstract-signer/5.5.0)
at Logger.makeError (/Users/mattlovan/Projects/rara/rara-protocol/node_modules/@ethersproject/logger/lib/index.js:199:21)
at Logger.throwError (/Users/mattlovan/Projects/rara/rara-protocol/node_modules/@ethersproject/logger/lib/index.js:208:20)
at /Users/mattlovan/Projects/rara/rara-protocol/node_modules/@ethersproject/abstract-signer/lib/index.js:365:47
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async Promise.all (index 7) {
reason: 'cannot estimate gas; transaction may fail or may require manual gas limit',
code: 'UNPREDICTABLE_GAS_LIMIT',
error: Error: cannot estimate gas; transaction may fail or may require manual gas limit (error={"reason":"processing response error","code":"SERVER_ERROR","body":"{\"jsonrpc\":\"2.0\",\"id\":49,\"error\":{\"code\":-32000,\"message\":\"execution reverted\"}}","error":{"code":-32000},"requestBody":"{\"method\":\"eth_estimateGas\",\"params\":[{\"type\":\"0x2\",\"maxFeePerGas\":\"0x9502f930\",\"maxPriorityFeePerGas\":\"0x9502f900\",\"from\":\"0x68c5119c92296a290140096b4b60205b62c6dd78\",\"to\":\"0x161354414b7ac43ded87bc1176146e9326ffc671\",\"data\":\"0x755443ce000000000000000000000000000000000000000000000000000000000001388100000000000000000000000007081c92ee04bd9ba46f18ed61e7c593f8d90951000000000000000000000000000000000000000000000000000000000000002c341c6ffe3493b3337dcde53c58aec123f85799a68d0dc4d2e46424f90bc3db0d000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000d34d4fb9b34b8d0281e4a24b4653794b266a9000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000002e516d563238387a4874744a4a7750425a4157334c393232644279705771756b464e577a656b543663687857344375000000000000000000000000000000000000\"}],\"id\":49,\"jsonrpc\":\"2.0\"}","requestMethod":"POST","url":"https://rpc-mumbai.maticvigil.com"}, method="estimateGas", transaction={"from":"0x68c5119c92296a290140096b4b60205b62c6dD78","maxPriorityFeePerGas":{"type":"BigNumber","hex":"0x9502f900"},"maxFeePerGas":{"type":"BigNumber","hex":"0x9502f930"},"to":"0x161354414b7aC43deD87Bc1176146e9326ffc671","data":"0x755443ce000000000000000000000000000000000000000000000000000000000001388100000000000000000000000007081c92ee04bd9ba46f18ed61e7c593f8d90951000000000000000000000000000000000000000000000000000000000000002c341c6ffe3493b3337dcde53c58aec123f85799a68d0dc4d2e46424f90bc3db0d000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000d34d4fb9b34b8d0281e4a24b4653794b266a9000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000002e516d563238387a4874744a4a7750425a4157334c393232644279705771756b464e577a656b543663687857344375000000000000000000000000000000000000","type":2,"accessList":null}, code=UNPREDICTABLE_GAS_LIMIT, version=providers/5.5.3)
at Logger.makeError (/Users/mattlovan/Projects/rara/rara-protocol/node_modules/@ethersproject/logger/lib/index.js:199:21)
at Logger.throwError (/Users/mattlovan/Projects/rara/rara-protocol/node_modules/@ethersproject/logger/lib/index.js:208:20)
at checkError (/Users/mattlovan/Projects/rara/rara-protocol/node_modules/@ethersproject/providers/lib/json-rpc-provider.js:126:16)
at JsonRpcProvider.<anonymous> (/Users/mattlovan/Projects/rara/rara-protocol/node_modules/@ethersproject/providers/lib/json-rpc-provider.js:659:47)
at step (/Users/mattlovan/Projects/rara/rara-protocol/node_modules/@ethersproject/providers/lib/json-rpc-provider.js:48:23)
at Object.throw (/Users/mattlovan/Projects/rara/rara-protocol/node_modules/@ethersproject/providers/lib/json-rpc-provider.js:29:53)
at rejected (/Users/mattlovan/Projects/rara/rara-protocol/node_modules/@ethersproject/providers/lib/json-rpc-provider.js:21:65)
at processTicksAndRejections (node:internal/process/task_queues:96:5) {
reason: 'cannot estimate gas; transaction may fail or may require manual gas limit',
code: 'UNPREDICTABLE_GAS_LIMIT',
error: Error: processing response error (body="{\"jsonrpc\":\"2.0\",\"id\":49,\"error\":{\"code\":-32000,\"message\":\"execution reverted\"}}", error={"code":-32000}, requestBody="{\"method\":\"eth_estimateGas\",\"params\":[{\"type\":\"0x2\",\"maxFeePerGas\":\"0x9502f930\",\"maxPriorityFeePerGas\":\"0x9502f900\",\"from\":\"0x68c5119c92296a290140096b4b60205b62c6dd78\",\"to\":\"0x161354414b7ac43ded87bc1176146e9326ffc671\",\"data\":\"0x755443ce000000000000000000000000000000000000000000000000000000000001388100000000000000000000000007081c92ee04bd9ba46f18ed61e7c593f8d90951000000000000000000000000000000000000000000000000000000000000002c341c6ffe3493b3337dcde53c58aec123f85799a68d0dc4d2e46424f90bc3db0d000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000d34d4fb9b34b8d0281e4a24b4653794b266a9000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000002e516d563238387a4874744a4a7750425a4157334c393232644279705771756b464e577a656b543663687857344375000000000000000000000000000000000000\"}],\"id\":49,\"jsonrpc\":\"2.0\"}", requestMethod="POST", url="https://rpc-mumbai.maticvigil.com", code=SERVER_ERROR, version=web/5.5.1)
at Logger.makeError (/Users/mattlovan/Projects/rara/rara-protocol/node_modules/@ethersproject/logger/lib/index.js:199:21)
at Logger.throwError (/Users/mattlovan/Projects/rara/rara-protocol/node_modules/@ethersproject/logger/lib/index.js:208:20)
at /Users/mattlovan/Projects/rara/rara-protocol/node_modules/@ethersproject/web/lib/index.js:301:32
at step (/Users/mattlovan/Projects/rara/rara-protocol/node_modules/@ethersproject/web/lib/index.js:33:23)
at Object.next (/Users/mattlovan/Projects/rara/rara-protocol/node_modules/@ethersproject/web/lib/index.js:14:53)
at fulfilled (/Users/mattlovan/Projects/rara/rara-protocol/node_modules/@ethersproject/web/lib/index.js:5:58)
at processTicksAndRejections (node:internal/process/task_queues:96:5) {
reason: 'processing response error',
code: 'SERVER_ERROR',
body: '{"jsonrpc":"2.0","id":49,"error":{"code":-32000,"message":"execution reverted"}}',
error: [Error],
requestBody: '{"method":"eth_estimateGas","params":[{"type":"0x2","maxFeePerGas":"0x9502f930","maxPriorityFeePerGas":"0x9502f900","from":"0x68c5119c92296a290140096b4b60205b62c6dd78","to":"0x161354414b7ac43ded87bc1176146e9326ffc671","data":"0x755443ce000000000000000000000000000000000000000000000000000000000001388100000000000000000000000007081c92ee04bd9ba46f18ed61e7c593f8d90951000000000000000000000000000000000000000000000000000000000000002c341c6ffe3493b3337dcde53c58aec123f85799a68d0dc4d2e46424f90bc3db0d000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000d34d4fb9b34b8d0281e4a24b4653794b266a9000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000002e516d563238387a4874744a4a7750425a4157334c393232644279705771756b464e577a656b543663687857344375000000000000000000000000000000000000"}],"id":49,"jsonrpc":"2.0"}',
requestMethod: 'POST',
url: 'https://rpc-mumbai.maticvigil.com'
},
method: 'estimateGas',
transaction: {
from: '0x68c5119c92296a290140096b4b60205b62c6dD78',
maxPriorityFeePerGas: [BigNumber],
maxFeePerGas: [BigNumber],
to: '0x161354414b7aC43deD87Bc1176146e9326ffc671',
data: '0x755443ce000000000000000000000000000000000000000000000000000000000001388100000000000000000000000007081c92ee04bd9ba46f18ed61e7c593f8d90951000000000000000000000000000000000000000000000000000000000000002c341c6ffe3493b3337dcde53c58aec123f85799a68d0dc4d2e46424f90bc3db0d000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000d34d4fb9b34b8d0281e4a24b4653794b266a9000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000002e516d563238387a4874744a4a7750425a4157334c393232644279705771756b464e577a656b543663687857344375000000000000000000000000000000000000',
type: 2,
accessList: null
}
},
tx: {
data: '0x755443ce000000000000000000000000000000000000000000000000000000000001388100000000000000000000000007081c92ee04bd9ba46f18ed61e7c593f8d90951000000000000000000000000000000000000000000000000000000000000002c341c6ffe3493b3337dcde53c58aec123f85799a68d0dc4d2e46424f90bc3db0d000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000d34d4fb9b34b8d0281e4a24b4653794b266a9000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000002e516d563238387a4874744a4a7750425a4157334c393232644279705771756b464e577a656b543663687857344375000000000000000000000000000000000000',
to: Promise { '0x161354414b7aC43deD87Bc1176146e9326ffc671' },
from: '0x68c5119c92296a290140096b4b60205b62c6dD78',
type: 2,
maxFeePerGas: BigNumber { _hex: '0x9502f930', _isBigNumber: true },
maxPriorityFeePerGas: BigNumber { _hex: '0x9502f900', _isBigNumber: true },
nonce: Promise { 103 },
gasLimit: Promise { <rejected> [Circular *1] },
chainId: Promise { 80001 }
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment