-
Notifications
You must be signed in to change notification settings - Fork 299
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
value/unify: unify unfies value in every alternation #1878
Comments
Thanks @FogDong.
We haven't actually release v0.4.4 yet! What version are you testing again here therefore? Is the repro you have provided how you are using CUE here, or is this a problem you are seeing via the API? Assuming it's the latter, please can you provide a repro of what you are seeing and expecting via the API? |
Sorry for the misleading, I'm testing it with The repro with API is like:
result:
|
Noting that the repro here suffers from the same problem of unintentionally upgrading beyond
This gives:
This is actually working as intended. The release of the v0.3.x series included the new evaluator. This changed the way in which disjunction elements were eliminated. In this example under the new evaluator (which is what we have at tip), we cannot eliminate the disjunction because both struct values are open. Hence,
Let's discuss where you are seeing this and how to deal with it. |
cc @mpvl for comment on disjunctions. |
If we close every option in value, this should work like: https://cuelang.org/play/?id=cpoiRRyb5hA#cue@export@cue
But if we close the outer field, this will not work like: https://cuelang.org/play/?id=mJeqrcuPbNY#cue@export@cue
Is this working as intended? |
@FogDong
|
We are thinking about whether we should bump the priority of the implementation of |
I've left the "WorkingAsIntended" tag on because the original issue is working as intended. However, as noted by @mpvl, we are considering repurposing this issue to implement |
We have made significant progress on the new builtins as part of preparation work for v0.6.0. Trying to include this in v0.5.0 was proving to be too much, given the issues that we've needed to shake out from the cycle and comprehension rework. Therefore, moving this issue to v0.6.0. |
What version of CUE are you using (
cue version
)?Does this issue reproduce with the latest release?
yes
What did you do?
The repro is as follows:
The result is:
You can also checkout the result in playground: https://cuelang.org/play/?id=ZawmQvcToMn#cue@export@cue
What did you expect to see?
The stdout.golden is also the result in cue v0.2.0:
What did you see instead?
The text was updated successfully, but these errors were encountered: