console.log support
- Dominant language
- Python
- Stars
- 5.5k
- Forks
- 1.7k
- Avg merge
- 3d 10h
- Merged PRs (30d)
- 2
Description
### What was wrong?
Currently some EVM backends, namely Foundry and Hardhat offer [console.log](https://book.getfoundry.sh/reference/forge-std/console-log) integration.
- console.log is what the name says, written in Solidity - it outputs specific emits that can be interpreted as a debug log
- as a special rule, console.log events regardless if the transaction reverts or not
- AFAIK console.log on Hardhat and Foundry are compatible, not sure if Ape/Vyper have equivalents
Currently web3.py does not support console.log, but this is **extremely** useful feature for developers who work with smart contract development.
### How can it be fixed?
- Figure out how console.log does it magic trick of emitting events despite the transaction fails
- Add a web3.py module to deal with console emitted output
- Add a middleware that can transform console.log output to Python logging
- Write a docs mini tutorial explaining how the feature is supposed to used by developers
Contributor guide
Assessment
This issue has not been assessed yet.