-
Notifications
You must be signed in to change notification settings - Fork 0
[WIP] Implement forking support with lazy loading backend #13
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
Conversation
|
I pulled in the latest changes from lazy-loading-backend branch on top of the forking-support and tried this out. Don't know if I messed something up while fixing conflicts, so would he worth doing this merge yourself and testing again |
crates/anvil-polkadot/src/substrate_node/lazy_loading/rpc_client.rs
Outdated
Show resolved
Hide resolved
Out of curiosity: did you try this flow without the lazy-loading changes, just want to confirm I don't have any special setup on my side. Regarding the merge itself — I’m currently heads-down on the other PR to get that one landed ASAP. Once that’s done I’ll jump straight onto this one |
You mean without pulling in the latest changes, but only with the state of this branch? |
|
And let's also test with a smart contract. A simple one which stores multiple items in the state to see if the child trie state is also migrated properly |
4a0ef1c to
cd91375
Compare
8a695d0 to
c863b3b
Compare
|
Closed in favor of paritytech#426 |
Description
This PR implements forking functionality for anvil-polkadot, allowing users to fork from a remote Substrate/Polkadot node and run local tests against live network state.
Adds the ability to fork from a running anvil-polkadot node (or compatible Substrate node) using the
--fork-urlflag. The implementation uses a lazy-loading approach to fetch state from the remote node on-demand, caching values locally for performanceTesting
After compiling the entire project using
cargo build --release1. Start base node
2. Modify state on base node
3. Verify modified balance
4. Start fork node (inherits modified state)
5. Verify fork inherited state
6. Make changes on fork (doesn't affect base)
7. Verify isolation
TODO