Skip to content
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

Adjust Simple Auction Example to Use Anvil Fork of Arbitrum Sepolia w/ Decrypter Pre-Deployed #3

Open
3 tasks
hashedtitan opened this issue Oct 31, 2024 · 1 comment

Comments

@hashedtitan
Copy link
Contributor

hashedtitan commented Oct 31, 2024

Scope

Setup the Simple Auction Example, and maybe others, to use an anvil fork of arbitrum sepolia testnet so we can simulate multiple bidders and have the 'students' come in and clone the repo and use a brand new wallet with no sepolia eth. The key here is that they don't need to get a bunch of sepETH to be able to run the tutorials.

TODOs:

Below are rough implementation steps to take where edits could be made to the bash test file, and additions made to the appropriate README.

  • Forking Arbitrum Sepolia with Anvil (anvil --fork-url https://sepolia-rollup.arbitrum.io/rpc)
  • Testing with Forked State in a Bash Script: Update the bash test script file RPC_URL var
# Define the Anvil RPC URL pointing to the Arbitrum Sepolia fork
RPC_URL="http://127.0.0.1:8545"
  • Testing Account Balance Management with Forked Anvil - essentially manipulate test environment balances of wallets using cast
# Adjust account balances to match your testing needs
cast rpc anvil_setBalance <account_address> 0xDE0B6B3A7640000 --rpc-url $RPC_URL  # Set to 1 ETH (in wei) 
@hashedtitan
Copy link
Contributor Author

hashedtitan commented Oct 31, 2024

  • Rough bash test file test.sh written, but is reverting with error as seen in screenshot below:
    image
  • It has to do with the inputs to decrypter address on the network, so this brings up a good opportunity to outline the key details of interacting with this contract. After discussion with @SetarehGhorshi, we will bring this up with foundry team.
  • @SetarehGhorshi troubleshot it further, and found the error to be the anvil server returned an error response where it seems like that anvil does not support the code:

error code -32603: EVM error OpcodeNotFound.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant