-
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
UnmarshalStrict()
doesn't error on duplicate keys
#284
Comments
Related: #154 |
I am facing the same issue here, I think it should throw an error if duplicate keys are found, rather than silently replacing the value |
rogpeppe
added a commit
to rogpeppe-contrib/yaml
that referenced
this issue
Jan 7, 2018
This is similar to PR go-yaml#285 but somewhat more efficient because it does not require a new map to be created for every struct unmarshal. Fixes go-yaml#284.
rogpeppe
added a commit
to rogpeppe-contrib/yaml
that referenced
this issue
Jan 8, 2018
This is similar to PR go-yaml#285 but somewhat more efficient because it does not require a new map to be created for every struct unmarshal. Fixes go-yaml#284.
Fixed by #307. |
djgilcrease
pushed a commit
to djgilcrease/yaml
that referenced
this issue
Mar 14, 2018
This is similar to PR go-yaml#285 but somewhat more efficient because it does not require a new map to be created for every struct unmarshal. Fixes go-yaml#284.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I spent yesterday afternoon tracking down a bug in our Concourse configuration whereby the root cause was a YAML file containing:
where the final
resource_types
effectively deleted the first.I thought it would be within the spirit of what
UnmarshalStrict()
sounds like it should do, if it would return an error if a key is attempted to be set in a map (or struct) that already has value.PR forthcoming for your consideration...
The text was updated successfully, but these errors were encountered: