pacrob on asyncify-contract
Resolve Typo in documentation. … Add sync chain_id to simple cac… Compile release notes and 23 more (compare)
kclowes on asyncify-contract
Remove un-needed chain_id (compare)
kclowes on asyncify-contract
Fix tests (compare)
kclowes on asyncify-contract
Add missing await in async buil… Merge branch 'asyncify-contract… (compare)
pacrob on asyncify-contract
add newsfragment (compare)
kclowes on master
Bump resource class (#2471) * … (compare)
@brschkv I think the best way to debug - would be try to run your own node and test against it
I don't have the infrastructure at hand to do that unfortunately...
maybe there is a difference how web3.py and web3.js construct the query
I hope I can make some time to look into that later.
Hi, I have a problem sending a raw transaction. I'm following the example in documentation, but Python returns an error. I'm not sure if it's a bug or just I'm doing it in the wrong way.
I have deployed a Hyperledger Besu network. So I'm using Web3 middleware. And I want to send a transaction using local keys. I can make the transaction using Metamask, so I think Besu network is not the problem.
Well, I first sign the transaction using the key of an account, after i send the signed transaction and by last I wait for transaction receipt. Here is the code:
w3 = Web3(Web3.HTTPProvider("http://192.168.43.125:10101"))
w3.middleware_onion.inject(geth_poa_middleware, layer=0)
accountKey = '0x...'
transaction = {
'to': '0x...',
'value': w3.toWei(0, 'ether'),
'gas': 2000000,
'gasPrice': 100,
'nonce': 0,
'chainId': 5403
}
signed = w3.eth.account.sign_transaction(transaction, accountKey)
txHash = w3.eth.sendRawTransaction(signed.rawTransaction)
txReceipt = w3.eth.waitForTransactionReceipt(txHash)
And here is the weird thing: I can run this python3 script once! (and it works as expected). But the second time I run, I get this error:
from eth_keys.backends.native.ecdsa import private_key_to_public_key
from eth_keys.utils.address import public_key_bytes_to_address
from eth_utils import to_normalized_address
public_key = private_key_to_public_key(private_key)
address = public_key_bytes_to_address(public_key)
normalized_address = to_normalized_address(address)
web3.py 5.11.1 released :rocket:
This includes a ton of type annotation fixes and some beefing up of the intro docs. Thanks to @Uxio0 and @MatthiasLohr for contributions this round :clap:
https://web3py.readthedocs.io/en/stable/releases.html#v5-11-1-2020-06-17