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

Fix get_json_object producing wrong output with wildcard paths #2220

Merged
merged 5 commits into from
Jul 12, 2024

Conversation

ttnghia
Copy link
Collaborator

@ttnghia ttnghia commented Jul 11, 2024

The output of get_json_object is wrong when the json path has a wildcard following by a name instruction. In such situations, the early return statement in the code path processing name instruction may cause the entire output row to be a null, instead of ignoring the child objects that do not contain the desired field.

This fixes the issue by removing the early return statement mentioned above.

Closes NVIDIA/spark-rapids#11172.

Signed-off-by: Nghia Truong <[email protected]>
@ttnghia ttnghia added the bug Something isn't working label Jul 11, 2024
@ttnghia ttnghia requested a review from res-life July 11, 2024 19:46
@ttnghia ttnghia self-assigned this Jul 11, 2024
@ttnghia
Copy link
Collaborator Author

ttnghia commented Jul 11, 2024

build

Copy link
Collaborator

@res-life res-life left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@res-life
Copy link
Collaborator

Good catch!

@ttnghia ttnghia merged commit 7b4ef3c into NVIDIA:branch-24.08 Jul 12, 2024
3 checks passed
@ttnghia ttnghia deleted the fix_get_json_object branch July 12, 2024 06:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] get_json_object returns wrong output with wildcard path
2 participants