Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions r/R/metadata.R
Original file line number Diff line number Diff line change
Expand Up @@ -188,8 +188,7 @@ apply_arrow_r_metadata <- function(x, r_metadata) {
# we cannot apply this row-level metadata, since the order of the rows is
# not guaranteed to be the same, so don't even try, but warn what's going on
trace <- trace_back()
# TODO: remove `trace$calls %||% trace$call` once rlang > 0.4.11 is released
in_dplyr_collect <- any(map_lgl(trace$calls %||% trace$call, function(x) {
in_dplyr_collect <- any(map_lgl(trace$call, function(x) {
grepl("collect\\.([aA]rrow|Dataset)", x)[[1]]
}))
if (in_dplyr_collect) {
Expand Down Expand Up @@ -296,8 +295,7 @@ arrow_attributes <- function(x, only_top_level = FALSE) {
# we cannot apply this row-level metadata, since the order of the rows is
# not guaranteed to be the same, so don't even try, but warn what's going on
trace <- trace_back()
# TODO: remove `trace$calls %||% trace$call` once rlang > 0.4.11 is released
in_dataset_write <- any(map_lgl(trace$calls %||% trace$call, function(x) {
in_dataset_write <- any(map_lgl(trace$call, function(x) {
grepl("write_dataset", x, fixed = TRUE)[[1]]
}))
if (in_dataset_write) {
Expand Down
Loading