fix(config): ignore yaml backup files in model loader#9443
Open
leinasi2014 wants to merge 1 commit intomudler:masterfrom
Open
fix(config): ignore yaml backup files in model loader#9443leinasi2014 wants to merge 1 commit intomudler:masterfrom
leinasi2014 wants to merge 1 commit intomudler:masterfrom
Conversation
Only load files whose real extension is .yaml or .yml so backup files like model.yaml.bak do not override active configs. Add a regression test covering plain and timestamped backup files. Assisted-by: Codex:gpt-5.4 docker Signed-off-by: leinasi2014 <leinasi2014@gmail.com>
e0dc41d to
5959572
Compare
mudler
approved these changes
Apr 20, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR fixes #9442.
It tightens
LoadModelConfigsFromPath()so only files whose actual extension is.yamlor.ymlare loaded as model configs. Backup files such asmodel.yaml.bakandmodel.yaml.bak.<timestamp>are now ignored.It also adds a regression test covering:
.yamlconfig.yaml.bak.yaml.bak.<timestamp>Notes for Reviewers
*.yaml.bak*files in/modelsoverrode the active config with the samename:.make protogen-gotests/models_fixtures/*intotest-modelsgo test ./core/configSigned commits