-
Notifications
You must be signed in to change notification settings - Fork 4
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 DuckDB 1.1.0 #4
Conversation
To build the gem on my macOS machine I had to specify the duckdb dir. Not sure why it is not found automatically?
Also, the GitHub Actions workflow no longer works. |
Thanks. |
Could you rebase on master? |
609368d
to
791f6e5
Compare
Seems to work now, thanks! https://github.com/stenlarsson/red-arrow-duckdb/actions/runs/11249869803 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
ext/arrow-duckdb/arrow-duckdb.cpp
Outdated
@@ -99,7 +101,7 @@ namespace { | |||
result_ensure_gschema(Result *result) | |||
{ | |||
ArrowSchema c_abi_schema; | |||
duckdb_arrow_schema schema = &c_abi_schema; | |||
duckdb_arrow_schema schema = reinterpret_cast<duckdb_arrow_schema>(&c_abi_schema); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
duckdb_arrow_schema schema = reinterpret_cast<duckdb_arrow_schema>(&c_abi_schema); | |
auto schema = reinterpret_cast<duckdb_arrow_schema>(&c_abi_schema); |
ext/arrow-duckdb/arrow-duckdb.cpp
Outdated
@@ -121,7 +123,7 @@ namespace { | |||
result_fetch_internal(VALUE self, Result *result) | |||
{ | |||
ArrowArray c_abi_array = {}; | |||
duckdb_arrow_array array = &c_abi_array; | |||
duckdb_arrow_array array = reinterpret_cast<duckdb_arrow_array>(&c_abi_array); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
duckdb_arrow_array array = reinterpret_cast<duckdb_arrow_array>(&c_abi_array); | |
auto array = reinterpret_cast<duckdb_arrow_array>(&c_abi_array); |
ext/arrow-duckdb/arrow-duckdb.cpp
Outdated
@@ -220,7 +222,7 @@ namespace { | |||
query_sql_arrow(VALUE self, VALUE sql) | |||
{ | |||
rubyDuckDBConnection *ctx; | |||
Data_Get_Struct(self, rubyDuckDBConnection, ctx); | |||
ctx = get_struct_connection(self); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you remove rubyDuckDBConnection *ctx;
and use auto ctx = ...
instead?
This fixes a number of errors due to changes in DuckDB and ruby-duckdb between 0.5.0 and 1.1.0.
791f6e5
to
1e8b5f1
Compare
Updated according to review comments. |
Thanks! |
This fixes a number of errors due to changes in DuckDB and ruby-duckdb between 0.5.0 and 1.1.0.