add ok() / is_ok() and replace error("missing") with none handling - #7288
Open
mccanne wants to merge 2 commits into
Open
add ok() / is_ok() and replace error("missing") with none handling#7288mccanne wants to merge 2 commits into
mccanne wants to merge 2 commits into
Conversation
This commit is the first step toward getting rid of error("missing")
and handling these conditions with proper none expressions. There are
still quite a few instances of missing values being created but they
will be removed in a subsequent PR where we take out vector.NewMissing().
We introduced the Rust idioms ok() and is_ok(). We removed the has()
and missing() functions and replaced has() with is_ok(). We replaced
quiet() with ok().
There are currently some problems with SQL errors since we relied upon
error("missing") semantics to avoid reporting errors based on the
hidden paths representing SQL relations. We disabled some problematic
tests and will fix the problem and re-enabled the tests in a subsequent PR.
We also wired up rungen to generate path references that use the
field.Chain noneish parameters so the "?." dereferencing operator
works correctly.
mattnibs
reviewed
Sep 7, 2026
| data: | | ||
| fn 0/h(e): ( | ||
| has(e) | ||
| len(e)!=0 |
Collaborator
There was a problem hiding this comment.
Wait why is this not ok(e)?
Collaborator
Author
There was a problem hiding this comment.
It could be is_ok but semantic changes that to ok(e)!=none which is fine but the point of the test was to test implied where for boolean udf so it doesn't matter.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This commit is the first step toward getting rid of error("missing") and handling these conditions with proper none expressions. There are still quite a few instances of missing values being created but they will be removed in a subsequent PR where we take out vector.NewMissing().
We introduced the Rust idioms ok() and is_ok(). We removed the has() and missing() functions and replaced has() with is_ok(). We replaced quiet() with ok().
There are currently some problems with SQL errors since we relied upon error("missing") semantics to avoid reporting errors based on the hidden paths representing SQL relations. We disabled some problematic tests and will fix the problem and re-enabled the tests in a subsequent PR.
We also wired up rungen to generate path references that use the field.Chain noneish parameters so the "?." dereferencing operator works correctly.