Skip to content

Config min version#1955

Merged
zricethezav merged 4 commits into
masterfrom
config-min-version
Oct 16, 2025
Merged

Config min version#1955
zricethezav merged 4 commits into
masterfrom
config-min-version

Conversation

@zricethezav
Copy link
Copy Markdown
Collaborator

Description:

Introduces a minversion check that users can define in the config. The default config will ship w/ v8.25.0.

Checklist:

  • Does your PR pass tests?
  • Have you written new tests for your changes?
  • Have you lint your code locally prior to submission?

Comment thread config/config.go Outdated
Comment thread config/config.go Outdated
Comment thread config/config.go Outdated

// extend minVersion
if validateMinVersion(extensionConfig.MinVersion) != nil {
// fail here?
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Yeah.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

lolol

Comment thread cmd/version.go Outdated
Comment thread config/config.go Outdated
Comment on lines +430 to +433
}
if extensionConfig.MinVersion != "" {
c.MinVersion = extensionConfig.MinVersion
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

So this basically bumps the min version to the highest1 min version out of this and the extended config? (or chain of them if they chain, I can't remember if you can chain config extensions).

Footnotes

  1. Because it'd fail if the min version of the parent config was set and the extension config was lower, correct?

Copy link
Copy Markdown
Collaborator Author

@zricethezav zricethezav Oct 16, 2025

Choose a reason for hiding this comment

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

I actually think

	if extensionConfig.MinVersion != "" {
		c.MinVersion = extensionConfig.MinVersion
	}

is extraneous. All we can about is checking if there is a minVersion higher than the build version somewhere in the extend chain. Right? Does that make sense @rgmz @bplaxco ?

Comment thread config/config.go
@zricethezav zricethezav merged commit 3821f30 into master Oct 16, 2025
6 of 9 checks passed
@zricethezav zricethezav deleted the config-min-version branch October 16, 2025 18:53
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.

3 participants