Skip to content

bug: deserializing into nullable field#1649

Merged
SpencerTorres merged 4 commits intoClickHouse:fix_pr_1649from
rbroggi:issue_1648
Sep 13, 2025
Merged

bug: deserializing into nullable field#1649
SpencerTorres merged 4 commits intoClickHouse:fix_pr_1649from
rbroggi:issue_1648

Conversation

@rbroggi
Copy link
Copy Markdown
Contributor

@rbroggi rbroggi commented Sep 10, 2025

Summary

This is a reproducer of the bug here: #1648 (comment)

There are 3 commits in this PR. If you checkout the code in the second commit you will see the panic happening in the TestArrayTupleNullableFieldPanic test.

If you checkout the 3rd commit (tip of the branch) the test is fixed.

Notice how the deserialization into a nullable field that is inside a tuple causes a panic.

There are 2 tests - one using nullable field (which fails with the panic) and one which succeeds without using nullable.

Notice that the existing method scanMap and scanSlice already properly handle nil cases it was only missing in this scanStruct.

Checklist

Delete items not relevant to your PR:

@CLAassistant
Copy link
Copy Markdown

CLAassistant commented Sep 10, 2025

CLA assistant check
All committers have signed the CLA.

@SpencerTorres SpencerTorres changed the base branch from main to fix_pr_1649 September 13, 2025 02:22
@SpencerTorres SpencerTorres merged commit 9724042 into ClickHouse:fix_pr_1649 Sep 13, 2025
4 of 14 checks passed
@SpencerTorres SpencerTorres mentioned this pull request Sep 13, 2025
SpencerTorres added a commit that referenced this pull request Sep 13, 2025
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

Successfully merging this pull request may close these issues.

3 participants