Providing an instance of AsyncWeb3 to async event builder
AsyncEventFilterBuilder.deploy(AsyncWeb3)
raises ValueError: Invalid web3 argument: got: <web3.main.AsyncWeb3 object at ...
It comes from _utils.events:L450, where there is a check if not isinstance(async_w3, web3.Web3):
. Shouldn't it check for web3.AsyncWeb3 instead?
Providing non-async instance of Web3
leads to other coroutine related issues. Changing the check to its negation if isinstance(async_w3, web3.Web3):
delivers expected behaviour.
The bug has been reported and solved in v6.3.0 https://github.com/ethereum/web3.py/issues/2931