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

[C#] Dense union arrays return incorrect results for IsValid and IsNull #41137

Closed
adamreeve opened this issue Apr 11, 2024 · 1 comment
Closed
Assignees
Milestone

Comments

@adamreeve
Copy link
Contributor

adamreeve commented Apr 11, 2024

Describe the bug, including details regarding any error messages, version, and platform.

IsValid and IsNull are implemented in the base UnionArray class, which doesn't account for the value offsets.

I encountered this when looking at how to test null count calculation for union arrays (#41136)

Component(s)

C#

CurtHagenlocher pushed a commit that referenced this issue Apr 11, 2024
### Rationale for this change

Fixes incorrect logic for IsNull and IsValid on DenseUnionArrays

### What changes are included in this PR?

Adds a new abstract `FieldIsValid` method to `UnionArray` to customize behaviour for sparse and dense union arrays.

### Are these changes tested?

Yes, I've added unit tests.

### Are there any user-facing changes?

Yes, this is a user facing bug fix.
* GitHub Issue: #41137

Authored-by: Adam Reeve <adreeve@gmail.com>
Signed-off-by: Curt Hagenlocher <curt@hagenlocher.org>
@CurtHagenlocher
Copy link
Contributor

Issue resolved by pull request 41138
#41138

@CurtHagenlocher CurtHagenlocher added this to the 17.0.0 milestone Apr 11, 2024
vibhatha pushed a commit to vibhatha/arrow that referenced this issue Apr 15, 2024
### Rationale for this change

Fixes incorrect logic for IsNull and IsValid on DenseUnionArrays

### What changes are included in this PR?

Adds a new abstract `FieldIsValid` method to `UnionArray` to customize behaviour for sparse and dense union arrays.

### Are these changes tested?

Yes, I've added unit tests.

### Are there any user-facing changes?

Yes, this is a user facing bug fix.
* GitHub Issue: apache#41137

Authored-by: Adam Reeve <adreeve@gmail.com>
Signed-off-by: Curt Hagenlocher <curt@hagenlocher.org>
@raulcd raulcd modified the milestones: 17.0.0, 16.1.0 Apr 29, 2024
raulcd pushed a commit that referenced this issue Apr 29, 2024
### Rationale for this change

Fixes incorrect logic for IsNull and IsValid on DenseUnionArrays

### What changes are included in this PR?

Adds a new abstract `FieldIsValid` method to `UnionArray` to customize behaviour for sparse and dense union arrays.

### Are these changes tested?

Yes, I've added unit tests.

### Are there any user-facing changes?

Yes, this is a user facing bug fix.
* GitHub Issue: #41137

Authored-by: Adam Reeve <adreeve@gmail.com>
Signed-off-by: Curt Hagenlocher <curt@hagenlocher.org>
tolleybot pushed a commit to tmct/arrow that referenced this issue May 2, 2024
### Rationale for this change

Fixes incorrect logic for IsNull and IsValid on DenseUnionArrays

### What changes are included in this PR?

Adds a new abstract `FieldIsValid` method to `UnionArray` to customize behaviour for sparse and dense union arrays.

### Are these changes tested?

Yes, I've added unit tests.

### Are there any user-facing changes?

Yes, this is a user facing bug fix.
* GitHub Issue: apache#41137

Authored-by: Adam Reeve <adreeve@gmail.com>
Signed-off-by: Curt Hagenlocher <curt@hagenlocher.org>
tolleybot pushed a commit to tmct/arrow that referenced this issue May 4, 2024
### Rationale for this change

Fixes incorrect logic for IsNull and IsValid on DenseUnionArrays

### What changes are included in this PR?

Adds a new abstract `FieldIsValid` method to `UnionArray` to customize behaviour for sparse and dense union arrays.

### Are these changes tested?

Yes, I've added unit tests.

### Are there any user-facing changes?

Yes, this is a user facing bug fix.
* GitHub Issue: apache#41137

Authored-by: Adam Reeve <adreeve@gmail.com>
Signed-off-by: Curt Hagenlocher <curt@hagenlocher.org>
rok pushed a commit to tmct/arrow that referenced this issue May 8, 2024
### Rationale for this change

Fixes incorrect logic for IsNull and IsValid on DenseUnionArrays

### What changes are included in this PR?

Adds a new abstract `FieldIsValid` method to `UnionArray` to customize behaviour for sparse and dense union arrays.

### Are these changes tested?

Yes, I've added unit tests.

### Are there any user-facing changes?

Yes, this is a user facing bug fix.
* GitHub Issue: apache#41137

Authored-by: Adam Reeve <adreeve@gmail.com>
Signed-off-by: Curt Hagenlocher <curt@hagenlocher.org>
rok pushed a commit to tmct/arrow that referenced this issue May 8, 2024
### Rationale for this change

Fixes incorrect logic for IsNull and IsValid on DenseUnionArrays

### What changes are included in this PR?

Adds a new abstract `FieldIsValid` method to `UnionArray` to customize behaviour for sparse and dense union arrays.

### Are these changes tested?

Yes, I've added unit tests.

### Are there any user-facing changes?

Yes, this is a user facing bug fix.
* GitHub Issue: apache#41137

Authored-by: Adam Reeve <adreeve@gmail.com>
Signed-off-by: Curt Hagenlocher <curt@hagenlocher.org>
vibhatha pushed a commit to vibhatha/arrow that referenced this issue May 25, 2024
### Rationale for this change

Fixes incorrect logic for IsNull and IsValid on DenseUnionArrays

### What changes are included in this PR?

Adds a new abstract `FieldIsValid` method to `UnionArray` to customize behaviour for sparse and dense union arrays.

### Are these changes tested?

Yes, I've added unit tests.

### Are there any user-facing changes?

Yes, this is a user facing bug fix.
* GitHub Issue: apache#41137

Authored-by: Adam Reeve <adreeve@gmail.com>
Signed-off-by: Curt Hagenlocher <curt@hagenlocher.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants