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

Add support for the "r+" datatype in the C Data interface / RunArray #5631

Closed
notfilippo opened this issue Apr 12, 2024 · 1 comment · Fixed by #5632
Closed

Add support for the "r+" datatype in the C Data interface / RunArray #5631

notfilippo opened this issue Apr 12, 2024 · 1 comment · Fixed by #5632
Labels
arrow Changes to the arrow crate enhancement Any new improvement worthy of a entry in the changelog

Comments

@notfilippo
Copy link
Contributor

Describe the bug

C Data interface error: The datatype ""+r"" is still not supported in Rust implementation

To Reproduce

let value_data = PrimitiveArray::<Int8Type>::from_iter_values([10_i8, 11, 12, 13, 14, 15, 16, 17]);

// Construct a run_ends array:
let run_ends_values = [4_i32, 6, 7, 9, 13, 18, 20, 22];
let run_ends_data = PrimitiveArray::<Int32Type>::from_iter_values(run_ends_values.iter().copied());

// Construct a run ends encoded array from the above two
let ree_array = RunArray::<Int32Type>::try_new(&run_ends_data, &value_data).unwrap();

// export it
let (array, schema) = to_ffi(&ree_array.to_data())?;

// (simulate consumer) import it
let data = unsafe { from_ffi(array, &schema) }?;

Expected behavior

The RunArray can be converted to / from the C data interface.

@notfilippo notfilippo added the enhancement Any new improvement worthy of a entry in the changelog label Apr 12, 2024
@alamb alamb changed the title Add support for the "r+" datatype in the C Data interface Add support for the "r+" datatype in the C Data interface / RunArray Apr 12, 2024
@tustvold tustvold added the arrow Changes to the arrow crate label Apr 17, 2024
@tustvold
Copy link
Contributor

label_issue.py automatically added labels {'arrow'} from #5632

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
arrow Changes to the arrow crate enhancement Any new improvement worthy of a entry in the changelog
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants