Skip to content
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

std.mergePatch loses hidden fields #219

Closed
guoshimin opened this issue Jul 19, 2016 · 2 comments
Closed

std.mergePatch loses hidden fields #219

guoshimin opened this issue Jul 19, 2016 · 2 comments

Comments

@guoshimin
Copy link
Contributor

% jsonnet -e 'local a = {a:: "foo"}; local b = std.mergePatch(a, {}); b.a'
RUNTIME ERROR: Field does not exist: a
    <cmdline>:1:57-59
@sparkprime
Copy link
Contributor

This is because mergePatch is a JSON standard and the value is effectively manifested to JSON first. What are you trying to do?

@guoshimin
Copy link
Contributor Author

Sorry for the late response. I can't recall what motivated this issue report. I guess it was just that this behavior didn't seem intuitive to me. I'll close it for now and reopen if I have a real use case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants