Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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(duckdb): return null typed pyarrow arrays and disable creating tables with all null columns in duckdb #9810
base: main
Are you sure you want to change the base?
fix(duckdb): return null typed pyarrow arrays and disable creating tables with all null columns in duckdb #9810
Changes from 8 commits
94617cb
b900251
8a4be61
0cf7b66
7cb3797
d1470ba
83044f4
64baaab
9a8b951
01e9e8d
f666ff8
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
Check warning on line 25 in ibis/backends/duckdb/converter.py
Codecov / codecov/patch
ibis/backends/duckdb/converter.py#L25
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.
Can you create null-typed columns in other backends?
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.
It would be safe to just do
import pyarrow.types as pat
, right? If that gets us better IDE/typing support, I would advocate for that, even if it doesn't match thepa = pytest.importorskip("pyarrow")
lines above.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.
but that's a nit, also fine keeping it as is
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.
Can we add a struct<x: null> and an array column to check for these nested types as well?
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.
In a follow up.
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.
I think for the purpose of this PR we need to recurse into nested types, eg if a structure field is Nulltype we need to deal with that too...
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.
This should be done in a follow-up.
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.
In the followup, the semantics of this are going to need to change. Since this is internal-only, I think it is fine for this churn to happen, but just writing this down for when I/we implement it.
We use this for two things:
OK, for these two use cases, consider:
What should this be? Could return something ibis-internal that isn't really machine-interpretable, and only for this error message, that is like jq's DSL, like
("s.n", "a<items>", "m1<values>", "m2<keys>", "n")
? I think that would suffice for our two needs.