1
eth | TypeError「 Unknown kwargs 'gasPrice'」
source link: https://benpaodewoniu.github.io/2024/04/05/eth50/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
eth | TypeError「 Unknown kwargs 'gasPrice'」
EIP-1559
新规范的参数不同于旧的 gas
策略,它不再需要 gasPrice
字段,而是使用 maxFeePerGas/maxPriorityFeePerGas
的组合(type
为可选,会根据交易参数隐式设置类型)。
tx_dic["nonce"] = nonce
tx_dic['gasPrice'] = w3.eth.gasPrice
tx_dic["nonce"] = nonce
tx_dic['maxFeePerGas'] = w3.eth.gasPrice
Recommend
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK