As per the current scenario, web3.py doesn't handle this very well, this due to differnt clients handle RPC response in differnt ways (see this issue). However, this is being worked upon very actively (see this issue).
There are few workarounds to accomplish this:
use eth-brownie, TransactionReceipt.revert_msg will give the verbose message for revert and ...
Perhaps what is needed is available in the API PRO plan:
"Get Token Info by ContractAddress" from https://etherscan.io/apis#APIpro
"tokenName": "Token Name",
It all came down to a virtualenv mess. For some reason it was using a globally installed web3 version (5.0.0) instead of the documented one that I was following the quickstart for (latest).
Nuking the virtualenv and starting from scratch with the new version worked for me :)
Had the same problem. Apparently we installed an older version of Web3 that used to have the method getBlock, now deprecated in favor of the get_block method.
However I don't know how to upgrade to the latest version, tried using pip install Web3 --upgrade but nothing changes.
My guesses are that it's either:
A limit of tx per address set by Infura, or
A limit of tx per API user set by Infura, or
A limit of tx per address set by miners (there is an option in Geth to set the max number of tx per address).