smlxl / evm.codes

Source for evm.codes an Ethereum Virtual Machine Opcodes Interactive Reference
https://evm.codes/
MIT License
727 stars 135 forks source link

Contract viewer [old - ignore] #286

Closed hananbeer closed 7 months ago

hananbeer commented 10 months ago

This is my first commit for code review.

The goal is to add a Contract Viewer tab with better functionalities than etherscan, ideally independent of etherscan and open source.

See demo video here: https://x.com/high_byte/status/1743294802022609172?s=20

Things I've added:

vercel[bot] commented 10 months ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
evm-codes ✅ Ready (Inspect) Visit Preview 💬 Add feedback Feb 2, 2024 8:54pm
vercel[bot] commented 9 months ago

@hananbeer is attempting to deploy a commit to the smlXL Team on Vercel.

A member of the Team first needs to authorize it.

hananbeer commented 9 months ago

I see you have added code for handling the various Etherscan response formats (nice!) in util/EtherscanParser.ts, but I still have issues viewing contracts that are not in the single source file format

example of contracts that fails to be loaded:

  • 0x000000000022d473030f116ddee9f6b43ac78ba3 (standard solc json response)
  • 0xfd1539ee9ccad1ab5d9b4877097cfd8221815b47 (multifile json response)

btw - I tried to debug this error myself, but when I try to run a preview (yarn install and then yarn dev) of this branch locally I get a error saying there are "5 Unhandled Runtime Error" (works fine on master). Do you see these errors also ?

thanks that's a good catch. some contracts have remappings and etherscan sources are pre-remapping, so I committed a fix to remap sources when looking for them.

charisra commented 7 months ago

Superseded by https://github.com/smlxl/evm.codes/pull/318