Quick syncronous and asynchronous examples of the middleware pattern introduced in v7 of web3.py.
To run the examples:
- install deps:
pip install web3==v7.0.0b2 python-dotenv - add your RPC URL to the
.envfile - run either
python sync.pyorpython async.py
If you want to skip all that, sample console output is included at the bottom of each file.