wanghuangang avatar

slove sendRawTransaction(**)'s same nonce problem

wanghuangang

Published: 17 Apr 2018 › Updated: 17 Apr 2018slove sendRawTransaction(**)'s same nonce problem

slove sendRawTransaction(**)'s same nonce problem

use python3,web3.py

follow code:
for k,v in self.web3.txpool.inspect.pending.items():
if str(k).lower() == fromwho.lower():
noncenum = len(v)
break

tx = Transaction(nonce=(self.web3.eth.getTransactionCount(fromwho) noncenum),gasprice=self.web3.eth.gasPrice,to=self.contract_address,startgas=70000,
value=0,
data = datahex)

Now you can Batch sendRawTransaction

Leave slove sendRawTransaction(**)'s same nonce problem to:

Written by

Read more #python3 posts


Best Posts From wanghuangang

We have not curated any of wanghuangang's posts yet. But you can encourage our curation team to review posts by visiting them regularly and by referring other readers. Because we give priority to frequently read content.

More Posts From wanghuangang