How to properly test my flashloan bot
How to properly test my flashloan bot
Loading saved threads...
Rishabh Raghwendra · External communityPost link
External question — Ethereum Stack Exchange
Author: Rishabh Raghwendra
Original post: https://ethereum.stackexchange.com/questions/155296
License: CC BY-SA 4.0 — https://creativecommons.org/licenses/by-sa/4.0/
Adaptation: HTML converted to plain text; contact email addresses removed.
I am building a simple flashloan bot as shown below:
Flashloan from Aave -> lend it on Lending protocol A -> Borrow tokens from protocol A -> Lend borrowed to protocol B -> Borrow from protocol B to payback flashloan.
I want to know how can I test the bot in the max possible way. I know testing on a mainnet fork will be a good idea but is there any other testing methods too to test my bot that it will be profitable?
I researched about it on internet and even asked on Ethereum discord channel they only suggested mainnet forking nothing else.
Thanks in advance
Quote
Report
Foxxxey · External communityPost link
External answer — Ethereum Stack Exchange
Author: Foxxxey
Original post: https://ethereum.stackexchange.com/a/155300
License: CC BY-SA 4.0 — https://creativecommons.org/licenses/by-sa/4.0/
Adaptation: HTML converted to plain text; contact email addresses removed.
Flashloan from Aave -> lend it on Lending protocol A -> Borrow tokens from protocol A -> Lend borrowed to protocol B -> Borrow from protocol B to payback flashloan.
There's absolutely no way this works, lending protocols allow you to borrow only up to a certain percentage of your collateral, you wouldnt be able to fully repay the loan with the money borrowed from B.
they only suggested mainnet forking nothing else.
Yeah that's about it, mainnet forking allows you to get the current mainnet state, which is where your bot is gonna operate when it's live, so there's really no better environment to test
Quote
Report
Post Reply
Quoted from Forex.com.bd-Editorial External answer — Ethereum Stack Exchange Author: Foxxxey Source score (net votes, not local likes): 0 Original post: https://ethereum.stackexchange.com/a/155300 License: CC BY-SA 4.0 — https://creativecommons.org/licenses/by-sa/4.0/ Adaptation: HTML converted to plain text; contact email addresses removed. Flashloan from Aave -> lend it on Lending protocol A -> Borrow tokens from protocol A -> Lend borrowed to protocol B -> Borrow from protocol B to payback flashloan. There's absolutely no way this works, lending protocols allow you to borrow only up to a certain percentage of your collateral, you wouldnt be able to fully repay the loan with the money borrowed from B. they only suggested mainnet forking nothing else. Yeah that's about it, mainnet forking allows you to get the current mainnet state, which is where your bot is gonna operate when it's live, so there's really no better environment to test
Checking account access…