Panic when inserting array literal with NULL element into a table where the matching column has a non-nullable element #12598
Labels
bug
Something isn't working
waiting-on-upstream
PR is waiting on an upstream dependency to be updated
Describe the bug
I have a custom data sink whose schema contains an array whose element type is non-nullable. If I attempt to insert an array literal with a null element into this data sink via SQL, the process exits with a panic. This behavior can be reproduced using
MemTable
.To Reproduce
The following example code can be added to
datafusion-examples/src
and run viacargo run --example array-non-nullable-element
:Running with
RUST_BACKTRACE=1
indicates that there is anunwrap()
occurring inListArray::new
.Expected behavior
I would expect this query to bubble a
DataFusionError
up to the call site instead of panicking the process.Additional context
No response
The text was updated successfully, but these errors were encountered: