-
Notifications
You must be signed in to change notification settings - Fork 44
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
bugfix: ignore extra fields in yaml #107
Conversation
Ignoring extra fields makes the code forward compatible with changes in the yaml format, without a version bump being necessary.
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.
Looks good to me. Good fix.
@@ -319,7 +319,7 @@ func readSlices(release *Release, baseDir, dirName string) error { | |||
|
|||
type yamlRelease struct { | |||
Format string `yaml:"format"` | |||
Archives map[string]yamlArchive `yaml:"archives` | |||
Archives map[string]yamlArchive `yaml:"archives"` |
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.
nice catch!
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.
Indeed.
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.
Nice. This also propagates to PathInfo
right? (e.g. /path: {badkind: foo}
)
@cjdcordeiro You are absolutely right, I have added another field in the test to reflect that. |
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.
Thanks!
A bit too late, but also not too urgent: @letFunny if you add a new key under |
Ignoring extra fields makes the code forward compatible with changes in the yaml format, without a version bump being necessary.