-
Notifications
You must be signed in to change notification settings - Fork 4.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When an error is thrown during a transaction the object error.receipt
is undefined
.
#6320
Comments
This seems issue with backend ganache as exception happens without using 4.x even: If you deploy stackTrace contract on ganache node and do following rpc:
ganache throws error:
Above exception happens when running test, and at line https://github.com/nazarhussain/truffle/blob/nh/web3-4x-upgrade/packages/debugger/test/stacktrace.js#L198 there is internal estimate_gas call here: |
Thanks @jdevcs for sharing the findings, |
With above scenario 1.x also throws same error, this error is happening independent of lib. |
created issue in ganache for this: trufflesuite/ganache#4526 |
So above exception happens with 1.x, 4.x, or even without web3.js lib as mentioned above.
at this line. with above fixes I am locally able to get err.receipt.transactionHash in case of error:
|
Changes applied here: trufflesuite/truffle@70250d8 |
In 1.x, the object
error.receipt
used to contain the receipt. But it is no longer at 4.x.This for example cause some tests to fail at Truffle when migrating to 4.x. Like this one:
https://github.com/nazarhussain/truffle/blob/nh/web3-4x-upgrade/packages/debugger/test/stacktrace.js
The text was updated successfully, but these errors were encountered: