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: [sc-56713] [core] query returns incorrect offsets for dense array fill value of variable-length int32 attribute #5331

Merged
merged 4 commits into from
Oct 3, 2024

Conversation

rroelke
Copy link
Contributor

@rroelke rroelke commented Oct 2, 2024

Story details: https://app.shortcut.com/tiledb-inc/story/56713

tiledb-rs uses the setting sm.var_offsets.mode = elements and the dense reader code which copies the fill value offsets does not check this setting.

This pull request fixes the issue by checking whether that value was previously set; and adds unit tests demonstrating correct fill value offsets in three different scenarios.


TYPE: BUG
DESC: Fix dense reader fill value with sm.var_offsets.mode = elements

Wrong offsets are written when "sm.var_offsets.mode = elements" is set.
Copy link
Contributor

@davisp davisp left a comment

Choose a reason for hiding this comment

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

Can we add tests for the sparse and possibly the legacy readers as well? I'm suspicious by this fix being dense specific but a test will show it regardless.

@rroelke
Copy link
Contributor Author

rroelke commented Oct 2, 2024

Can we add tests for the sparse and possibly the legacy readers as well? I'm suspicious by this fix being dense specific but a test will show it regardless.

Is there a better way to manifest fill values from a sparse array than schema evolution?
The approaches here will not do it.

EDIT: done via schema evolution.

@rroelke
Copy link
Contributor Author

rroelke commented Oct 2, 2024

Can we add tests for the sparse and possibly the legacy readers as well? I'm suspicious by this fix being dense specific but a test will show it regardless.

Added additional tests which stepping through with the debugger has confirmed to hit the legacy reader and the sparse global and unordered readers

@rroelke rroelke requested a review from davisp October 2, 2024 20:33
Copy link
Contributor

@davisp davisp left a comment

Choose a reason for hiding this comment

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

+1

@davisp davisp merged commit 351d032 into dev Oct 3, 2024
63 checks passed
@davisp davisp deleted the rr/sc-56713-dense-fill-value-int32-var branch October 3, 2024 22:18
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