【发布时间】:2022-01-16 12:49:26
【问题描述】:
在一个可靠的方法中,有一个 require 语句正在失败,并且 web3j 中的事务由于“Gas value is not enough”而抛出错误。
示例:require(providedtimestamp > block.timestamp, "release time is before current time");
但在来自 Etherscan 的交易中,错误消息会正确显示。示例:https://rinkeby.etherscan.io/tx/0x2ed757feef430f1695dcbbad8d13ee8df5ba630409465dbf82688dc5543dc52e
如何在使用 web3j 的方法调用期间捕获此错误消息。
【问题讨论】:
标签: blockchain solidity web3-java