apache / apache/arrow

[R] Mixed-type list columns fail with unintuitive error message

Open
#47,436 0 comments 0 reactions 0 assignees View on GitHub
Component: R Status: needs champion Type: bug
Dominant language
C++
Stars
17.1k
Forks
4.3k
Avg merge
3d 13h
Merged PRs (30d)
88

Description

### Describe the bug, including details regarding any error messages, version, and platform.

Often surfaced when users are trying to call `write_parquet()` on tibbles with list-columns

``` r
library(arrow)

# works
df <- tibble::tibble(x = list(NULL, 1))
arrow_table(df)
#> Table
#> 2 rows x 1 columns
#> $x: list>

# fails
df <- tibble::tibble(x = list(NULL, 1, "a"))
arrow_table(df)
#> Error: Invalid: cannot convert

# fails
df <- tibble::tibble(x = list(1, "a"))
arrow_table(df)
#> Error: Invalid: cannot convert
```

### Component(s)

R

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.