Skip to content

Conversation

@strauss-m
Copy link
Contributor

Description

Transaction's field "to" was not encoded in contract creation since it was not set.
The facilitate ETS success, this field is expected to always be present.

Proposed Solution

The fix allows the encoding of empty fields, and remove the duplicated (and not working) custom option serializer

@jvdp
Copy link
Contributor

jvdp commented Jul 12, 2021

Interesting, I actually did the same change way back but it was reverted quickly after: a8b92f5 (#965)

I wonder if you'll run into anything. Does retesteth not complain about extra fields?

@strauss-m
Copy link
Contributor Author

Actually, unit-tests are not happy with this change.
eth_getTransactionReceipt is expecting either a root, or a status, and it's handled throught optional (see https://eth.wiki/json-rpc/API#eth_gettransactionreceipt).
I'm guess I should rollback the DefaultFormat.preserveEmptyValue part and do a hand-crafted custom json encoder for the EthTransactionResponse.

@strauss-m strauss-m force-pushed the fix/ETCM-980_unmarshal_error branch 8 times, most recently from ce7590f to 29a0349 Compare July 13, 2021 13:13
@strauss-m strauss-m force-pushed the fix/ETCM-980_unmarshal_error branch from 29a0349 to 58931bb Compare July 13, 2021 13:15
@strauss-m strauss-m merged commit 357bc89 into develop Jul 13, 2021
@strauss-m strauss-m deleted the fix/ETCM-980_unmarshal_error branch July 13, 2021 15:12
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.

4 participants