Skip to content

config: add version to the config file#9413

Merged
cmwaters merged 6 commits intomainfrom
cal/config-version
Sep 22, 2022
Merged

config: add version to the config file#9413
cmwaters merged 6 commits intomainfrom
cal/config-version

Conversation

@cmwaters
Copy link
Contributor

Ref: #9264

This is the first part of this issue. Note that existing configs will not have this version tag. In order to achieve this we should use something like confix to update older config files.

I have placed this intentionally outside the config sections to illustrate that this value should not be modifed by the user

@cmwaters cmwaters requested a review from ebuchman as a code owner September 12, 2022 09:30
@cmwaters cmwaters requested a review from a team September 12, 2022 09:30
@cmwaters cmwaters added the S:backport-to-v0.37.x Tell mergify to backport the PR to v0.37.x label Sep 12, 2022
@thanethomson thanethomson removed the S:backport-to-v0.37.x Tell mergify to backport the PR to v0.37.x label Sep 21, 2022
Copy link
Contributor

@thanethomson thanethomson left a comment

Choose a reason for hiding this comment

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

Seems good to me.

Are we going to eventually be providing some kind of version compatibility guidelines for Tendermint config files and Tendermint node versions? If so we should probably make use of some library like https://github.com/Masterminds/semver to do semantic version comparisons during validation.

Also, I see this was labelled to be backported to v0.37 - I've removed the label now given that our QA process is currently underway for v0.37.0, and the version number in version/version.go is not correct for that backport. Could we please schedule a manual backport of this for v0.37.1? (seeing that it's a non-breaking change)

@cmwaters
Copy link
Contributor Author

Are we going to eventually be providing some kind of version compatibility guidelines for Tendermint config files and Tendermint node versions?

I think generally, all newer versions of the tendermint node should be able to migrate and parse older config versions. As it stands, you could run a node with an empty config file (or with just random crap) as it would just set every value to its default (so long as the file directory structure was maintained). We don't even warn users that they have an outdated config file and that the node is about to use a bunch of defaults instead (which we should do).

@cmwaters
Copy link
Contributor Author

Also, I see this was labelled to be backported to v0.37

Yeah I kind of wanted to squeeze the versioning into v0.37 but will accept that it will have to wait. I still want to document how the Tendermint filesystem works.

@cmwaters cmwaters merged commit 561440a into main Sep 22, 2022
@cmwaters cmwaters deleted the cal/config-version branch September 22, 2022 08:49
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.

2 participants