[ 
https://issues.apache.org/jira/browse/ARROW-14168?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17461550#comment-17461550
 ] 

Dewey Dunnington commented on ARROW-14168:
------------------------------------------

Reprex:

{code:R}
tf <- tempfile(fileext = ".R")

write("
library(arrow, warn.conflicts = FALSE)
library(dplyr, warn.conflicts = FALSE)

record_batch(some_numbers = 1:5) %>% 
  summarise(
    if_else(TRUE, median(some_numbers), median(some_numbers))
  )
", tf)

processx::run(glue::glue("{R.home()}/bin/Rscript"), args = tf)
#> $status
#> [1] 0
#> 
#> $stdout
#> [1] "InMemoryDataset (query)\nif_else(TRUE, median(some_numbers), 
median(some_numbers)): double (if_else(true, ..temp0, ..temp1))\n\nSee $.data 
for the source Arrow object\n"
#> 
#> $stderr
#> [1] "Warning messages:\n1: median() currently returns an approximate median 
in Arrow \n2: median() currently returns an approximate median in Arrow \n"
#> 
#> $timeout
#> [1] FALSE
{code}


> [R] Warn only once about arrow function differences
> ---------------------------------------------------
>
>                 Key: ARROW-14168
>                 URL: https://issues.apache.org/jira/browse/ARROW-14168
>             Project: Apache Arrow
>          Issue Type: Improvement
>          Components: R
>            Reporter: Neal Richardson
>            Assignee: Dragoș Moldovan-Grünfeld
>            Priority: Major
>              Labels: good-first-issue
>             Fix For: 7.0.0
>
>
> When someone calls median or quantile, we warn them that it is approximate. 
> -When someone calls if_else, case_when, or coalesce on a dictionary array, we 
> warn them that it will be converted to string type.- (if_else, case_when, and 
> coalesce now have native support for dictionary arrays.) We probably only 
> need to warn the first time. (This will also solve the issue of uncaught 
> duplicate warnings in our tests, which the testthat 3e upgrade exposes.)



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

Reply via email to