airgap-it / tezos-rust-sdk

MIT License
20 stars 10 forks source link

Added Unknown to OperationContent so that the parsing does not fail if the library is not up to date on operation types #27

Closed Wicpar closed 1 year ago

Wicpar commented 1 year ago

Fix to the parsing error when unknown operations contents appear in blocks.

Wicpar commented 1 year ago

i would also note that there is no reason to use an untagged enum as it is tagged with kind. What is the rationale behind it ?

RomarQ commented 1 year ago

i would also note that there is no reason to use an untagged enum as it is tagged with kind. What is the rationale behind it ?

I agree, using tag = "kind" instead of untagged is preferable here, we will have a look at it.

At the time I believe it was because of the new operations being added, some of them got renamed and ended up being removed on mumbai upgrade.

Wicpar commented 1 year ago

Indeed if renames are possible it does make sense to keep them as untagged. The only risk is the collision of two schemas. Whichever is more risky should determine what to keep.

RomarQ commented 1 year ago

Thanks for the contribution :+1: .