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
[BUG] Empty key in YAML sets value to null #751
Comments
You would expect options to be an empty object? Why not an empty string? Or a numeric zero? I guess the answer is - what does the YAML parser treat it as? My guess is it treats it as null, which is why your result ended up with null |
The confusion is caused by the fact that adding a value to the empty However, it might be worth adding warning to the docs, similar to the warning that's already present about array replacement. |
Describe the bug
Merging two YAML config files results in a null value if the last file has an empty key.
Example:
Result:
Expected behavior
I would intuitively expect that the empty key is treated the same as an empty object in JSON and merged.
Please tell us about your environment:
Other information
The text was updated successfully, but these errors were encountered: