flashbots / flashbots/simple-blind-arbitrage

BigNumber.from overflow error

Open
#15 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
Solidity
Stars
385
Forks
98
PR merge metrics
No merged PRs in 30d

Description

Here is the complete error with the context.

Transaction trading on Uniswap v2 pool detected! Pool address: 0x28cee28a7c4b4022ac92685c07d2f33ab1a0e122
Pool contract created, getting tokens
Token0: 0x1f9840a85d5aF5bf1D1762F925BDADdC4201F984
Token1: 0xB4FBF271143F4FBf7B91A5ded31805e42b2208d6
Factory: 0x5C69bEe701ef814a2B6a3EDD4B1652CB9cc5aA6f
Pool is WETH pair
Pool is Uniswap v2
Checking alternative factor for pair
Alternate pair exists! Pair address: 0x6D2fAf643Fe564e0204f35e38d1a1b08D9620d14
Sending bundles to MEV-Share Node for tx: 0xb496066791af51c3bbbfa82c98b79b28a3bfb8c9c0b057968837126a73603198
Current block number: 9938656
Building bundles
/root/mad-arb/execute/node_modules/@ethersproject/logger/lib/index.js:238
var error = new Error(message);
^

Error: overflow [ See: https://links.ethers.org/v5-errors-NUMERIC_FAULT-overflow ] (fault="overflow", operation="BigNumber.from", value=1e+21, code=NUMERIC_FAULT, version=bignumber/5.7.0)
at Logger.makeError (/root/mad-arb/execute/node_modules/@ethersproject/logger/lib/index.js:238:21)
at Logger.throwError (/root/mad-arb/execute/node_modules/@ethersproject/logger/lib/index.js:247:20)
at throwFault (/root/mad-arb/execute/node_modules/@ethersproject/bignumber/lib/bignumber.js:303:19)
at BigNumber.from (/root/mad-arb/execute/node_modules/@ethersproject/bignumber/lib/bignumber.js:206:17)
at BundleExecutor.buildBundles (/root/mad-arb/execute/bundleExecutor.js:126:30)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async BundleExecutor.execute (/root/mad-arb/execute/bundleExecutor.js:28:60)
at async MevShareNode.onmessage (/root/mad-arb/execute/index.js:65:13) {
reason: 'overflow',
code: 'NUMERIC_FAULT',
fault: 'overflow',
operation: 'BigNumber.from',
value: 1e+21
}

Contributor guide

No contributing guide indexed for this repository

Research direction

Start at execute/bundleExecutor.js:126, where the stack trace shows BigNumber.from receiving the value 1e+21, and trace how that value enters BundleExecutor.buildBundles. Reproduce the reported bundle-building path and confirm that it completes without the overflow error for the transaction shown.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
blockchain
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.