1

I have some simple question. What state_version stands for, and when it should be changed?

As I can see, in Cumulus parachain template on polkadot-v0.9.18 tag the state_version was changed to 1.
Also, transaction_version was increased, but when I compare extrinsic ordering and metadata on our chain (between 0.9.16 and 0.9.18), it looks like transaction_version need not change.

1 Answer 1

4

I think state_version is related to migration to a new version of the representation of the key-value trie. I think if you start a new chain, it's better to use the latest version from the start. At the moment of writing, I think it's the version 1.

Changing transaction_version is just a way to communicate that the transaction/extrinsic became incompatible with another version. For example, in case you change parameters of a dispatchable to something else, you will need to bump the transaction_version or else a user sent transaction might be misinterpreted.

And, btw, those are not related to Cumulus but rather are coming from Substrate.

See documentation to those methods here.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.