-
Notifications
You must be signed in to change notification settings - Fork 73
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
fix: let 0 value transactions pass #3304
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Simeon Nakov <[email protected]>
Quality Gate passedIssues Measures |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LG, just once concern:
value(tx: Transaction): void { | ||
if (tx.data === EthImpl.emptyHex && tx.value < constants.TINYBAR_TO_WEIBAR_COEF) { | ||
throw predefined.VALUE_TOO_LOW; | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we still want to confirm that the value is not negative instead of completely removing the pre-check
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good point, the value shouldn't be below under 1 tinybar but 0 should be a valid value. I will push a new commit along with new tests for this
Description:
This PR fixes the case where transactions with a value of 0 would not pass. This is needed because they would pass as valid transactions on the Ethereum network as 0 is a valid value there.
Related issue(s):
Fixes #3105
Notes for reviewer:
Checklist