foundry
foundry copied to clipboard
meta(compilers): Vyper support
Component
Forge
Describe the feature you would like
Tracking issue for Vyper support improvements. For now just a list of things to consider.
- Standard library. First
Vm.vydraft is in https://github.com/foundry-rs/forge-std/pull/567, need to figure out a way to distribute - Better debugger support. Due to https://github.com/foundry-rs/foundry/issues/2704 we have conflicts of
source_ids between Vyper and Solc. Need to keep track of them separately. - Verification etherscan #10702 and blockscout supports automated Vyper verifcation for now
- https://github.com/foundry-rs/foundry/issues/7612.
vm.deployCodewould be very useful to allow deploying arbitrary contracts from Vyper tests and making them much more powerful. Need to figure out a clean way to execute EVM frames from insideCheatcodes. - Version manager? UX with Vyper is a bit less smooth then with solc because we require users to have Vyper pre-installed. There is a version manager in https://github.com/crypdoughdoteth/vyper-rs, however it initializes and uses Python venv which is a bit different to how svm-rs works.
- https://github.com/foundry-rs/foundry/issues/5411 Currently coverage relies on Solidity AST. We can either analyze Vyper AST separately or only rely on source maps to display line coverage.
- Vyper templates: https://github.com/foundry-rs/foundry/pull/9930
Additional context
No response
fyi etherscan seems to support multifile vyper verification as well through its api (e.g. https://etherscan.io/address/0x10b97ce0b66a2e18a5b2ef78090d7970e6affe52#code)