-
-
Notifications
You must be signed in to change notification settings - Fork 6.2k
Remove all the deprecated setting fallback logic because it reached the target version and put a warning there if old configuration are still present #33707
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 1 commit
564c670
5ab0de8
1f62ea3
ae166fd
302bb33
7e7811b
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -326,7 +326,16 @@ func LogStartupProblem(skip int, level log.Level, format string, args ...any) { | |||||||||||||||
|
|
||||||||||||||||
| func deprecatedSetting(rootCfg ConfigProvider, oldSection, oldKey, newSection, newKey, version string) { | ||||||||||||||||
| if rootCfg.Section(oldSection).HasKey(oldKey) { | ||||||||||||||||
| LogStartupProblem(1, log.ERROR, "Deprecation: config option `[%s].%s` presents, please use `[%s].%s` instead because this fallback will be/has been removed in %s", oldSection, oldKey, newSection, newKey, version) | ||||||||||||||||
| LogStartupProblem(1, log.ERROR, "Deprecation: config option `[%s].%s` presents, please use `[%s].%s` instead because this fallback will be removed in %s", oldSection, oldKey, newSection, newKey, version) | ||||||||||||||||
lunny marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||||||||||||||||
| } | ||||||||||||||||
| } | ||||||||||||||||
|
|
||||||||||||||||
| // make linter happy when there is no deprecated setting at the moment | ||||||||||||||||
| var _ = deprecatedSetting | ||||||||||||||||
|
|
||||||||||||||||
| func deprecatedSettingWarning(rootCfg ConfigProvider, oldSection, oldKey, newSection, newKey, version string) { | ||||||||||||||||
|
||||||||||||||||
| if rootCfg.Section(oldSection).HasKey(oldKey) { | ||||||||||||||||
| LogStartupProblem(1, log.ERROR, "Deprecation: config option `[%s].%s` presents, please use `[%s].%s` instead because this fallback has been removed in %s", oldSection, oldKey, newSection, newKey, version) | ||||||||||||||||
|
||||||||||||||||
| func deprecatedSettingWarning(rootCfg ConfigProvider, oldSection, oldKey, newSection, newKey, version string) { | |
| if rootCfg.Section(oldSection).HasKey(oldKey) { | |
| LogStartupProblem(1, log.ERROR, "Deprecation: config option `[%s].%s` presents, please use `[%s].%s` instead because this fallback has been removed in %s", oldSection, oldKey, newSection, newKey, version) | |
| // deprecatedSettingWarning is a warning about a setting that has already been removed, giving the user a last chance to fix their app.ini | |
| func deprecatedSettingWarning(rootCfg ConfigProvider, oldSection, oldKey, newSection, newKey, version string) { | |
| if rootCfg.Section(oldSection).HasKey(oldKey) { | |
| LogStartupProblem(1, log.ERROR, "Deprecation: config option `[%s].%s` is still present, please use `[%s].%s` instead. This fallback has been removed in %s", oldSection, oldKey, newSection, newKey, version) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Uh oh!
There was an error while loading. Please reload this page.