Skip to content
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

EIP-2718 Typed Transaction Envelopes #1645

Merged
merged 24 commits into from
Dec 2, 2020

Conversation

RatanRSur
Copy link
Contributor

@RatanRSur RatanRSur commented Dec 1, 2020

PR description

This implements the encoding/decoding logic and because it's backwards compatible we can introduce it immediately. You can see that some of the typed-transaction specific encoding/decoding logic is tested where there are EIP-1559 encoding/decoding tests but there'll be more tests included in the EIP-2930 PR.

I synced mainnet up to block ~50k so that we know we're deserializing and building legacy transactions/receipts correctly.

Hide whitespace changes.

Fixed Issue(s)

fixed #1505

Changelog

Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
…oder/decoder classes

Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
@RatanRSur RatanRSur marked this pull request as ready for review December 1, 2020 22:54
Copy link
Contributor

@AbdelStark AbdelStark left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me. Only looked at the code

Signed-off-by: Ratan Rai Sur <ratan.r.sur@gmail.com>
@RatanRSur RatanRSur merged commit 021ce8e into hyperledger:master Dec 2, 2020
@RatanRSur RatanRSur deleted the eip-2718-easy-mode branch December 2, 2020 14:02
try {
input.enterList();
} catch (RLPException rlpe) {
if (rlpe.getMessage().contains("Expected current item to be a list")) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't there a better way to check the error type like a getCode() ? Because a simple modification of the message can lead to a change in behavior

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're right, it's brittle as is. I'll change it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement EIP-2718
3 participants