-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Support for Unmarshalling strict in yaml v3 #602
Comments
We've replaced "strict" unmarshaling, which is an open-ended term, by more specific terms. The feature you're looking for is currently supported as KnownFields(true/false) in the decoder. We indeed need a way to pass those to the Node. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
We were working around validating the yaml fields inside the rules files, Prometheus. However, we faced an issue that the yaml v3 unmarshalling does not throw an error if it finds unknown fields inside the bytes stream. Earlier we were using
Unmarshalstrict()
from yaml v2 which was effective to handle this.Hence, it will be good if yaml v3 supports
Unmarshalstrict()
. Any other workaround would be great to know as well.The text was updated successfully, but these errors were encountered: