Details
-
Improvement
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
None
Description
When someone calls median or quantile, we warn them that it is approximate. When a session is interactive, this happens only the first time in interactive sessions for median and quantile https://github.com/apache/arrow/blob/d197ad31c3d7c16ecee74cb76a71ce397e905b3b/r/R/dplyr-summarize.R#L107-L111
But when we test, the session is not interactive so we get a number of spurious extra warnings. Because of this we set a local testthat edition https://github.com/apache/arrow/blob/d197ad31c3d7c16ecee74cb76a71ce397e905b3b/r/tests/testthat/test-dplyr-summarize.R#L299-L301 which swallows any extra warnings.
We can either only warn once regardless of interactivity (which is probably totally fine for these warnings), or we could use something like local_interactive in these tests so that we only get the first warning https://rlang.r-lib.org/reference/is_interactive.html
Attachments
Issue Links
- links to