0xnivek / joe-liquidator

Flash loan liquidation bot for traderjoe.xyz
35 stars 19 forks source link

Error performing liquidation #1

Open sfbcm opened 2 years ago

sfbcm commented 2 years ago

I'm running into an issue when attempting to run the bot with "yarn start". Please see below:

Mainnet contract address: 0x60ae94AF8C90a0DeBF0ad75BFA44E408cb81ED27

🔧 Bot starting up... 🔁 Bot will query the subgraph every 10 seconds to search for liquidatable accounts...

🔎 Searching for account to liquidate... 🤩 Found underwater account to liquidate! 🌊 Performing liquidation on borrower 0x364efe92840aa222866759dc4e4d25a58ec80775 with borrow position on jUSDT and supply position on jWBTC Error performing liquidation: <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","method":"estimateGas","transaction":{"from":"0x4547DdF5e28CF4aBEB59Be84FFacee0571C02FD2","maxPriorityFeePerGas":{"type":"BigNumber","hex":"0x9502f900"},"maxFeePerGas":{"type":"BigNumber","hex":"0x0b757d65ba"},"to":"0x60ae94AF8C90a0DeBF0ad75BFA44E408cb81ED27","data":"0xca5ce2ec000000000000000000000000364efe92840aa222866759dc4e4d25a58ec807750000000000000000000000008b650e26404ac6837539ca96812f0123601e44480000000000000000000000003fe38b7b610c0acd10296fef69d9b18eb7a9eb1f","type":2,"accessList":null}}, tx={"data":"0xca5ce2ec000000000000000000000000364efe92840aa222866759dc4e4d25a58ec807750000000000000000000000008b650e26404ac6837539ca96812f0123601e44480000000000000000000000003fe38b7b610c0acd10296fef69d9b18eb7a9eb1f","to":{},"from":"0x4547DdF5e28CF4aBEB59Be84FFacee0571C02FD2","type":2,"maxFeePerGas":{"type":"BigNumber","hex":"0x0b757d65ba"},"maxPriorityFeePerGas":{"type":"BigNumber","hex":"0x9502f900"},"nonce":{},"gasLimit":{},"chainId":{}}, code=UNPREDICTABLE_GAS_LIMIT, version=abstract-signer/5.5.0) 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 (method="estimateGas", transaction={"from":"0x4547DdF5e28CF4aBEB59Be84FFacee0571C02FD2","maxPriorityFeePerGas":{"type":"BigNumber","hex":"0x9502f900"},"maxFeePerGas":{"type":"BigNumber","hex":"0x0b757d65ba"},"to":"0x60ae94AF8C90a0DeBF0ad75BFA44E408cb81ED27","data":"0xca5ce2ec000000000000000000000000364efe92840aa222866759dc4e4d25a58ec807750000000000000000000000008b650e26404ac6837539ca96812f0123601e44480000000000000000000000003fe38b7b610c0acd10296fef69d9b18eb7a9eb1f","type":2,"accessList":null}, code=UNPREDICTABLE_GAS_LIMIT, version=providers/5.5.1) reason: 'cannot estimate gas; transaction may fail or may require manual gas limit', code: 'UNPREDICTABLE_GAS_LIMIT', method: 'estimateGas', transaction: { from: '0x4547DdF5e28CF4aBEB59Be84FFacee0571C02FD2', maxPriorityFeePerGas: [BigNumber], maxFeePerGas: [BigNumber], to: '0x60ae94AF8C90a0DeBF0ad75BFA44E408cb81ED27', data: '0xca5ce2ec000000000000000000000000364efe92840aa222866759dc4e4d25a58ec807750000000000000000000000008b650e26404ac6837539ca96812f0123601e44480000000000000000000000003fe38b7b610c0acd10296fef69d9b18eb7a9eb1f', type: 2, accessList: null } }, tx: { data: '0xca5ce2ec000000000000000000000000364efe92840aa222866759dc4e4d25a58ec807750000000000000000000000008b650e26404ac6837539ca96812f0123601e44480000000000000000000000003fe38b7b610c0acd10296fef69d9b18eb7a9eb1f', to: Promise { '0x60ae94AF8C90a0DeBF0ad75BFA44E408cb81ED27' }, from: '0x4547DdF5e28CF4aBEB59Be84FFacee0571C02FD2', type: 2, maxFeePerGas: BigNumber { _hex: '0x0b757d65ba', _isBigNumber: true }, maxPriorityFeePerGas: BigNumber { _hex: '0x9502f900', _isBigNumber: true }, nonce: Promise { 0 }, gasLimit: Promise { [Circular 1] }, chainId: Promise { 1 } } }

Any idea what could be causing the issue?

sameshitdifferentday commented 2 years ago

How did you compile your contract ?

ryantpozzi commented 2 years ago

Used yarn compile. I'm getting the same error.

nihat2065 commented 2 years ago

hi i have the same problem can you write how you solved it

mewmix commented 2 years ago

i use to run this with no issues on ubuntu WSL , now running ubuntu 22.04 baremetal im having this same issue - could be node version maybe?

Kru0489 commented 2 years ago

@sfbcm did you find a solution to the "cannot estimate gas; transaction may fail or may require manual gas limit" error? I'm having the same issue. Thanks

DEEPML1818 commented 1 year ago

HI guys did anyone found the issue i am having the same problem, thx in advance.

krazedegen commented 8 months ago

it displays errors but still makes transactions. its never profitable though. just sucks your avax out in transactions that cost .03 yet only return .0005-.005.