-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
chore(remap): Make del function only take one arg #5633
Conversation
Signed-off-by: Luc Perkins <[email protected]>
@JeanMertz @FungusHumungus There's a bit more work that needs to be done here to have I'll finish this up when we get the desired end state sorted. |
Signed-off-by: Luc Perkins <[email protected]>
@lucperkins does this close an issue? |
@binarylogic It might address #5566, but I'm going to hold off on pushing any further on this until there's consensus around expected behavior. |
Signed-off-by: Luc Perkins <[email protected]>
Signed-off-by: Luc Perkins <[email protected]>
Signed-off-by: Luc Perkins <[email protected]>
Signed-off-by: Luc Perkins <[email protected]>
Signed-off-by: Luc Perkins <[email protected]>
Signed-off-by: Luc Perkins <[email protected]>
Also linked to #5605. |
To move this forward: @binarylogic @lucperkins For this release we just need to answer: should calling |
For now, it should return |
a7fe062
to
d07a810
Compare
Signed-off-by: Luc Perkins <[email protected]>
It looks like this is always returning I'm sure I saw somewhere you added a |
@FungusHumungus You're not just seeing things 😄 I did have that. I think I misunderstood the outcome of the discussion above and I now see that |
Signed-off-by: Luc Perkins <[email protected]>
Signed-off-by: Luc Perkins <[email protected]>
d07a810
to
f5bcf6f
Compare
Signed-off-by: Luc Perkins <[email protected]>
@FungusHumungus Okay, I've reverted that behavior. I've left |
Signed-off-by: Luc Perkins <[email protected]>
Signed-off-by: Stephen Wakely <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is looking good, but isn't quite what we want just yet. I left some notes on what I think we should do before we merge this PR.
Signed-off-by: Luc Perkins <[email protected]>
Signed-off-by: Luc Perkins <[email protected]>
Signed-off-by: Luc Perkins <[email protected]>
Signed-off-by: Jean Mertz <[email protected]>
Signed-off-by: Jean Mertz <[email protected]>
Signed-off-by: Jean Mertz <[email protected]>
I updated the PR based on the latest consensus in #5633 (comment). This should be good for a final round of reviews before we merge it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! Just a few small suggestions / questions.
Signed-off-by: Jean Mertz <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work!
"user_id": 1 | ||
} | ||
source: #""" | ||
.user.id = if exists(.user_id) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TIL we support if
s as expressions 😄
Signed-off-by: Luc Perkins <[email protected]>
Signed-off-by: Jean Mertz <[email protected]>
At the moment, the
del
function can be used to delete any number of object fields. This capability, however, is inconsistent with an emerging core tenet of TRL, which is that functions should return a single value. Ifdel
is called on two fields and only one exists, it's not clear what the appropriate response should be. Furthermore, it's been decided thatdel
should return the value of the field deleted rather thannull
, in order to "bubble up" the value of the field upon deletion and thus enable expressions like this:Closes #5605