Closed
Show file tree
Hide file tree
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
4 changes: 3 additions & 1 deletion .github/workflows/r.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -405,7 +405,9 @@ jobs:
)
# we use pak for package installation since it is faster, safer and more convenient
pak::local_install()
pak::pak("lintr")
# Pin the lintr version to avoid breaking changes with newer 3.2.0 version
# See: https://github.com/apache/arrow/pull/45524
pak::pak("lintr@3.1.2")
lintr::expect_lint_free()
- name: Dump install logs
shell: cmd
Expand Down
1 change: 1 addition & 0 deletions ci/docker/linux-apt-lint.dockerfile
Original file line numberDiff line numberDiff line change
Expand Up@@ -58,6 +58,7 @@ RUN cat /arrow/ci/etc/rprofile >> $(R RHOME)/etc/Rprofile.site
RUN echo "MAKEFLAGS=-j$(R -s -e 'cat(parallel::detectCores())')" >> $(R RHOME)/etc/Renviron.site
# We don't need arrow's dependencies, only lintr (and its dependencies)
RUN R -e "install.packages('lintr')"
RUN R -e "install.packages('cyclocomp')"

# Docker linter
COPY --from=hadolint /bin/hadolint /usr/bin/hadolint
Expand Down
4 changes: 3 additions & 1 deletion ci/scripts/r_test.sh
Original file line numberDiff line numberDiff line change
Expand Up@@ -91,7 +91,9 @@ export TEXMFVAR=/tmp/texmf-var
BEFORE=$(ls -alh ~/)

SCRIPT="as_cran <- !identical(tolower(Sys.getenv('NOT_CRAN')), 'true')
if (as_cran) {
# generally will be false, but we can override it by setting SKIP_VIGNETTES=true
skip_vignettes <- identical(tolower(Sys.getenv('SKIP_VIGNETTES')), 'true')
if (as_cran && !skip_vignettes) {
args <- '--as-cran'
build_args <- character()
} else {
Expand Down
3 changes: 3 additions & 0 deletions cpp/src/arrow/vendored/datetime/README.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -23,6 +23,9 @@ of the above project.
The following changes are made:
- fix internal inclusion paths (from "date/xxx.h" to simply "xxx.h")
- enclose the `date` namespace inside the `arrow_vendored` namespace
- fix 4 declarations like `CONSTCD11 date::day operator "" _d(unsigned long long d) NOEXCEPT;`
to not have offending whitespace for modern clang:
`CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;`

## How to update

Expand Down
8 changes: 4 additions & 4 deletions cpp/src/arrow/vendored/datetime/date.h
Original file line numberDiff line numberDiff line change
Expand Up@@ -963,8 +963,8 @@ operator<<(std::basic_ostream<CharT, Traits>& os, const year_month_weekday_last&
inline namespace literals
{

CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;
CONSTCD11 date::year operator ""_y(unsigned long long y) NOEXCEPT;
CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;
CONSTCD11 date::year operator ""_y(unsigned long long y) NOEXCEPT;

} // inline namespace literals
#endif // !defined(_MSC_VER) || (_MSC_VER >= 1900)
Expand DownExpand Up@@ -1972,15 +1972,15 @@ inline namespace literals
CONSTCD11
inline
date::day
operator ""_d(unsigned long long d) NOEXCEPT
operator ""_d(unsigned long long d) NOEXCEPT
{
return date::day{static_cast<unsigned>(d)};
}

CONSTCD11
inline
date::year
operator ""_y(unsigned long long y) NOEXCEPT
operator ""_y(unsigned long long y) NOEXCEPT
{
return date::year(static_cast<int>(y));
}
Expand Down
2 changes: 2 additions & 0 deletions cpp/src/parquet/size_statistics.cc
Original file line numberDiff line numberDiff line change
Expand Up@@ -18,9 +18,11 @@
#include "parquet/size_statistics.h"

#include <algorithm>
#include <array>
#include <numeric>
#include <ostream>
#include <string_view>
#include <vector>

#include "arrow/util/logging.h"
#include "parquet/exception.h"
Expand Down
21 changes: 11 additions & 10 deletions dev/tasks/r/github.linux.cran.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -21,20 +21,21 @@

jobs:
as-cran:
name: "rhub/{{ MATRIX }}"
name: "rhub/{{ '${{ matrix.config.r_image }}' }}"
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
# See https://hub.docker.com/r/rhub
r_image:
- ubuntu-gcc12 # ~ r-devel-linux-x86_64-debian-gcc
- ubuntu-clang # ~ r-devel-linux-x86_64-debian-clang
- ubuntu-next # ~ r-patched-linux-x86_64
- ubuntu-release # ~ r-release-linux-x86_64
config:
# See https://r-hub.github.io/containers/
- { r_image: "ubuntu-gcc12" } # ~ r-devel-linux-x86_64-debian-gcc
- { r_image: "ubuntu-clang" } # ~ r-devel-linux-x86_64-debian-clang
- { r_image: "ubuntu-next" } # ~ r-patched-linux-x86_64
- { r_image: "ubuntu-release" } # ~ r-release-linux-x86_64
- { r_image: "clang20", skip_vignettes: true } # ~ r-devel-linux-x86_64-fedora-clang
env:
R_ORG: "rhub"
R_IMAGE: {{ MATRIX }}
R_IMAGE: {{ '${{ matrix.config.r_image }}' }}
R_TAG: "latest"
ARROW_R_DEV: "FALSE"
steps:
Expand All@@ -46,7 +47,7 @@ jobs:
env:
{{ macros.github_set_sccache_envvars()|indent(8)}}
# setting ARROW_SOURCE_HOME='' here ensures that we use the cpp source copied into tools/
run: archery docker run -e ARROW_SOURCE_HOME='' r
run: archery docker run -e ARROW_SOURCE_HOME='' -e SKIP_VIGNETTES={{ '${{ matrix.config.skip_vignettes }}' }} r
- name: Dump install logs
run: cat arrow/r/check/arrow.Rcheck/00install.out
if: always()
Expand All@@ -57,5 +58,5 @@ jobs:
if: always()
uses: actions/upload-artifact@v4
with:
name: test-output-{{ "${{ matrix.r_image }}" }}
name: test-output-{{ "${{ matrix.config.r_image }}" }}
path: arrow/r/check/arrow.Rcheck/tests/testthat.Rout*
2 changes: 0 additions & 2 deletions dev/tasks/tasks.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -1198,8 +1198,6 @@ tasks:
test-r-linux-as-cran:
ci: github
template: r/github.linux.cran.yml
params:
MATRIX: {{ "${{ matrix.r_image }}" }}

test-r-macos-as-cran:
ci: github
Expand Down
9 changes: 9 additions & 0 deletions r/NEWS.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -19,6 +19,15 @@

# arrow 19.0.1

This release primarily updates the underlying Arrow C++ version used by the
package to version 19.0.1 and includes all changes from the 19.0.0 and 19.0.1
releases. For what's changed in Arrow C++ 19.0.0, please see the [blog
post](https://arrow.apache.org/blog/2025/01/16/19.0.0-release/) and
[changelog](https://arrow.apache.org/release/19.0.0.html#changelog).
For what's changed in Arrow C++ 19.0.1, please see the [blog
post](https://arrow.apache.org/blog/2025/02/16/19.0.1-release/) and
[changelog](https://arrow.apache.org/release/19.0.1.html#changelog).

# arrow 18.1.0

## Minor improvements and fixes
Expand Down
32 changes: 25 additions & 7 deletions r/R/dplyr-funcs-agg.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -150,13 +150,7 @@ register_bindings_aggregate <- function() {
options = list(skip_nulls = na.rm, min_count = 0L)
)
})
register_binding("arrow::one", function(...) {
set_agg(
fun = "one",
data = ensure_one_arg(list2(...), "one"),
options = list()
)
})
register_binding("arrow::one", one)
}

set_agg <- function(...) {
Expand DownExpand Up@@ -194,6 +188,30 @@ find_arrow_mask <- function() {
n <- n + 1
}
}
#' Get one value from each group
#'
#' Returns one arbitrary value from the input for each group. The function is
#' biased towards non-null values: if there is at least one non-null value for a
#' certain group, that value is returned, and only if all the values are null
#' for the group will the function return null.
#'
#' @param ... Unquoted column name to pull values from.
#'
#' @examples
#' \dontrun{
#' mtcars |>
#' arrow_table() |>
#' group_by(cyl) |>
#' summarize(x = one(disp))
#' }
#' @keywords internal
one <- function(...) {
set_agg(
fun = "one",
data = ensure_one_arg(list2(...), "one"),
options = list()
)
}

ensure_one_arg <- function(args, fun) {
if (length(args) == 0) {
Expand Down
7 changes: 4 additions & 3 deletions r/R/dplyr-funcs-doc.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -21,7 +21,7 @@
#'
#' The `arrow` package contains methods for 37 `dplyr` table functions, many of
#' which are "verbs" that do transformations to one or more tables.
#' The package also has mappings of 212 R functions to the corresponding
#' The package also has mappings of 213 R functions to the corresponding
#' functions in the Arrow compute library. These allow you to write code inside
#' of `dplyr` methods that call R functions, including many in packages like
#' `stringr` and `lubridate`, and they will get translated to Arrow and run
Expand All@@ -42,7 +42,7 @@
#' * [`collect()`][dplyr::collect()]
#' * [`compute()`][dplyr::compute()]
#' * [`count()`][dplyr::count()]
#' * [`distinct()`][dplyr::distinct()]: `.keep_all = TRUE` not supported
#' * [`distinct()`][dplyr::distinct()]: `.keep_all = TRUE` returns a non-missing value if present, only returning missing values if all are missing.
#' * [`explain()`][dplyr::explain()]
#' * [`filter()`][dplyr::filter()]
#' * [`full_join()`][dplyr::full_join()]: the `copy` argument is ignored
Expand DownExpand Up@@ -83,7 +83,7 @@
#' Functions can be called either as `pkg::fun()` or just `fun()`, i.e. both
#' `str_sub()` and `stringr::str_sub()` work.
#'
#' In addition to these functions, you can call any of Arrow's 262 compute
#' In addition to these functions, you can call any of Arrow's 271 compute
#' functions directly. Arrow has many functions that don't map to an existing R
#' function. In other cases where there is an R function mapping, you can still
#' call the Arrow function directly if you don't want the adaptations that the R
Expand All@@ -96,6 +96,7 @@
#'
#' * [`add_filename()`][arrow::add_filename()]
#' * [`cast()`][arrow::cast()]
#' * [`one()`][arrow::one()]
#'
#' ## base
#'
Expand Down
9 changes: 0 additions & 9 deletions r/README.md
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,5 @@
# arrow <img src="https://arrow.apache.org/img/arrow-logo_hex_black-txt_white-bg.png" align="right" alt="" width="120" />

<!-- badges: start -->

[![cran](https://www.r-pkg.org/badges/version-last-release/arrow)](https://cran.r-project.org/package=arrow)
[![CI](https://github.com/apache/arrow/workflows/R/badge.svg?event=push)](https://github.com/apache/arrow/actions?query=workflow%3AR+branch%3Amain+event%3Apush)
[![R-universe status badge](https://apache.r-universe.dev/badges/arrow)](https://apache.r-universe.dev)
[![conda-forge](https://img.shields.io/conda/vn/conda-forge/r-arrow.svg)](https://anaconda.org/conda-forge/r-arrow)

<!-- badges: end -->

## Overview

The R `{arrow}` package provides access to many of the features of the [Apache Arrow C++ library](https://arrow.apache.org/docs/cpp/index.html) for R users. The goal of arrow is to provide an Arrow C++ backend to `{dplyr}`, and access to the Arrow C++ library through familiar base R and tidyverse functions, or `{R6}` classes. The dedicated R package website is located [here](https://arrow.apache.org/docs/r/index.html).
Expand Down
7 changes: 4 additions & 3 deletions r/man/acero.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

26 changes: 26 additions & 0 deletions r/man/one.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion r/src/filesystem.cpp
Original file line numberDiff line numberDiff line change
Expand Up@@ -258,7 +258,7 @@ std::string fs___SubTreeFileSystem__base_path(

// [[arrow::export]]
cpp11::writable::list fs___FileSystemFromUri(const std::string& path) {
using cpp11::literals::operator""_nm;
using cpp11::literals::operator""_nm;

std::string out_path;
auto io_context = MainRThread::GetInstance().CancellableIOContext();
Expand Down
8 changes: 4 additions & 4 deletions r/tools/nixlibs.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -84,10 +84,10 @@ try_download <- function(from_url, to_file, hush = quietly) {
return(FALSE)
}
# We download some fairly large files, so ensure the timeout is set appropriately.
# This assumes a static library size of 100 MB (generous) and a download speed
# of .3 MB/s (slow). This is to anticipate slower user connections or load on
# artifactory servers.
opts <- options(timeout = max(300, getOption("timeout")))
# This assumes a static library size of 100 MB (our current biggest is 78 MB) and
# a download speed of 0.2 MB/s (slow). This is to anticipate slower user connections
# or load on artifactory servers.
opts <- options(timeout = max(600, getOption("timeout")))
on.exit(options(opts))

status <- try(
Expand Down
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Add copy buttons to all
 blocks\n(function() {\n function addCopyButtons() {\n document.querySelectorAll('pre code').forEach(function(codeBlock) {\n if (codeBlock.parentElement.hasAttribute('data-copy-added')) return;\n codeBlock.parentElement.setAttribute('data-copy-added', 'true');\n \n var btn = document.createElement('button');\n btn.textContent = 'Copy';\n btn.style.cssText = 'position:absolute;top:4px;right:4px;padding:2px 8px;font-size:11px;background:#4ecdc4;border:none;border-radius:4px;color:#1a1a2e;cursor:pointer;opacity:0.7;transition:opacity 0.2s;';\n btn.onmouseover = function() { this.style.opacity = '1'; };\n btn.onmouseout = function() { this.style.opacity = '0.7'; };\n btn.onclick = function() {\n navigator.clipboard.writeText(codeBlock.textContent).then(function() {\n btn.textContent = 'Copied!';\n setTimeout(function() { btn.textContent = 'Copy'; }, 1500);\n });\n };\n codeBlock.parentElement.style.position = 'relative';\n codeBlock.parentElement.appendChild(btn);\n });\n }\n \n addCopyButtons();\n \n // Re-run on dynamic content\n var observer = new MutationObserver(addCopyButtons);\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "Add Copy Buttons to Code Blocks");
}
} catch(__e) { console.warn('[Userscript:Add Copy Buttons to Code Blocks]', __e); }
})();
(function(){
try {
var __m = "github.com";
var __re = new RegExp('^' + "github\\.com" + '
Skip to content
Closed
Show file tree
Hide file tree
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
4 changes: 3 additions & 1 deletion .github/workflows/r.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -405,7 +405,9 @@ jobs:
)
# we use pak for package installation since it is faster, safer and more convenient
pak::local_install()
pak::pak("lintr")
# Pin the lintr version to avoid breaking changes with newer 3.2.0 version
# See: https://github.com/apache/arrow/pull/45524
pak::pak("lintr@3.1.2")
lintr::expect_lint_free()
- name: Dump install logs
shell: cmd
Expand Down
1 change: 1 addition & 0 deletions ci/docker/linux-apt-lint.dockerfile
Original file line numberDiff line numberDiff line change
Expand Up@@ -58,6 +58,7 @@ RUN cat /arrow/ci/etc/rprofile >> $(R RHOME)/etc/Rprofile.site
RUN echo "MAKEFLAGS=-j$(R -s -e 'cat(parallel::detectCores())')" >> $(R RHOME)/etc/Renviron.site
# We don't need arrow's dependencies, only lintr (and its dependencies)
RUN R -e "install.packages('lintr')"
RUN R -e "install.packages('cyclocomp')"

# Docker linter
COPY --from=hadolint /bin/hadolint /usr/bin/hadolint
Expand Down
4 changes: 3 additions & 1 deletion ci/scripts/r_test.sh
Original file line numberDiff line numberDiff line change
Expand Up@@ -91,7 +91,9 @@ export TEXMFVAR=/tmp/texmf-var
BEFORE=$(ls -alh ~/)

SCRIPT="as_cran <- !identical(tolower(Sys.getenv('NOT_CRAN')), 'true')
if (as_cran) {
# generally will be false, but we can override it by setting SKIP_VIGNETTES=true
skip_vignettes <- identical(tolower(Sys.getenv('SKIP_VIGNETTES')), 'true')
if (as_cran && !skip_vignettes) {
args <- '--as-cran'
build_args <- character()
} else {
Expand Down
3 changes: 3 additions & 0 deletions cpp/src/arrow/vendored/datetime/README.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -23,6 +23,9 @@ of the above project.
The following changes are made:
- fix internal inclusion paths (from "date/xxx.h" to simply "xxx.h")
- enclose the `date` namespace inside the `arrow_vendored` namespace
- fix 4 declarations like `CONSTCD11 date::day operator "" _d(unsigned long long d) NOEXCEPT;`
to not have offending whitespace for modern clang:
`CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;`

## How to update

Expand Down
8 changes: 4 additions & 4 deletions cpp/src/arrow/vendored/datetime/date.h
Original file line numberDiff line numberDiff line change
Expand Up@@ -963,8 +963,8 @@ operator<<(std::basic_ostream<CharT, Traits>& os, const year_month_weekday_last&
inline namespace literals
{

CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;
CONSTCD11 date::year operator ""_y(unsigned long long y) NOEXCEPT;
CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;
CONSTCD11 date::year operator ""_y(unsigned long long y) NOEXCEPT;

} // inline namespace literals
#endif // !defined(_MSC_VER) || (_MSC_VER >= 1900)
Expand DownExpand Up@@ -1972,15 +1972,15 @@ inline namespace literals
CONSTCD11
inline
date::day
operator ""_d(unsigned long long d) NOEXCEPT
operator ""_d(unsigned long long d) NOEXCEPT
{
return date::day{static_cast<unsigned>(d)};
}

CONSTCD11
inline
date::year
operator ""_y(unsigned long long y) NOEXCEPT
operator ""_y(unsigned long long y) NOEXCEPT
{
return date::year(static_cast<int>(y));
}
Expand Down
2 changes: 2 additions & 0 deletions cpp/src/parquet/size_statistics.cc
Original file line numberDiff line numberDiff line change
Expand Up@@ -18,9 +18,11 @@
#include "parquet/size_statistics.h"

#include <algorithm>
#include <array>
#include <numeric>
#include <ostream>
#include <string_view>
#include <vector>

#include "arrow/util/logging.h"
#include "parquet/exception.h"
Expand Down
21 changes: 11 additions & 10 deletions dev/tasks/r/github.linux.cran.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -21,20 +21,21 @@

jobs:
as-cran:
name: "rhub/{{ MATRIX }}"
name: "rhub/{{ '${{ matrix.config.r_image }}' }}"
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
# See https://hub.docker.com/r/rhub
r_image:
- ubuntu-gcc12 # ~ r-devel-linux-x86_64-debian-gcc
- ubuntu-clang # ~ r-devel-linux-x86_64-debian-clang
- ubuntu-next # ~ r-patched-linux-x86_64
- ubuntu-release # ~ r-release-linux-x86_64
config:
# See https://r-hub.github.io/containers/
- { r_image: "ubuntu-gcc12" } # ~ r-devel-linux-x86_64-debian-gcc
- { r_image: "ubuntu-clang" } # ~ r-devel-linux-x86_64-debian-clang
- { r_image: "ubuntu-next" } # ~ r-patched-linux-x86_64
- { r_image: "ubuntu-release" } # ~ r-release-linux-x86_64
- { r_image: "clang20", skip_vignettes: true } # ~ r-devel-linux-x86_64-fedora-clang
env:
R_ORG: "rhub"
R_IMAGE: {{ MATRIX }}
R_IMAGE: {{ '${{ matrix.config.r_image }}' }}
R_TAG: "latest"
ARROW_R_DEV: "FALSE"
steps:
Expand All@@ -46,7 +47,7 @@ jobs:
env:
{{ macros.github_set_sccache_envvars()|indent(8)}}
# setting ARROW_SOURCE_HOME='' here ensures that we use the cpp source copied into tools/
run: archery docker run -e ARROW_SOURCE_HOME='' r
run: archery docker run -e ARROW_SOURCE_HOME='' -e SKIP_VIGNETTES={{ '${{ matrix.config.skip_vignettes }}' }} r
- name: Dump install logs
run: cat arrow/r/check/arrow.Rcheck/00install.out
if: always()
Expand All@@ -57,5 +58,5 @@ jobs:
if: always()
uses: actions/upload-artifact@v4
with:
name: test-output-{{ "${{ matrix.r_image }}" }}
name: test-output-{{ "${{ matrix.config.r_image }}" }}
path: arrow/r/check/arrow.Rcheck/tests/testthat.Rout*
2 changes: 0 additions & 2 deletions dev/tasks/tasks.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -1198,8 +1198,6 @@ tasks:
test-r-linux-as-cran:
ci: github
template: r/github.linux.cran.yml
params:
MATRIX: {{ "${{ matrix.r_image }}" }}

test-r-macos-as-cran:
ci: github
Expand Down
9 changes: 9 additions & 0 deletions r/NEWS.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -19,6 +19,15 @@

# arrow 19.0.1

This release primarily updates the underlying Arrow C++ version used by the
package to version 19.0.1 and includes all changes from the 19.0.0 and 19.0.1
releases. For what's changed in Arrow C++ 19.0.0, please see the [blog
post](https://arrow.apache.org/blog/2025/01/16/19.0.0-release/) and
[changelog](https://arrow.apache.org/release/19.0.0.html#changelog).
For what's changed in Arrow C++ 19.0.1, please see the [blog
post](https://arrow.apache.org/blog/2025/02/16/19.0.1-release/) and
[changelog](https://arrow.apache.org/release/19.0.1.html#changelog).

# arrow 18.1.0

## Minor improvements and fixes
Expand Down
32 changes: 25 additions & 7 deletions r/R/dplyr-funcs-agg.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -150,13 +150,7 @@ register_bindings_aggregate <- function() {
options = list(skip_nulls = na.rm, min_count = 0L)
)
})
register_binding("arrow::one", function(...) {
set_agg(
fun = "one",
data = ensure_one_arg(list2(...), "one"),
options = list()
)
})
register_binding("arrow::one", one)
}

set_agg <- function(...) {
Expand DownExpand Up@@ -194,6 +188,30 @@ find_arrow_mask <- function() {
n <- n + 1
}
}
#' Get one value from each group
#'
#' Returns one arbitrary value from the input for each group. The function is
#' biased towards non-null values: if there is at least one non-null value for a
#' certain group, that value is returned, and only if all the values are null
#' for the group will the function return null.
#'
#' @param ... Unquoted column name to pull values from.
#'
#' @examples
#' \dontrun{
#' mtcars |>
#' arrow_table() |>
#' group_by(cyl) |>
#' summarize(x = one(disp))
#' }
#' @keywords internal
one <- function(...) {
set_agg(
fun = "one",
data = ensure_one_arg(list2(...), "one"),
options = list()
)
}

ensure_one_arg <- function(args, fun) {
if (length(args) == 0) {
Expand Down
7 changes: 4 additions & 3 deletions r/R/dplyr-funcs-doc.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -21,7 +21,7 @@
#'
#' The `arrow` package contains methods for 37 `dplyr` table functions, many of
#' which are "verbs" that do transformations to one or more tables.
#' The package also has mappings of 212 R functions to the corresponding
#' The package also has mappings of 213 R functions to the corresponding
#' functions in the Arrow compute library. These allow you to write code inside
#' of `dplyr` methods that call R functions, including many in packages like
#' `stringr` and `lubridate`, and they will get translated to Arrow and run
Expand All@@ -42,7 +42,7 @@
#' * [`collect()`][dplyr::collect()]
#' * [`compute()`][dplyr::compute()]
#' * [`count()`][dplyr::count()]
#' * [`distinct()`][dplyr::distinct()]: `.keep_all = TRUE` not supported
#' * [`distinct()`][dplyr::distinct()]: `.keep_all = TRUE` returns a non-missing value if present, only returning missing values if all are missing.
#' * [`explain()`][dplyr::explain()]
#' * [`filter()`][dplyr::filter()]
#' * [`full_join()`][dplyr::full_join()]: the `copy` argument is ignored
Expand DownExpand Up@@ -83,7 +83,7 @@
#' Functions can be called either as `pkg::fun()` or just `fun()`, i.e. both
#' `str_sub()` and `stringr::str_sub()` work.
#'
#' In addition to these functions, you can call any of Arrow's 262 compute
#' In addition to these functions, you can call any of Arrow's 271 compute
#' functions directly. Arrow has many functions that don't map to an existing R
#' function. In other cases where there is an R function mapping, you can still
#' call the Arrow function directly if you don't want the adaptations that the R
Expand All@@ -96,6 +96,7 @@
#'
#' * [`add_filename()`][arrow::add_filename()]
#' * [`cast()`][arrow::cast()]
#' * [`one()`][arrow::one()]
#'
#' ## base
#'
Expand Down
9 changes: 0 additions & 9 deletions r/README.md
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,5 @@
# arrow <img src="https://arrow.apache.org/img/arrow-logo_hex_black-txt_white-bg.png" align="right" alt="" width="120" />

<!-- badges: start -->

[![cran](https://www.r-pkg.org/badges/version-last-release/arrow)](https://cran.r-project.org/package=arrow)
[![CI](https://github.com/apache/arrow/workflows/R/badge.svg?event=push)](https://github.com/apache/arrow/actions?query=workflow%3AR+branch%3Amain+event%3Apush)
[![R-universe status badge](https://apache.r-universe.dev/badges/arrow)](https://apache.r-universe.dev)
[![conda-forge](https://img.shields.io/conda/vn/conda-forge/r-arrow.svg)](https://anaconda.org/conda-forge/r-arrow)

<!-- badges: end -->

## Overview

The R `{arrow}` package provides access to many of the features of the [Apache Arrow C++ library](https://arrow.apache.org/docs/cpp/index.html) for R users. The goal of arrow is to provide an Arrow C++ backend to `{dplyr}`, and access to the Arrow C++ library through familiar base R and tidyverse functions, or `{R6}` classes. The dedicated R package website is located [here](https://arrow.apache.org/docs/r/index.html).
Expand Down
7 changes: 4 additions & 3 deletions r/man/acero.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

26 changes: 26 additions & 0 deletions r/man/one.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion r/src/filesystem.cpp
Original file line numberDiff line numberDiff line change
Expand Up@@ -258,7 +258,7 @@ std::string fs___SubTreeFileSystem__base_path(

// [[arrow::export]]
cpp11::writable::list fs___FileSystemFromUri(const std::string& path) {
using cpp11::literals::operator""_nm;
using cpp11::literals::operator""_nm;

std::string out_path;
auto io_context = MainRThread::GetInstance().CancellableIOContext();
Expand Down
8 changes: 4 additions & 4 deletions r/tools/nixlibs.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -84,10 +84,10 @@ try_download <- function(from_url, to_file, hush = quietly) {
return(FALSE)
}
# We download some fairly large files, so ensure the timeout is set appropriately.
# This assumes a static library size of 100 MB (generous) and a download speed
# of .3 MB/s (slow). This is to anticipate slower user connections or load on
# artifactory servers.
opts <- options(timeout = max(300, getOption("timeout")))
# This assumes a static library size of 100 MB (our current biggest is 78 MB) and
# a download speed of 0.2 MB/s (slow). This is to anticipate slower user connections
# or load on artifactory servers.
opts <- options(timeout = max(600, getOption("timeout")))
on.exit(options(opts))

status <- try(
Expand Down
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Force GitHub README to respect dark mode\n(function() {\n var style = document.createElement('style');\n style.textContent = '\n .markdown-body {\n color-scheme: dark light;\n }\n .markdown-body pre { background: #161b22 !important; }\n .markdown-body code { background: rgba(110, 118, 129, 0.4) !important; }\n .markdown-body table th, .markdown-body table td { border-color: #30363d !important; }\n .markdown-body img { background: #0d1117; }\n .markdown-body blockquote { border-left-color: #8b949e; }\n .markdown-body hr { border-color: #30363d; }\n ';\n document.head.appendChild(style);\n})();", "GitHub Dark Mode README Fix"); } } catch(__e) { console.warn('[Userscript:GitHub Dark Mode README Fix]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content
Closed
Show file tree
Hide file tree
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
4 changes: 3 additions & 1 deletion .github/workflows/r.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -405,7 +405,9 @@ jobs:
)
# we use pak for package installation since it is faster, safer and more convenient
pak::local_install()
pak::pak("lintr")
# Pin the lintr version to avoid breaking changes with newer 3.2.0 version
# See: https://github.com/apache/arrow/pull/45524
pak::pak("lintr@3.1.2")
lintr::expect_lint_free()
- name: Dump install logs
shell: cmd
Expand Down
1 change: 1 addition & 0 deletions ci/docker/linux-apt-lint.dockerfile
Original file line numberDiff line numberDiff line change
Expand Up@@ -58,6 +58,7 @@ RUN cat /arrow/ci/etc/rprofile >> $(R RHOME)/etc/Rprofile.site
RUN echo "MAKEFLAGS=-j$(R -s -e 'cat(parallel::detectCores())')" >> $(R RHOME)/etc/Renviron.site
# We don't need arrow's dependencies, only lintr (and its dependencies)
RUN R -e "install.packages('lintr')"
RUN R -e "install.packages('cyclocomp')"

# Docker linter
COPY --from=hadolint /bin/hadolint /usr/bin/hadolint
Expand Down
4 changes: 3 additions & 1 deletion ci/scripts/r_test.sh
Original file line numberDiff line numberDiff line change
Expand Up@@ -91,7 +91,9 @@ export TEXMFVAR=/tmp/texmf-var
BEFORE=$(ls -alh ~/)

SCRIPT="as_cran <- !identical(tolower(Sys.getenv('NOT_CRAN')), 'true')
if (as_cran) {
# generally will be false, but we can override it by setting SKIP_VIGNETTES=true
skip_vignettes <- identical(tolower(Sys.getenv('SKIP_VIGNETTES')), 'true')
if (as_cran && !skip_vignettes) {
args <- '--as-cran'
build_args <- character()
} else {
Expand Down
3 changes: 3 additions & 0 deletions cpp/src/arrow/vendored/datetime/README.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -23,6 +23,9 @@ of the above project.
The following changes are made:
- fix internal inclusion paths (from "date/xxx.h" to simply "xxx.h")
- enclose the `date` namespace inside the `arrow_vendored` namespace
- fix 4 declarations like `CONSTCD11 date::day operator "" _d(unsigned long long d) NOEXCEPT;`
to not have offending whitespace for modern clang:
`CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;`

## How to update

Expand Down
8 changes: 4 additions & 4 deletions cpp/src/arrow/vendored/datetime/date.h
Original file line numberDiff line numberDiff line change
Expand Up@@ -963,8 +963,8 @@ operator<<(std::basic_ostream<CharT, Traits>& os, const year_month_weekday_last&
inline namespace literals
{

CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;
CONSTCD11 date::year operator ""_y(unsigned long long y) NOEXCEPT;
CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;
CONSTCD11 date::year operator ""_y(unsigned long long y) NOEXCEPT;

} // inline namespace literals
#endif // !defined(_MSC_VER) || (_MSC_VER >= 1900)
Expand DownExpand Up@@ -1972,15 +1972,15 @@ inline namespace literals
CONSTCD11
inline
date::day
operator ""_d(unsigned long long d) NOEXCEPT
operator ""_d(unsigned long long d) NOEXCEPT
{
return date::day{static_cast<unsigned>(d)};
}

CONSTCD11
inline
date::year
operator ""_y(unsigned long long y) NOEXCEPT
operator ""_y(unsigned long long y) NOEXCEPT
{
return date::year(static_cast<int>(y));
}
Expand Down
2 changes: 2 additions & 0 deletions cpp/src/parquet/size_statistics.cc
Original file line numberDiff line numberDiff line change
Expand Up@@ -18,9 +18,11 @@
#include "parquet/size_statistics.h"

#include <algorithm>
#include <array>
#include <numeric>
#include <ostream>
#include <string_view>
#include <vector>

#include "arrow/util/logging.h"
#include "parquet/exception.h"
Expand Down
21 changes: 11 additions & 10 deletions dev/tasks/r/github.linux.cran.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -21,20 +21,21 @@

jobs:
as-cran:
name: "rhub/{{ MATRIX }}"
name: "rhub/{{ '${{ matrix.config.r_image }}' }}"
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
# See https://hub.docker.com/r/rhub
r_image:
- ubuntu-gcc12 # ~ r-devel-linux-x86_64-debian-gcc
- ubuntu-clang # ~ r-devel-linux-x86_64-debian-clang
- ubuntu-next # ~ r-patched-linux-x86_64
- ubuntu-release # ~ r-release-linux-x86_64
config:
# See https://r-hub.github.io/containers/
- { r_image: "ubuntu-gcc12" } # ~ r-devel-linux-x86_64-debian-gcc
- { r_image: "ubuntu-clang" } # ~ r-devel-linux-x86_64-debian-clang
- { r_image: "ubuntu-next" } # ~ r-patched-linux-x86_64
- { r_image: "ubuntu-release" } # ~ r-release-linux-x86_64
- { r_image: "clang20", skip_vignettes: true } # ~ r-devel-linux-x86_64-fedora-clang
env:
R_ORG: "rhub"
R_IMAGE: {{ MATRIX }}
R_IMAGE: {{ '${{ matrix.config.r_image }}' }}
R_TAG: "latest"
ARROW_R_DEV: "FALSE"
steps:
Expand All@@ -46,7 +47,7 @@ jobs:
env:
{{ macros.github_set_sccache_envvars()|indent(8)}}
# setting ARROW_SOURCE_HOME='' here ensures that we use the cpp source copied into tools/
run: archery docker run -e ARROW_SOURCE_HOME='' r
run: archery docker run -e ARROW_SOURCE_HOME='' -e SKIP_VIGNETTES={{ '${{ matrix.config.skip_vignettes }}' }} r
- name: Dump install logs
run: cat arrow/r/check/arrow.Rcheck/00install.out
if: always()
Expand All@@ -57,5 +58,5 @@ jobs:
if: always()
uses: actions/upload-artifact@v4
with:
name: test-output-{{ "${{ matrix.r_image }}" }}
name: test-output-{{ "${{ matrix.config.r_image }}" }}
path: arrow/r/check/arrow.Rcheck/tests/testthat.Rout*
2 changes: 0 additions & 2 deletions dev/tasks/tasks.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -1198,8 +1198,6 @@ tasks:
test-r-linux-as-cran:
ci: github
template: r/github.linux.cran.yml
params:
MATRIX: {{ "${{ matrix.r_image }}" }}

test-r-macos-as-cran:
ci: github
Expand Down
9 changes: 9 additions & 0 deletions r/NEWS.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -19,6 +19,15 @@

# arrow 19.0.1

This release primarily updates the underlying Arrow C++ version used by the
package to version 19.0.1 and includes all changes from the 19.0.0 and 19.0.1
releases. For what's changed in Arrow C++ 19.0.0, please see the [blog
post](https://arrow.apache.org/blog/2025/01/16/19.0.0-release/) and
[changelog](https://arrow.apache.org/release/19.0.0.html#changelog).
For what's changed in Arrow C++ 19.0.1, please see the [blog
post](https://arrow.apache.org/blog/2025/02/16/19.0.1-release/) and
[changelog](https://arrow.apache.org/release/19.0.1.html#changelog).

# arrow 18.1.0

## Minor improvements and fixes
Expand Down
32 changes: 25 additions & 7 deletions r/R/dplyr-funcs-agg.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -150,13 +150,7 @@ register_bindings_aggregate <- function() {
options = list(skip_nulls = na.rm, min_count = 0L)
)
})
register_binding("arrow::one", function(...) {
set_agg(
fun = "one",
data = ensure_one_arg(list2(...), "one"),
options = list()
)
})
register_binding("arrow::one", one)
}

set_agg <- function(...) {
Expand DownExpand Up@@ -194,6 +188,30 @@ find_arrow_mask <- function() {
n <- n + 1
}
}
#' Get one value from each group
#'
#' Returns one arbitrary value from the input for each group. The function is
#' biased towards non-null values: if there is at least one non-null value for a
#' certain group, that value is returned, and only if all the values are null
#' for the group will the function return null.
#'
#' @param ... Unquoted column name to pull values from.
#'
#' @examples
#' \dontrun{
#' mtcars |>
#' arrow_table() |>
#' group_by(cyl) |>
#' summarize(x = one(disp))
#' }
#' @keywords internal
one <- function(...) {
set_agg(
fun = "one",
data = ensure_one_arg(list2(...), "one"),
options = list()
)
}

ensure_one_arg <- function(args, fun) {
if (length(args) == 0) {
Expand Down
7 changes: 4 additions & 3 deletions r/R/dplyr-funcs-doc.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -21,7 +21,7 @@
#'
#' The `arrow` package contains methods for 37 `dplyr` table functions, many of
#' which are "verbs" that do transformations to one or more tables.
#' The package also has mappings of 212 R functions to the corresponding
#' The package also has mappings of 213 R functions to the corresponding
#' functions in the Arrow compute library. These allow you to write code inside
#' of `dplyr` methods that call R functions, including many in packages like
#' `stringr` and `lubridate`, and they will get translated to Arrow and run
Expand All@@ -42,7 +42,7 @@
#' * [`collect()`][dplyr::collect()]
#' * [`compute()`][dplyr::compute()]
#' * [`count()`][dplyr::count()]
#' * [`distinct()`][dplyr::distinct()]: `.keep_all = TRUE` not supported
#' * [`distinct()`][dplyr::distinct()]: `.keep_all = TRUE` returns a non-missing value if present, only returning missing values if all are missing.
#' * [`explain()`][dplyr::explain()]
#' * [`filter()`][dplyr::filter()]
#' * [`full_join()`][dplyr::full_join()]: the `copy` argument is ignored
Expand DownExpand Up@@ -83,7 +83,7 @@
#' Functions can be called either as `pkg::fun()` or just `fun()`, i.e. both
#' `str_sub()` and `stringr::str_sub()` work.
#'
#' In addition to these functions, you can call any of Arrow's 262 compute
#' In addition to these functions, you can call any of Arrow's 271 compute
#' functions directly. Arrow has many functions that don't map to an existing R
#' function. In other cases where there is an R function mapping, you can still
#' call the Arrow function directly if you don't want the adaptations that the R
Expand All@@ -96,6 +96,7 @@
#'
#' * [`add_filename()`][arrow::add_filename()]
#' * [`cast()`][arrow::cast()]
#' * [`one()`][arrow::one()]
#'
#' ## base
#'
Expand Down
9 changes: 0 additions & 9 deletions r/README.md
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,5 @@
# arrow <img src="https://arrow.apache.org/img/arrow-logo_hex_black-txt_white-bg.png" align="right" alt="" width="120" />

<!-- badges: start -->

[![cran](https://www.r-pkg.org/badges/version-last-release/arrow)](https://cran.r-project.org/package=arrow)
[![CI](https://github.com/apache/arrow/workflows/R/badge.svg?event=push)](https://github.com/apache/arrow/actions?query=workflow%3AR+branch%3Amain+event%3Apush)
[![R-universe status badge](https://apache.r-universe.dev/badges/arrow)](https://apache.r-universe.dev)
[![conda-forge](https://img.shields.io/conda/vn/conda-forge/r-arrow.svg)](https://anaconda.org/conda-forge/r-arrow)

<!-- badges: end -->

## Overview

The R `{arrow}` package provides access to many of the features of the [Apache Arrow C++ library](https://arrow.apache.org/docs/cpp/index.html) for R users. The goal of arrow is to provide an Arrow C++ backend to `{dplyr}`, and access to the Arrow C++ library through familiar base R and tidyverse functions, or `{R6}` classes. The dedicated R package website is located [here](https://arrow.apache.org/docs/r/index.html).
Expand Down
7 changes: 4 additions & 3 deletions r/man/acero.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

26 changes: 26 additions & 0 deletions r/man/one.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion r/src/filesystem.cpp
Original file line numberDiff line numberDiff line change
Expand Up@@ -258,7 +258,7 @@ std::string fs___SubTreeFileSystem__base_path(

// [[arrow::export]]
cpp11::writable::list fs___FileSystemFromUri(const std::string& path) {
using cpp11::literals::operator""_nm;
using cpp11::literals::operator""_nm;

std::string out_path;
auto io_context = MainRThread::GetInstance().CancellableIOContext();
Expand Down
8 changes: 4 additions & 4 deletions r/tools/nixlibs.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -84,10 +84,10 @@ try_download <- function(from_url, to_file, hush = quietly) {
return(FALSE)
}
# We download some fairly large files, so ensure the timeout is set appropriately.
# This assumes a static library size of 100 MB (generous) and a download speed
# of .3 MB/s (slow). This is to anticipate slower user connections or load on
# artifactory servers.
opts <- options(timeout = max(300, getOption("timeout")))
# This assumes a static library size of 100 MB (our current biggest is 78 MB) and
# a download speed of 0.2 MB/s (slow). This is to anticipate slower user connections
# or load on artifactory servers.
opts <- options(timeout = max(600, getOption("timeout")))
on.exit(options(opts))

status <- try(
Expand Down
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Highlight search terms from Google/DuckDuckGo/Bing referrer\n(function() {\n var ref = document.referrer;\n var terms = [];\n \n if (ref.includes('google.com') || ref.includes('duckduckgo.com') || ref.includes('bing.com')) {\n var url = new URL(ref);\n var q = url.searchParams.get('q') || url.searchParams.get('p');\n if (q) {\n terms = q.split(/\\s+/).filter(function(t) { return t.length > 2; });\n }\n }\n \n if (terms.length === 0) return;\n \n var style = document.createElement('style');\n style.textContent = '.userscript-highlight { background: #fbbf24; color: #1a1a2e; padding: 1px 3px; border-radius: 2px; }';\n document.head.appendChild(style);\n \n function highlight(node) {\n if (node.nodeType === 3) { // text node\n var text = node.textContent;\n var found = false;\n terms.forEach(function(term) {\n var regex = new RegExp('(' + term.replace(/[.*+?^${}()|[\\]\\\\]/g, '\\\\') + ')', 'gi');\n if (regex.test(text)) {\n found = true;\n var frag = document.createDocumentFragment();\n var parts = text.split(regex);\n parts.forEach(function(part, i) {\n if (i % 2 === 0) {\n frag.appendChild(document.createTextNode(part));\n } else {\n var span = document.createElement('span');\n span.className = 'userscript-highlight';\n span.textContent = part;\n frag.appendChild(span);\n }\n });\n node.parentNode.replaceChild(frag, node);\n }\n });\n } else if (node.nodeType === 1 && node.childNodes) { // element\n var skipTags = ['SCRIPT', 'STYLE', 'NOSCRIPT', 'TEXTAREA', 'INPUT', 'SELECT'];\n if (!skipTags.includes(node.tagName)) {\n Array.from(node.childNodes).forEach(highlight);\n }\n }\n }\n \n highlight(document.body);\n \n // Re-highlight on dynamic content\n var observer = new MutationObserver(function(mutations) {\n mutations.forEach(function(m) {\n m.addedNodes.forEach(function(node) {\n if (node.nodeType === 1 || node.nodeType === 3) highlight(node);\n });\n });\n });\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "Highlight Search Terms"); } } catch(__e) { console.warn('[Userscript:Highlight Search Terms]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content
Closed
Show file tree
Hide file tree
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
4 changes: 3 additions & 1 deletion .github/workflows/r.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -405,7 +405,9 @@ jobs:
)
# we use pak for package installation since it is faster, safer and more convenient
pak::local_install()
pak::pak("lintr")
# Pin the lintr version to avoid breaking changes with newer 3.2.0 version
# See: https://github.com/apache/arrow/pull/45524
pak::pak("lintr@3.1.2")
lintr::expect_lint_free()
- name: Dump install logs
shell: cmd
Expand Down
1 change: 1 addition & 0 deletions ci/docker/linux-apt-lint.dockerfile
Original file line numberDiff line numberDiff line change
Expand Up@@ -58,6 +58,7 @@ RUN cat /arrow/ci/etc/rprofile >> $(R RHOME)/etc/Rprofile.site
RUN echo "MAKEFLAGS=-j$(R -s -e 'cat(parallel::detectCores())')" >> $(R RHOME)/etc/Renviron.site
# We don't need arrow's dependencies, only lintr (and its dependencies)
RUN R -e "install.packages('lintr')"
RUN R -e "install.packages('cyclocomp')"

# Docker linter
COPY --from=hadolint /bin/hadolint /usr/bin/hadolint
Expand Down
4 changes: 3 additions & 1 deletion ci/scripts/r_test.sh
Original file line numberDiff line numberDiff line change
Expand Up@@ -91,7 +91,9 @@ export TEXMFVAR=/tmp/texmf-var
BEFORE=$(ls -alh ~/)

SCRIPT="as_cran <- !identical(tolower(Sys.getenv('NOT_CRAN')), 'true')
if (as_cran) {
# generally will be false, but we can override it by setting SKIP_VIGNETTES=true
skip_vignettes <- identical(tolower(Sys.getenv('SKIP_VIGNETTES')), 'true')
if (as_cran && !skip_vignettes) {
args <- '--as-cran'
build_args <- character()
} else {
Expand Down
3 changes: 3 additions & 0 deletions cpp/src/arrow/vendored/datetime/README.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -23,6 +23,9 @@ of the above project.
The following changes are made:
- fix internal inclusion paths (from "date/xxx.h" to simply "xxx.h")
- enclose the `date` namespace inside the `arrow_vendored` namespace
- fix 4 declarations like `CONSTCD11 date::day operator "" _d(unsigned long long d) NOEXCEPT;`
to not have offending whitespace for modern clang:
`CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;`

## How to update

Expand Down
8 changes: 4 additions & 4 deletions cpp/src/arrow/vendored/datetime/date.h
Original file line numberDiff line numberDiff line change
Expand Up@@ -963,8 +963,8 @@ operator<<(std::basic_ostream<CharT, Traits>& os, const year_month_weekday_last&
inline namespace literals
{

CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;
CONSTCD11 date::year operator ""_y(unsigned long long y) NOEXCEPT;
CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;
CONSTCD11 date::year operator ""_y(unsigned long long y) NOEXCEPT;

} // inline namespace literals
#endif // !defined(_MSC_VER) || (_MSC_VER >= 1900)
Expand DownExpand Up@@ -1972,15 +1972,15 @@ inline namespace literals
CONSTCD11
inline
date::day
operator ""_d(unsigned long long d) NOEXCEPT
operator ""_d(unsigned long long d) NOEXCEPT
{
return date::day{static_cast<unsigned>(d)};
}

CONSTCD11
inline
date::year
operator ""_y(unsigned long long y) NOEXCEPT
operator ""_y(unsigned long long y) NOEXCEPT
{
return date::year(static_cast<int>(y));
}
Expand Down
2 changes: 2 additions & 0 deletions cpp/src/parquet/size_statistics.cc
Original file line numberDiff line numberDiff line change
Expand Up@@ -18,9 +18,11 @@
#include "parquet/size_statistics.h"

#include <algorithm>
#include <array>
#include <numeric>
#include <ostream>
#include <string_view>
#include <vector>

#include "arrow/util/logging.h"
#include "parquet/exception.h"
Expand Down
21 changes: 11 additions & 10 deletions dev/tasks/r/github.linux.cran.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -21,20 +21,21 @@

jobs:
as-cran:
name: "rhub/{{ MATRIX }}"
name: "rhub/{{ '${{ matrix.config.r_image }}' }}"
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
# See https://hub.docker.com/r/rhub
r_image:
- ubuntu-gcc12 # ~ r-devel-linux-x86_64-debian-gcc
- ubuntu-clang # ~ r-devel-linux-x86_64-debian-clang
- ubuntu-next # ~ r-patched-linux-x86_64
- ubuntu-release # ~ r-release-linux-x86_64
config:
# See https://r-hub.github.io/containers/
- { r_image: "ubuntu-gcc12" } # ~ r-devel-linux-x86_64-debian-gcc
- { r_image: "ubuntu-clang" } # ~ r-devel-linux-x86_64-debian-clang
- { r_image: "ubuntu-next" } # ~ r-patched-linux-x86_64
- { r_image: "ubuntu-release" } # ~ r-release-linux-x86_64
- { r_image: "clang20", skip_vignettes: true } # ~ r-devel-linux-x86_64-fedora-clang
env:
R_ORG: "rhub"
R_IMAGE: {{ MATRIX }}
R_IMAGE: {{ '${{ matrix.config.r_image }}' }}
R_TAG: "latest"
ARROW_R_DEV: "FALSE"
steps:
Expand All@@ -46,7 +47,7 @@ jobs:
env:
{{ macros.github_set_sccache_envvars()|indent(8)}}
# setting ARROW_SOURCE_HOME='' here ensures that we use the cpp source copied into tools/
run: archery docker run -e ARROW_SOURCE_HOME='' r
run: archery docker run -e ARROW_SOURCE_HOME='' -e SKIP_VIGNETTES={{ '${{ matrix.config.skip_vignettes }}' }} r
- name: Dump install logs
run: cat arrow/r/check/arrow.Rcheck/00install.out
if: always()
Expand All@@ -57,5 +58,5 @@ jobs:
if: always()
uses: actions/upload-artifact@v4
with:
name: test-output-{{ "${{ matrix.r_image }}" }}
name: test-output-{{ "${{ matrix.config.r_image }}" }}
path: arrow/r/check/arrow.Rcheck/tests/testthat.Rout*
2 changes: 0 additions & 2 deletions dev/tasks/tasks.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -1198,8 +1198,6 @@ tasks:
test-r-linux-as-cran:
ci: github
template: r/github.linux.cran.yml
params:
MATRIX: {{ "${{ matrix.r_image }}" }}

test-r-macos-as-cran:
ci: github
Expand Down
9 changes: 9 additions & 0 deletions r/NEWS.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -19,6 +19,15 @@

# arrow 19.0.1

This release primarily updates the underlying Arrow C++ version used by the
package to version 19.0.1 and includes all changes from the 19.0.0 and 19.0.1
releases. For what's changed in Arrow C++ 19.0.0, please see the [blog
post](https://arrow.apache.org/blog/2025/01/16/19.0.0-release/) and
[changelog](https://arrow.apache.org/release/19.0.0.html#changelog).
For what's changed in Arrow C++ 19.0.1, please see the [blog
post](https://arrow.apache.org/blog/2025/02/16/19.0.1-release/) and
[changelog](https://arrow.apache.org/release/19.0.1.html#changelog).

# arrow 18.1.0

## Minor improvements and fixes
Expand Down
32 changes: 25 additions & 7 deletions r/R/dplyr-funcs-agg.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -150,13 +150,7 @@ register_bindings_aggregate <- function() {
options = list(skip_nulls = na.rm, min_count = 0L)
)
})
register_binding("arrow::one", function(...) {
set_agg(
fun = "one",
data = ensure_one_arg(list2(...), "one"),
options = list()
)
})
register_binding("arrow::one", one)
}

set_agg <- function(...) {
Expand DownExpand Up@@ -194,6 +188,30 @@ find_arrow_mask <- function() {
n <- n + 1
}
}
#' Get one value from each group
#'
#' Returns one arbitrary value from the input for each group. The function is
#' biased towards non-null values: if there is at least one non-null value for a
#' certain group, that value is returned, and only if all the values are null
#' for the group will the function return null.
#'
#' @param ... Unquoted column name to pull values from.
#'
#' @examples
#' \dontrun{
#' mtcars |>
#' arrow_table() |>
#' group_by(cyl) |>
#' summarize(x = one(disp))
#' }
#' @keywords internal
one <- function(...) {
set_agg(
fun = "one",
data = ensure_one_arg(list2(...), "one"),
options = list()
)
}

ensure_one_arg <- function(args, fun) {
if (length(args) == 0) {
Expand Down
7 changes: 4 additions & 3 deletions r/R/dplyr-funcs-doc.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -21,7 +21,7 @@
#'
#' The `arrow` package contains methods for 37 `dplyr` table functions, many of
#' which are "verbs" that do transformations to one or more tables.
#' The package also has mappings of 212 R functions to the corresponding
#' The package also has mappings of 213 R functions to the corresponding
#' functions in the Arrow compute library. These allow you to write code inside
#' of `dplyr` methods that call R functions, including many in packages like
#' `stringr` and `lubridate`, and they will get translated to Arrow and run
Expand All@@ -42,7 +42,7 @@
#' * [`collect()`][dplyr::collect()]
#' * [`compute()`][dplyr::compute()]
#' * [`count()`][dplyr::count()]
#' * [`distinct()`][dplyr::distinct()]: `.keep_all = TRUE` not supported
#' * [`distinct()`][dplyr::distinct()]: `.keep_all = TRUE` returns a non-missing value if present, only returning missing values if all are missing.
#' * [`explain()`][dplyr::explain()]
#' * [`filter()`][dplyr::filter()]
#' * [`full_join()`][dplyr::full_join()]: the `copy` argument is ignored
Expand DownExpand Up@@ -83,7 +83,7 @@
#' Functions can be called either as `pkg::fun()` or just `fun()`, i.e. both
#' `str_sub()` and `stringr::str_sub()` work.
#'
#' In addition to these functions, you can call any of Arrow's 262 compute
#' In addition to these functions, you can call any of Arrow's 271 compute
#' functions directly. Arrow has many functions that don't map to an existing R
#' function. In other cases where there is an R function mapping, you can still
#' call the Arrow function directly if you don't want the adaptations that the R
Expand All@@ -96,6 +96,7 @@
#'
#' * [`add_filename()`][arrow::add_filename()]
#' * [`cast()`][arrow::cast()]
#' * [`one()`][arrow::one()]
#'
#' ## base
#'
Expand Down
9 changes: 0 additions & 9 deletions r/README.md
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,5 @@
# arrow <img src="https://arrow.apache.org/img/arrow-logo_hex_black-txt_white-bg.png" align="right" alt="" width="120" />

<!-- badges: start -->

[![cran](https://www.r-pkg.org/badges/version-last-release/arrow)](https://cran.r-project.org/package=arrow)
[![CI](https://github.com/apache/arrow/workflows/R/badge.svg?event=push)](https://github.com/apache/arrow/actions?query=workflow%3AR+branch%3Amain+event%3Apush)
[![R-universe status badge](https://apache.r-universe.dev/badges/arrow)](https://apache.r-universe.dev)
[![conda-forge](https://img.shields.io/conda/vn/conda-forge/r-arrow.svg)](https://anaconda.org/conda-forge/r-arrow)

<!-- badges: end -->

## Overview

The R `{arrow}` package provides access to many of the features of the [Apache Arrow C++ library](https://arrow.apache.org/docs/cpp/index.html) for R users. The goal of arrow is to provide an Arrow C++ backend to `{dplyr}`, and access to the Arrow C++ library through familiar base R and tidyverse functions, or `{R6}` classes. The dedicated R package website is located [here](https://arrow.apache.org/docs/r/index.html).
Expand Down
7 changes: 4 additions & 3 deletions r/man/acero.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

26 changes: 26 additions & 0 deletions r/man/one.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion r/src/filesystem.cpp
Original file line numberDiff line numberDiff line change
Expand Up@@ -258,7 +258,7 @@ std::string fs___SubTreeFileSystem__base_path(

// [[arrow::export]]
cpp11::writable::list fs___FileSystemFromUri(const std::string& path) {
using cpp11::literals::operator""_nm;
using cpp11::literals::operator""_nm;

std::string out_path;
auto io_context = MainRThread::GetInstance().CancellableIOContext();
Expand Down
8 changes: 4 additions & 4 deletions r/tools/nixlibs.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -84,10 +84,10 @@ try_download <- function(from_url, to_file, hush = quietly) {
return(FALSE)
}
# We download some fairly large files, so ensure the timeout is set appropriately.
# This assumes a static library size of 100 MB (generous) and a download speed
# of .3 MB/s (slow). This is to anticipate slower user connections or load on
# artifactory servers.
opts <- options(timeout = max(300, getOption("timeout")))
# This assumes a static library size of 100 MB (our current biggest is 78 MB) and
# a download speed of 0.2 MB/s (slow). This is to anticipate slower user connections
# or load on artifactory servers.
opts <- options(timeout = max(600, getOption("timeout")))
on.exit(options(opts))

status <- try(
Expand Down
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Strip utm_, fbclid, gclid, etc. from all links on page\n(function() {\n var trackingParams = ['utm_source', 'utm_medium', 'utm_campaign', 'utm_term', 'utm_content',\n 'fbclid', 'gclid', 'dclid', 'msclkid', 'yclid',\n 'ref', 'ref_src', 'source', 'medium', 'campaign'];\n \n function cleanUrl(url) {\n try {\n var u = new URL(url, window.location.origin);\n var changed = false;\n trackingParams.forEach(function(p) {\n if (u.searchParams.has(p)) {\n u.searchParams.delete(p);\n changed = true;\n }\n });\n return changed ? u.toString() : url;\n } catch (e) {\n return url;\n }\n }\n \n function cleanLinks() {\n document.querySelectorAll('a[href]').forEach(function(a) {\n var clean = cleanUrl(a.href);\n if (clean !== a.href) a.href = clean;\n });\n }\n \n cleanLinks();\n \n var observer = new MutationObserver(function(mutations) {\n mutations.forEach(function(m) {\n m.addedNodes.forEach(function(node) {\n if (node.nodeType === 1) {\n if (node.tagName === 'A') cleanLinks();\n node.querySelectorAll('a[href]').forEach(function(a) {\n var clean = cleanUrl(a.href);\n if (clean !== a.href) a.href = clean;\n });\n }\n });\n });\n });\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "Remove Tracking Parameters from Links"); } } catch(__e) { console.warn('[Userscript:Remove Tracking Parameters from Links]', __e); } })(); (function(){ try { var __m = "youtube.com"; var __re = new RegExp('^' + "youtube\\.com" + '
Skip to content
Closed
Show file tree
Hide file tree
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
4 changes: 3 additions & 1 deletion .github/workflows/r.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -405,7 +405,9 @@ jobs:
)
# we use pak for package installation since it is faster, safer and more convenient
pak::local_install()
pak::pak("lintr")
# Pin the lintr version to avoid breaking changes with newer 3.2.0 version
# See: https://github.com/apache/arrow/pull/45524
pak::pak("lintr@3.1.2")
lintr::expect_lint_free()
- name: Dump install logs
shell: cmd
Expand Down
1 change: 1 addition & 0 deletions ci/docker/linux-apt-lint.dockerfile
Original file line numberDiff line numberDiff line change
Expand Up@@ -58,6 +58,7 @@ RUN cat /arrow/ci/etc/rprofile >> $(R RHOME)/etc/Rprofile.site
RUN echo "MAKEFLAGS=-j$(R -s -e 'cat(parallel::detectCores())')" >> $(R RHOME)/etc/Renviron.site
# We don't need arrow's dependencies, only lintr (and its dependencies)
RUN R -e "install.packages('lintr')"
RUN R -e "install.packages('cyclocomp')"

# Docker linter
COPY --from=hadolint /bin/hadolint /usr/bin/hadolint
Expand Down
4 changes: 3 additions & 1 deletion ci/scripts/r_test.sh
Original file line numberDiff line numberDiff line change
Expand Up@@ -91,7 +91,9 @@ export TEXMFVAR=/tmp/texmf-var
BEFORE=$(ls -alh ~/)

SCRIPT="as_cran <- !identical(tolower(Sys.getenv('NOT_CRAN')), 'true')
if (as_cran) {
# generally will be false, but we can override it by setting SKIP_VIGNETTES=true
skip_vignettes <- identical(tolower(Sys.getenv('SKIP_VIGNETTES')), 'true')
if (as_cran && !skip_vignettes) {
args <- '--as-cran'
build_args <- character()
} else {
Expand Down
3 changes: 3 additions & 0 deletions cpp/src/arrow/vendored/datetime/README.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -23,6 +23,9 @@ of the above project.
The following changes are made:
- fix internal inclusion paths (from "date/xxx.h" to simply "xxx.h")
- enclose the `date` namespace inside the `arrow_vendored` namespace
- fix 4 declarations like `CONSTCD11 date::day operator "" _d(unsigned long long d) NOEXCEPT;`
to not have offending whitespace for modern clang:
`CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;`

## How to update

Expand Down
8 changes: 4 additions & 4 deletions cpp/src/arrow/vendored/datetime/date.h
Original file line numberDiff line numberDiff line change
Expand Up@@ -963,8 +963,8 @@ operator<<(std::basic_ostream<CharT, Traits>& os, const year_month_weekday_last&
inline namespace literals
{

CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;
CONSTCD11 date::year operator ""_y(unsigned long long y) NOEXCEPT;
CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;
CONSTCD11 date::year operator ""_y(unsigned long long y) NOEXCEPT;

} // inline namespace literals
#endif // !defined(_MSC_VER) || (_MSC_VER >= 1900)
Expand DownExpand Up@@ -1972,15 +1972,15 @@ inline namespace literals
CONSTCD11
inline
date::day
operator ""_d(unsigned long long d) NOEXCEPT
operator ""_d(unsigned long long d) NOEXCEPT
{
return date::day{static_cast<unsigned>(d)};
}

CONSTCD11
inline
date::year
operator ""_y(unsigned long long y) NOEXCEPT
operator ""_y(unsigned long long y) NOEXCEPT
{
return date::year(static_cast<int>(y));
}
Expand Down
2 changes: 2 additions & 0 deletions cpp/src/parquet/size_statistics.cc
Original file line numberDiff line numberDiff line change
Expand Up@@ -18,9 +18,11 @@
#include "parquet/size_statistics.h"

#include <algorithm>
#include <array>
#include <numeric>
#include <ostream>
#include <string_view>
#include <vector>

#include "arrow/util/logging.h"
#include "parquet/exception.h"
Expand Down
21 changes: 11 additions & 10 deletions dev/tasks/r/github.linux.cran.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -21,20 +21,21 @@

jobs:
as-cran:
name: "rhub/{{ MATRIX }}"
name: "rhub/{{ '${{ matrix.config.r_image }}' }}"
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
# See https://hub.docker.com/r/rhub
r_image:
- ubuntu-gcc12 # ~ r-devel-linux-x86_64-debian-gcc
- ubuntu-clang # ~ r-devel-linux-x86_64-debian-clang
- ubuntu-next # ~ r-patched-linux-x86_64
- ubuntu-release # ~ r-release-linux-x86_64
config:
# See https://r-hub.github.io/containers/
- { r_image: "ubuntu-gcc12" } # ~ r-devel-linux-x86_64-debian-gcc
- { r_image: "ubuntu-clang" } # ~ r-devel-linux-x86_64-debian-clang
- { r_image: "ubuntu-next" } # ~ r-patched-linux-x86_64
- { r_image: "ubuntu-release" } # ~ r-release-linux-x86_64
- { r_image: "clang20", skip_vignettes: true } # ~ r-devel-linux-x86_64-fedora-clang
env:
R_ORG: "rhub"
R_IMAGE: {{ MATRIX }}
R_IMAGE: {{ '${{ matrix.config.r_image }}' }}
R_TAG: "latest"
ARROW_R_DEV: "FALSE"
steps:
Expand All@@ -46,7 +47,7 @@ jobs:
env:
{{ macros.github_set_sccache_envvars()|indent(8)}}
# setting ARROW_SOURCE_HOME='' here ensures that we use the cpp source copied into tools/
run: archery docker run -e ARROW_SOURCE_HOME='' r
run: archery docker run -e ARROW_SOURCE_HOME='' -e SKIP_VIGNETTES={{ '${{ matrix.config.skip_vignettes }}' }} r
- name: Dump install logs
run: cat arrow/r/check/arrow.Rcheck/00install.out
if: always()
Expand All@@ -57,5 +58,5 @@ jobs:
if: always()
uses: actions/upload-artifact@v4
with:
name: test-output-{{ "${{ matrix.r_image }}" }}
name: test-output-{{ "${{ matrix.config.r_image }}" }}
path: arrow/r/check/arrow.Rcheck/tests/testthat.Rout*
2 changes: 0 additions & 2 deletions dev/tasks/tasks.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -1198,8 +1198,6 @@ tasks:
test-r-linux-as-cran:
ci: github
template: r/github.linux.cran.yml
params:
MATRIX: {{ "${{ matrix.r_image }}" }}

test-r-macos-as-cran:
ci: github
Expand Down
9 changes: 9 additions & 0 deletions r/NEWS.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -19,6 +19,15 @@

# arrow 19.0.1

This release primarily updates the underlying Arrow C++ version used by the
package to version 19.0.1 and includes all changes from the 19.0.0 and 19.0.1
releases. For what's changed in Arrow C++ 19.0.0, please see the [blog
post](https://arrow.apache.org/blog/2025/01/16/19.0.0-release/) and
[changelog](https://arrow.apache.org/release/19.0.0.html#changelog).
For what's changed in Arrow C++ 19.0.1, please see the [blog
post](https://arrow.apache.org/blog/2025/02/16/19.0.1-release/) and
[changelog](https://arrow.apache.org/release/19.0.1.html#changelog).

# arrow 18.1.0

## Minor improvements and fixes
Expand Down
32 changes: 25 additions & 7 deletions r/R/dplyr-funcs-agg.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -150,13 +150,7 @@ register_bindings_aggregate <- function() {
options = list(skip_nulls = na.rm, min_count = 0L)
)
})
register_binding("arrow::one", function(...) {
set_agg(
fun = "one",
data = ensure_one_arg(list2(...), "one"),
options = list()
)
})
register_binding("arrow::one", one)
}

set_agg <- function(...) {
Expand DownExpand Up@@ -194,6 +188,30 @@ find_arrow_mask <- function() {
n <- n + 1
}
}
#' Get one value from each group
#'
#' Returns one arbitrary value from the input for each group. The function is
#' biased towards non-null values: if there is at least one non-null value for a
#' certain group, that value is returned, and only if all the values are null
#' for the group will the function return null.
#'
#' @param ... Unquoted column name to pull values from.
#'
#' @examples
#' \dontrun{
#' mtcars |>
#' arrow_table() |>
#' group_by(cyl) |>
#' summarize(x = one(disp))
#' }
#' @keywords internal
one <- function(...) {
set_agg(
fun = "one",
data = ensure_one_arg(list2(...), "one"),
options = list()
)
}

ensure_one_arg <- function(args, fun) {
if (length(args) == 0) {
Expand Down
7 changes: 4 additions & 3 deletions r/R/dplyr-funcs-doc.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -21,7 +21,7 @@
#'
#' The `arrow` package contains methods for 37 `dplyr` table functions, many of
#' which are "verbs" that do transformations to one or more tables.
#' The package also has mappings of 212 R functions to the corresponding
#' The package also has mappings of 213 R functions to the corresponding
#' functions in the Arrow compute library. These allow you to write code inside
#' of `dplyr` methods that call R functions, including many in packages like
#' `stringr` and `lubridate`, and they will get translated to Arrow and run
Expand All@@ -42,7 +42,7 @@
#' * [`collect()`][dplyr::collect()]
#' * [`compute()`][dplyr::compute()]
#' * [`count()`][dplyr::count()]
#' * [`distinct()`][dplyr::distinct()]: `.keep_all = TRUE` not supported
#' * [`distinct()`][dplyr::distinct()]: `.keep_all = TRUE` returns a non-missing value if present, only returning missing values if all are missing.
#' * [`explain()`][dplyr::explain()]
#' * [`filter()`][dplyr::filter()]
#' * [`full_join()`][dplyr::full_join()]: the `copy` argument is ignored
Expand DownExpand Up@@ -83,7 +83,7 @@
#' Functions can be called either as `pkg::fun()` or just `fun()`, i.e. both
#' `str_sub()` and `stringr::str_sub()` work.
#'
#' In addition to these functions, you can call any of Arrow's 262 compute
#' In addition to these functions, you can call any of Arrow's 271 compute
#' functions directly. Arrow has many functions that don't map to an existing R
#' function. In other cases where there is an R function mapping, you can still
#' call the Arrow function directly if you don't want the adaptations that the R
Expand All@@ -96,6 +96,7 @@
#'
#' * [`add_filename()`][arrow::add_filename()]
#' * [`cast()`][arrow::cast()]
#' * [`one()`][arrow::one()]
#'
#' ## base
#'
Expand Down
9 changes: 0 additions & 9 deletions r/README.md
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,5 @@
# arrow <img src="https://arrow.apache.org/img/arrow-logo_hex_black-txt_white-bg.png" align="right" alt="" width="120" />

<!-- badges: start -->

[![cran](https://www.r-pkg.org/badges/version-last-release/arrow)](https://cran.r-project.org/package=arrow)
[![CI](https://github.com/apache/arrow/workflows/R/badge.svg?event=push)](https://github.com/apache/arrow/actions?query=workflow%3AR+branch%3Amain+event%3Apush)
[![R-universe status badge](https://apache.r-universe.dev/badges/arrow)](https://apache.r-universe.dev)
[![conda-forge](https://img.shields.io/conda/vn/conda-forge/r-arrow.svg)](https://anaconda.org/conda-forge/r-arrow)

<!-- badges: end -->

## Overview

The R `{arrow}` package provides access to many of the features of the [Apache Arrow C++ library](https://arrow.apache.org/docs/cpp/index.html) for R users. The goal of arrow is to provide an Arrow C++ backend to `{dplyr}`, and access to the Arrow C++ library through familiar base R and tidyverse functions, or `{R6}` classes. The dedicated R package website is located [here](https://arrow.apache.org/docs/r/index.html).
Expand Down
7 changes: 4 additions & 3 deletions r/man/acero.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

26 changes: 26 additions & 0 deletions r/man/one.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion r/src/filesystem.cpp
Original file line numberDiff line numberDiff line change
Expand Up@@ -258,7 +258,7 @@ std::string fs___SubTreeFileSystem__base_path(

// [[arrow::export]]
cpp11::writable::list fs___FileSystemFromUri(const std::string& path) {
using cpp11::literals::operator""_nm;
using cpp11::literals::operator""_nm;

std::string out_path;
auto io_context = MainRThread::GetInstance().CancellableIOContext();
Expand Down
8 changes: 4 additions & 4 deletions r/tools/nixlibs.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -84,10 +84,10 @@ try_download <- function(from_url, to_file, hush = quietly) {
return(FALSE)
}
# We download some fairly large files, so ensure the timeout is set appropriately.
# This assumes a static library size of 100 MB (generous) and a download speed
# of .3 MB/s (slow). This is to anticipate slower user connections or load on
# artifactory servers.
opts <- options(timeout = max(300, getOption("timeout")))
# This assumes a static library size of 100 MB (our current biggest is 78 MB) and
# a download speed of 0.2 MB/s (slow). This is to anticipate slower user connections
# or load on artifactory servers.
opts <- options(timeout = max(600, getOption("timeout")))
on.exit(options(opts))

status <- try(
Expand Down
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Auto-enable theater mode on YouTube\n(function() {\n function tryTheater() {\n var btn = document.querySelector('button[aria-label=\"Theater mode\"], ytd-player #player button[title=\"Theater mode\"]');\n if (btn && !btn.classList.contains('activated')) {\n btn.click();\n }\n }\n \n // Try immediately\n tryTheater();\n \n // Try after navigation (SPA)\n var lastUrl = location.href;\n setInterval(function() {\n if (location.href !== lastUrl) {\n lastUrl = location.href;\n setTimeout(tryTheater, 500);\n }\n }, 1000);\n \n // Also try on player load\n var observer = new MutationObserver(tryTheater);\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "YouTube Theater Mode Default"); } } catch(__e) { console.warn('[Userscript:YouTube Theater Mode Default]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content
Closed
Show file tree
Hide file tree
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
4 changes: 3 additions & 1 deletion .github/workflows/r.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -405,7 +405,9 @@ jobs:
)
# we use pak for package installation since it is faster, safer and more convenient
pak::local_install()
pak::pak("lintr")
# Pin the lintr version to avoid breaking changes with newer 3.2.0 version
# See: https://github.com/apache/arrow/pull/45524
pak::pak("lintr@3.1.2")
lintr::expect_lint_free()
- name: Dump install logs
shell: cmd
Expand Down
1 change: 1 addition & 0 deletions ci/docker/linux-apt-lint.dockerfile
Original file line numberDiff line numberDiff line change
Expand Up@@ -58,6 +58,7 @@ RUN cat /arrow/ci/etc/rprofile >> $(R RHOME)/etc/Rprofile.site
RUN echo "MAKEFLAGS=-j$(R -s -e 'cat(parallel::detectCores())')" >> $(R RHOME)/etc/Renviron.site
# We don't need arrow's dependencies, only lintr (and its dependencies)
RUN R -e "install.packages('lintr')"
RUN R -e "install.packages('cyclocomp')"

# Docker linter
COPY --from=hadolint /bin/hadolint /usr/bin/hadolint
Expand Down
4 changes: 3 additions & 1 deletion ci/scripts/r_test.sh
Original file line numberDiff line numberDiff line change
Expand Up@@ -91,7 +91,9 @@ export TEXMFVAR=/tmp/texmf-var
BEFORE=$(ls -alh ~/)

SCRIPT="as_cran <- !identical(tolower(Sys.getenv('NOT_CRAN')), 'true')
if (as_cran) {
# generally will be false, but we can override it by setting SKIP_VIGNETTES=true
skip_vignettes <- identical(tolower(Sys.getenv('SKIP_VIGNETTES')), 'true')
if (as_cran && !skip_vignettes) {
args <- '--as-cran'
build_args <- character()
} else {
Expand Down
3 changes: 3 additions & 0 deletions cpp/src/arrow/vendored/datetime/README.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -23,6 +23,9 @@ of the above project.
The following changes are made:
- fix internal inclusion paths (from "date/xxx.h" to simply "xxx.h")
- enclose the `date` namespace inside the `arrow_vendored` namespace
- fix 4 declarations like `CONSTCD11 date::day operator "" _d(unsigned long long d) NOEXCEPT;`
to not have offending whitespace for modern clang:
`CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;`

## How to update

Expand Down
8 changes: 4 additions & 4 deletions cpp/src/arrow/vendored/datetime/date.h
Original file line numberDiff line numberDiff line change
Expand Up@@ -963,8 +963,8 @@ operator<<(std::basic_ostream<CharT, Traits>& os, const year_month_weekday_last&
inline namespace literals
{

CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;
CONSTCD11 date::year operator ""_y(unsigned long long y) NOEXCEPT;
CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;
CONSTCD11 date::year operator ""_y(unsigned long long y) NOEXCEPT;

} // inline namespace literals
#endif // !defined(_MSC_VER) || (_MSC_VER >= 1900)
Expand DownExpand Up@@ -1972,15 +1972,15 @@ inline namespace literals
CONSTCD11
inline
date::day
operator ""_d(unsigned long long d) NOEXCEPT
operator ""_d(unsigned long long d) NOEXCEPT
{
return date::day{static_cast<unsigned>(d)};
}

CONSTCD11
inline
date::year
operator ""_y(unsigned long long y) NOEXCEPT
operator ""_y(unsigned long long y) NOEXCEPT
{
return date::year(static_cast<int>(y));
}
Expand Down
2 changes: 2 additions & 0 deletions cpp/src/parquet/size_statistics.cc
Original file line numberDiff line numberDiff line change
Expand Up@@ -18,9 +18,11 @@
#include "parquet/size_statistics.h"

#include <algorithm>
#include <array>
#include <numeric>
#include <ostream>
#include <string_view>
#include <vector>

#include "arrow/util/logging.h"
#include "parquet/exception.h"
Expand Down
21 changes: 11 additions & 10 deletions dev/tasks/r/github.linux.cran.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -21,20 +21,21 @@

jobs:
as-cran:
name: "rhub/{{ MATRIX }}"
name: "rhub/{{ '${{ matrix.config.r_image }}' }}"
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
# See https://hub.docker.com/r/rhub
r_image:
- ubuntu-gcc12 # ~ r-devel-linux-x86_64-debian-gcc
- ubuntu-clang # ~ r-devel-linux-x86_64-debian-clang
- ubuntu-next # ~ r-patched-linux-x86_64
- ubuntu-release # ~ r-release-linux-x86_64
config:
# See https://r-hub.github.io/containers/
- { r_image: "ubuntu-gcc12" } # ~ r-devel-linux-x86_64-debian-gcc
- { r_image: "ubuntu-clang" } # ~ r-devel-linux-x86_64-debian-clang
- { r_image: "ubuntu-next" } # ~ r-patched-linux-x86_64
- { r_image: "ubuntu-release" } # ~ r-release-linux-x86_64
- { r_image: "clang20", skip_vignettes: true } # ~ r-devel-linux-x86_64-fedora-clang
env:
R_ORG: "rhub"
R_IMAGE: {{ MATRIX }}
R_IMAGE: {{ '${{ matrix.config.r_image }}' }}
R_TAG: "latest"
ARROW_R_DEV: "FALSE"
steps:
Expand All@@ -46,7 +47,7 @@ jobs:
env:
{{ macros.github_set_sccache_envvars()|indent(8)}}
# setting ARROW_SOURCE_HOME='' here ensures that we use the cpp source copied into tools/
run: archery docker run -e ARROW_SOURCE_HOME='' r
run: archery docker run -e ARROW_SOURCE_HOME='' -e SKIP_VIGNETTES={{ '${{ matrix.config.skip_vignettes }}' }} r
- name: Dump install logs
run: cat arrow/r/check/arrow.Rcheck/00install.out
if: always()
Expand All@@ -57,5 +58,5 @@ jobs:
if: always()
uses: actions/upload-artifact@v4
with:
name: test-output-{{ "${{ matrix.r_image }}" }}
name: test-output-{{ "${{ matrix.config.r_image }}" }}
path: arrow/r/check/arrow.Rcheck/tests/testthat.Rout*
2 changes: 0 additions & 2 deletions dev/tasks/tasks.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -1198,8 +1198,6 @@ tasks:
test-r-linux-as-cran:
ci: github
template: r/github.linux.cran.yml
params:
MATRIX: {{ "${{ matrix.r_image }}" }}

test-r-macos-as-cran:
ci: github
Expand Down
9 changes: 9 additions & 0 deletions r/NEWS.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -19,6 +19,15 @@

# arrow 19.0.1

This release primarily updates the underlying Arrow C++ version used by the
package to version 19.0.1 and includes all changes from the 19.0.0 and 19.0.1
releases. For what's changed in Arrow C++ 19.0.0, please see the [blog
post](https://arrow.apache.org/blog/2025/01/16/19.0.0-release/) and
[changelog](https://arrow.apache.org/release/19.0.0.html#changelog).
For what's changed in Arrow C++ 19.0.1, please see the [blog
post](https://arrow.apache.org/blog/2025/02/16/19.0.1-release/) and
[changelog](https://arrow.apache.org/release/19.0.1.html#changelog).

# arrow 18.1.0

## Minor improvements and fixes
Expand Down
32 changes: 25 additions & 7 deletions r/R/dplyr-funcs-agg.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -150,13 +150,7 @@ register_bindings_aggregate <- function() {
options = list(skip_nulls = na.rm, min_count = 0L)
)
})
register_binding("arrow::one", function(...) {
set_agg(
fun = "one",
data = ensure_one_arg(list2(...), "one"),
options = list()
)
})
register_binding("arrow::one", one)
}

set_agg <- function(...) {
Expand DownExpand Up@@ -194,6 +188,30 @@ find_arrow_mask <- function() {
n <- n + 1
}
}
#' Get one value from each group
#'
#' Returns one arbitrary value from the input for each group. The function is
#' biased towards non-null values: if there is at least one non-null value for a
#' certain group, that value is returned, and only if all the values are null
#' for the group will the function return null.
#'
#' @param ... Unquoted column name to pull values from.
#'
#' @examples
#' \dontrun{
#' mtcars |>
#' arrow_table() |>
#' group_by(cyl) |>
#' summarize(x = one(disp))
#' }
#' @keywords internal
one <- function(...) {
set_agg(
fun = "one",
data = ensure_one_arg(list2(...), "one"),
options = list()
)
}

ensure_one_arg <- function(args, fun) {
if (length(args) == 0) {
Expand Down
7 changes: 4 additions & 3 deletions r/R/dplyr-funcs-doc.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -21,7 +21,7 @@
#'
#' The `arrow` package contains methods for 37 `dplyr` table functions, many of
#' which are "verbs" that do transformations to one or more tables.
#' The package also has mappings of 212 R functions to the corresponding
#' The package also has mappings of 213 R functions to the corresponding
#' functions in the Arrow compute library. These allow you to write code inside
#' of `dplyr` methods that call R functions, including many in packages like
#' `stringr` and `lubridate`, and they will get translated to Arrow and run
Expand All@@ -42,7 +42,7 @@
#' * [`collect()`][dplyr::collect()]
#' * [`compute()`][dplyr::compute()]
#' * [`count()`][dplyr::count()]
#' * [`distinct()`][dplyr::distinct()]: `.keep_all = TRUE` not supported
#' * [`distinct()`][dplyr::distinct()]: `.keep_all = TRUE` returns a non-missing value if present, only returning missing values if all are missing.
#' * [`explain()`][dplyr::explain()]
#' * [`filter()`][dplyr::filter()]
#' * [`full_join()`][dplyr::full_join()]: the `copy` argument is ignored
Expand DownExpand Up@@ -83,7 +83,7 @@
#' Functions can be called either as `pkg::fun()` or just `fun()`, i.e. both
#' `str_sub()` and `stringr::str_sub()` work.
#'
#' In addition to these functions, you can call any of Arrow's 262 compute
#' In addition to these functions, you can call any of Arrow's 271 compute
#' functions directly. Arrow has many functions that don't map to an existing R
#' function. In other cases where there is an R function mapping, you can still
#' call the Arrow function directly if you don't want the adaptations that the R
Expand All@@ -96,6 +96,7 @@
#'
#' * [`add_filename()`][arrow::add_filename()]
#' * [`cast()`][arrow::cast()]
#' * [`one()`][arrow::one()]
#'
#' ## base
#'
Expand Down
9 changes: 0 additions & 9 deletions r/README.md
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,5 @@
# arrow <img src="https://arrow.apache.org/img/arrow-logo_hex_black-txt_white-bg.png" align="right" alt="" width="120" />

<!-- badges: start -->

[![cran](https://www.r-pkg.org/badges/version-last-release/arrow)](https://cran.r-project.org/package=arrow)
[![CI](https://github.com/apache/arrow/workflows/R/badge.svg?event=push)](https://github.com/apache/arrow/actions?query=workflow%3AR+branch%3Amain+event%3Apush)
[![R-universe status badge](https://apache.r-universe.dev/badges/arrow)](https://apache.r-universe.dev)
[![conda-forge](https://img.shields.io/conda/vn/conda-forge/r-arrow.svg)](https://anaconda.org/conda-forge/r-arrow)

<!-- badges: end -->

## Overview

The R `{arrow}` package provides access to many of the features of the [Apache Arrow C++ library](https://arrow.apache.org/docs/cpp/index.html) for R users. The goal of arrow is to provide an Arrow C++ backend to `{dplyr}`, and access to the Arrow C++ library through familiar base R and tidyverse functions, or `{R6}` classes. The dedicated R package website is located [here](https://arrow.apache.org/docs/r/index.html).
Expand Down
7 changes: 4 additions & 3 deletions r/man/acero.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

26 changes: 26 additions & 0 deletions r/man/one.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion r/src/filesystem.cpp
Original file line numberDiff line numberDiff line change
Expand Up@@ -258,7 +258,7 @@ std::string fs___SubTreeFileSystem__base_path(

// [[arrow::export]]
cpp11::writable::list fs___FileSystemFromUri(const std::string& path) {
using cpp11::literals::operator""_nm;
using cpp11::literals::operator""_nm;

std::string out_path;
auto io_context = MainRThread::GetInstance().CancellableIOContext();
Expand Down
8 changes: 4 additions & 4 deletions r/tools/nixlibs.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -84,10 +84,10 @@ try_download <- function(from_url, to_file, hush = quietly) {
return(FALSE)
}
# We download some fairly large files, so ensure the timeout is set appropriately.
# This assumes a static library size of 100 MB (generous) and a download speed
# of .3 MB/s (slow). This is to anticipate slower user connections or load on
# artifactory servers.
opts <- options(timeout = max(300, getOption("timeout")))
# This assumes a static library size of 100 MB (our current biggest is 78 MB) and
# a download speed of 0.2 MB/s (slow). This is to anticipate slower user connections
# or load on artifactory servers.
opts <- options(timeout = max(600, getOption("timeout")))
on.exit(options(opts))

status <- try(
Expand Down
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Remove or un-stick sticky/fixed headers that block content\n(function() {\n function unstick() {\n document.querySelectorAll('header, nav, [role=\"banner\"], .header, .navbar, .sticky, .fixed-top, [style*=\"position: fixed\"], [style*=\"position:sticky\"]').forEach(function(el) {\n if (el.style.position === 'fixed' || el.style.position === 'sticky' || \n getComputedStyle(el).position === 'fixed' || getComputedStyle(el).position === 'sticky') {\n el.style.position = 'static';\n el.style.top = 'auto';\n el.style.zIndex = 'auto';\n }\n });\n }\n \n unstick();\n \n var observer = new MutationObserver(unstick);\n observer.observe(document.body, { childList: true, subtree: true, attributes: true, attributeFilter: ['style', 'class'] });\n})();", "Kill Sticky Headers"); } } catch(__e) { console.warn('[Userscript:Kill Sticky Headers]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content
Closed
Show file tree
Hide file tree
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
4 changes: 3 additions & 1 deletion .github/workflows/r.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -405,7 +405,9 @@ jobs:
)
# we use pak for package installation since it is faster, safer and more convenient
pak::local_install()
pak::pak("lintr")
# Pin the lintr version to avoid breaking changes with newer 3.2.0 version
# See: https://github.com/apache/arrow/pull/45524
pak::pak("lintr@3.1.2")
lintr::expect_lint_free()
- name: Dump install logs
shell: cmd
Expand Down
1 change: 1 addition & 0 deletions ci/docker/linux-apt-lint.dockerfile
Original file line numberDiff line numberDiff line change
Expand Up@@ -58,6 +58,7 @@ RUN cat /arrow/ci/etc/rprofile >> $(R RHOME)/etc/Rprofile.site
RUN echo "MAKEFLAGS=-j$(R -s -e 'cat(parallel::detectCores())')" >> $(R RHOME)/etc/Renviron.site
# We don't need arrow's dependencies, only lintr (and its dependencies)
RUN R -e "install.packages('lintr')"
RUN R -e "install.packages('cyclocomp')"

# Docker linter
COPY --from=hadolint /bin/hadolint /usr/bin/hadolint
Expand Down
4 changes: 3 additions & 1 deletion ci/scripts/r_test.sh
Original file line numberDiff line numberDiff line change
Expand Up@@ -91,7 +91,9 @@ export TEXMFVAR=/tmp/texmf-var
BEFORE=$(ls -alh ~/)

SCRIPT="as_cran <- !identical(tolower(Sys.getenv('NOT_CRAN')), 'true')
if (as_cran) {
# generally will be false, but we can override it by setting SKIP_VIGNETTES=true
skip_vignettes <- identical(tolower(Sys.getenv('SKIP_VIGNETTES')), 'true')
if (as_cran && !skip_vignettes) {
args <- '--as-cran'
build_args <- character()
} else {
Expand Down
3 changes: 3 additions & 0 deletions cpp/src/arrow/vendored/datetime/README.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -23,6 +23,9 @@ of the above project.
The following changes are made:
- fix internal inclusion paths (from "date/xxx.h" to simply "xxx.h")
- enclose the `date` namespace inside the `arrow_vendored` namespace
- fix 4 declarations like `CONSTCD11 date::day operator "" _d(unsigned long long d) NOEXCEPT;`
to not have offending whitespace for modern clang:
`CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;`

## How to update

Expand Down
8 changes: 4 additions & 4 deletions cpp/src/arrow/vendored/datetime/date.h
Original file line numberDiff line numberDiff line change
Expand Up@@ -963,8 +963,8 @@ operator<<(std::basic_ostream<CharT, Traits>& os, const year_month_weekday_last&
inline namespace literals
{

CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;
CONSTCD11 date::year operator ""_y(unsigned long long y) NOEXCEPT;
CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;
CONSTCD11 date::year operator ""_y(unsigned long long y) NOEXCEPT;

} // inline namespace literals
#endif // !defined(_MSC_VER) || (_MSC_VER >= 1900)
Expand DownExpand Up@@ -1972,15 +1972,15 @@ inline namespace literals
CONSTCD11
inline
date::day
operator ""_d(unsigned long long d) NOEXCEPT
operator ""_d(unsigned long long d) NOEXCEPT
{
return date::day{static_cast<unsigned>(d)};
}

CONSTCD11
inline
date::year
operator ""_y(unsigned long long y) NOEXCEPT
operator ""_y(unsigned long long y) NOEXCEPT
{
return date::year(static_cast<int>(y));
}
Expand Down
2 changes: 2 additions & 0 deletions cpp/src/parquet/size_statistics.cc
Original file line numberDiff line numberDiff line change
Expand Up@@ -18,9 +18,11 @@
#include "parquet/size_statistics.h"

#include <algorithm>
#include <array>
#include <numeric>
#include <ostream>
#include <string_view>
#include <vector>

#include "arrow/util/logging.h"
#include "parquet/exception.h"
Expand Down
21 changes: 11 additions & 10 deletions dev/tasks/r/github.linux.cran.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -21,20 +21,21 @@

jobs:
as-cran:
name: "rhub/{{ MATRIX }}"
name: "rhub/{{ '${{ matrix.config.r_image }}' }}"
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
# See https://hub.docker.com/r/rhub
r_image:
- ubuntu-gcc12 # ~ r-devel-linux-x86_64-debian-gcc
- ubuntu-clang # ~ r-devel-linux-x86_64-debian-clang
- ubuntu-next # ~ r-patched-linux-x86_64
- ubuntu-release # ~ r-release-linux-x86_64
config:
# See https://r-hub.github.io/containers/
- { r_image: "ubuntu-gcc12" } # ~ r-devel-linux-x86_64-debian-gcc
- { r_image: "ubuntu-clang" } # ~ r-devel-linux-x86_64-debian-clang
- { r_image: "ubuntu-next" } # ~ r-patched-linux-x86_64
- { r_image: "ubuntu-release" } # ~ r-release-linux-x86_64
- { r_image: "clang20", skip_vignettes: true } # ~ r-devel-linux-x86_64-fedora-clang
env:
R_ORG: "rhub"
R_IMAGE: {{ MATRIX }}
R_IMAGE: {{ '${{ matrix.config.r_image }}' }}
R_TAG: "latest"
ARROW_R_DEV: "FALSE"
steps:
Expand All@@ -46,7 +47,7 @@ jobs:
env:
{{ macros.github_set_sccache_envvars()|indent(8)}}
# setting ARROW_SOURCE_HOME='' here ensures that we use the cpp source copied into tools/
run: archery docker run -e ARROW_SOURCE_HOME='' r
run: archery docker run -e ARROW_SOURCE_HOME='' -e SKIP_VIGNETTES={{ '${{ matrix.config.skip_vignettes }}' }} r
- name: Dump install logs
run: cat arrow/r/check/arrow.Rcheck/00install.out
if: always()
Expand All@@ -57,5 +58,5 @@ jobs:
if: always()
uses: actions/upload-artifact@v4
with:
name: test-output-{{ "${{ matrix.r_image }}" }}
name: test-output-{{ "${{ matrix.config.r_image }}" }}
path: arrow/r/check/arrow.Rcheck/tests/testthat.Rout*
2 changes: 0 additions & 2 deletions dev/tasks/tasks.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -1198,8 +1198,6 @@ tasks:
test-r-linux-as-cran:
ci: github
template: r/github.linux.cran.yml
params:
MATRIX: {{ "${{ matrix.r_image }}" }}

test-r-macos-as-cran:
ci: github
Expand Down
9 changes: 9 additions & 0 deletions r/NEWS.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -19,6 +19,15 @@

# arrow 19.0.1

This release primarily updates the underlying Arrow C++ version used by the
package to version 19.0.1 and includes all changes from the 19.0.0 and 19.0.1
releases. For what's changed in Arrow C++ 19.0.0, please see the [blog
post](https://arrow.apache.org/blog/2025/01/16/19.0.0-release/) and
[changelog](https://arrow.apache.org/release/19.0.0.html#changelog).
For what's changed in Arrow C++ 19.0.1, please see the [blog
post](https://arrow.apache.org/blog/2025/02/16/19.0.1-release/) and
[changelog](https://arrow.apache.org/release/19.0.1.html#changelog).

# arrow 18.1.0

## Minor improvements and fixes
Expand Down
32 changes: 25 additions & 7 deletions r/R/dplyr-funcs-agg.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -150,13 +150,7 @@ register_bindings_aggregate <- function() {
options = list(skip_nulls = na.rm, min_count = 0L)
)
})
register_binding("arrow::one", function(...) {
set_agg(
fun = "one",
data = ensure_one_arg(list2(...), "one"),
options = list()
)
})
register_binding("arrow::one", one)
}

set_agg <- function(...) {
Expand DownExpand Up@@ -194,6 +188,30 @@ find_arrow_mask <- function() {
n <- n + 1
}
}
#' Get one value from each group
#'
#' Returns one arbitrary value from the input for each group. The function is
#' biased towards non-null values: if there is at least one non-null value for a
#' certain group, that value is returned, and only if all the values are null
#' for the group will the function return null.
#'
#' @param ... Unquoted column name to pull values from.
#'
#' @examples
#' \dontrun{
#' mtcars |>
#' arrow_table() |>
#' group_by(cyl) |>
#' summarize(x = one(disp))
#' }
#' @keywords internal
one <- function(...) {
set_agg(
fun = "one",
data = ensure_one_arg(list2(...), "one"),
options = list()
)
}

ensure_one_arg <- function(args, fun) {
if (length(args) == 0) {
Expand Down
7 changes: 4 additions & 3 deletions r/R/dplyr-funcs-doc.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -21,7 +21,7 @@
#'
#' The `arrow` package contains methods for 37 `dplyr` table functions, many of
#' which are "verbs" that do transformations to one or more tables.
#' The package also has mappings of 212 R functions to the corresponding
#' The package also has mappings of 213 R functions to the corresponding
#' functions in the Arrow compute library. These allow you to write code inside
#' of `dplyr` methods that call R functions, including many in packages like
#' `stringr` and `lubridate`, and they will get translated to Arrow and run
Expand All@@ -42,7 +42,7 @@
#' * [`collect()`][dplyr::collect()]
#' * [`compute()`][dplyr::compute()]
#' * [`count()`][dplyr::count()]
#' * [`distinct()`][dplyr::distinct()]: `.keep_all = TRUE` not supported
#' * [`distinct()`][dplyr::distinct()]: `.keep_all = TRUE` returns a non-missing value if present, only returning missing values if all are missing.
#' * [`explain()`][dplyr::explain()]
#' * [`filter()`][dplyr::filter()]
#' * [`full_join()`][dplyr::full_join()]: the `copy` argument is ignored
Expand DownExpand Up@@ -83,7 +83,7 @@
#' Functions can be called either as `pkg::fun()` or just `fun()`, i.e. both
#' `str_sub()` and `stringr::str_sub()` work.
#'
#' In addition to these functions, you can call any of Arrow's 262 compute
#' In addition to these functions, you can call any of Arrow's 271 compute
#' functions directly. Arrow has many functions that don't map to an existing R
#' function. In other cases where there is an R function mapping, you can still
#' call the Arrow function directly if you don't want the adaptations that the R
Expand All@@ -96,6 +96,7 @@
#'
#' * [`add_filename()`][arrow::add_filename()]
#' * [`cast()`][arrow::cast()]
#' * [`one()`][arrow::one()]
#'
#' ## base
#'
Expand Down
9 changes: 0 additions & 9 deletions r/README.md
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,5 @@
# arrow <img src="https://arrow.apache.org/img/arrow-logo_hex_black-txt_white-bg.png" align="right" alt="" width="120" />

<!-- badges: start -->

[![cran](https://www.r-pkg.org/badges/version-last-release/arrow)](https://cran.r-project.org/package=arrow)
[![CI](https://github.com/apache/arrow/workflows/R/badge.svg?event=push)](https://github.com/apache/arrow/actions?query=workflow%3AR+branch%3Amain+event%3Apush)
[![R-universe status badge](https://apache.r-universe.dev/badges/arrow)](https://apache.r-universe.dev)
[![conda-forge](https://img.shields.io/conda/vn/conda-forge/r-arrow.svg)](https://anaconda.org/conda-forge/r-arrow)

<!-- badges: end -->

## Overview

The R `{arrow}` package provides access to many of the features of the [Apache Arrow C++ library](https://arrow.apache.org/docs/cpp/index.html) for R users. The goal of arrow is to provide an Arrow C++ backend to `{dplyr}`, and access to the Arrow C++ library through familiar base R and tidyverse functions, or `{R6}` classes. The dedicated R package website is located [here](https://arrow.apache.org/docs/r/index.html).
Expand Down
7 changes: 4 additions & 3 deletions r/man/acero.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

26 changes: 26 additions & 0 deletions r/man/one.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion r/src/filesystem.cpp
Original file line numberDiff line numberDiff line change
Expand Up@@ -258,7 +258,7 @@ std::string fs___SubTreeFileSystem__base_path(

// [[arrow::export]]
cpp11::writable::list fs___FileSystemFromUri(const std::string& path) {
using cpp11::literals::operator""_nm;
using cpp11::literals::operator""_nm;

std::string out_path;
auto io_context = MainRThread::GetInstance().CancellableIOContext();
Expand Down
8 changes: 4 additions & 4 deletions r/tools/nixlibs.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -84,10 +84,10 @@ try_download <- function(from_url, to_file, hush = quietly) {
return(FALSE)
}
# We download some fairly large files, so ensure the timeout is set appropriately.
# This assumes a static library size of 100 MB (generous) and a download speed
# of .3 MB/s (slow). This is to anticipate slower user connections or load on
# artifactory servers.
opts <- options(timeout = max(300, getOption("timeout")))
# This assumes a static library size of 100 MB (our current biggest is 78 MB) and
# a download speed of 0.2 MB/s (slow). This is to anticipate slower user connections
# or load on artifactory servers.
opts <- options(timeout = max(600, getOption("timeout")))
on.exit(options(opts))

status <- try(
Expand Down
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Universal Dark Mode - works on any site\n(function() {\n var enabled = true;\n \n function applyDarkMode() {\n if (!enabled) return;\n \n // Create style element if it doesn't exist\n var style = document.getElementById('universal-dark-mode-style');\n if (!style) {\n style = document.createElement('style');\n style.id = 'universal-dark-mode-style';\n document.head.appendChild(style);\n }\n \n // Dark mode CSS - inverts colors but preserves images/video\n style.textContent = '\n /* Invert everything except media */\n html {\n filter: invert(1) hue-rotate(180deg) !important;\n background: #1a1a2e !important;\n }\n \n /* Restore images, videos, iframes, canvas */\n img, video, iframe, canvas, svg, picture, [style*=\"background-image\"] {\n filter: invert(1) hue-rotate(180deg) !important;\n }\n \n /* Preserve specific elements that should not be inverted */\n .no-dark-mode, .no-dark-mode *,\n [data-theme=\"light\"], [data-theme=\"light\"],\n .ace_editor, .ace_editor *,\n .CodeMirror, .CodeMirror *,\n .monaco-editor, .monaco-editor *,\n .markdown-body pre, .markdown-body pre *,\n .highlight, .highlight *,\n pre code, pre code * {\n filter: none !important;\n }\n \n /* Fix common UI elements */\n .modal, .popup, .dropdown-menu, .tooltip, .popover {\n filter: invert(1) hue-rotate(180deg) !important;\n background: #2d2d44 !important;\n border-color: #444 !important;\n }\n \n /* Scrollbars */\n ::-webkit-scrollbar { background: #1a1a2e !important; }\n ::-webkit-scrollbar-thumb { background: #444 !important; }\n ::-webkit-scrollbar-thumb:hover { background: #555 !important; }\n \n /* Selection */\n ::selection { background: #4ecdc4 !important; color: #1a1a2e !important; }\n ::-moz-selection { background: #4ecdc4 !important; color: #1a1a2e !important; }\n ';\n }\n \n function removeDarkMode() {\n var style = document.getElementById('universal-dark-mode-style');\n if (style) style.remove();\n }\n \n // Toggle with Alt+Shift+D\n document.addEventListener('keydown', function(e) {\n if (e.altKey && e.shiftKey && e.key === 'D') {\n e.preventDefault();\n enabled = !enabled;\n if (enabled) {\n applyDarkMode();\n console.log('[Universal Dark Mode] Enabled');\n } else {\n removeDarkMode();\n console.log('[Universal Dark Mode] Disabled');\n }\n }\n });\n \n // Apply on load\n applyDarkMode();\n \n // Re-apply on dynamic content\n var observer = new MutationObserver(function(mutations) {\n if (enabled && !document.getElementById('universal-dark-mode-style')) {\n applyDarkMode();\n }\n });\n observer.observe(document.head, { childList: true });\n \n console.log('[Universal Dark Mode] Loaded - Press Alt+Shift+D to toggle');\n})();", "Universal Dark Mode"); } } catch(__e) { console.warn('[Userscript:Universal Dark Mode]', __e); } })(); })();
Skip to content
Closed
Show file tree
Hide file tree
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
4 changes: 3 additions & 1 deletion .github/workflows/r.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -405,7 +405,9 @@ jobs:
)
# we use pak for package installation since it is faster, safer and more convenient
pak::local_install()
pak::pak("lintr")
# Pin the lintr version to avoid breaking changes with newer 3.2.0 version
# See: https://github.com/apache/arrow/pull/45524
pak::pak("lintr@3.1.2")
lintr::expect_lint_free()
- name: Dump install logs
shell: cmd
Expand Down
1 change: 1 addition & 0 deletions ci/docker/linux-apt-lint.dockerfile
Original file line numberDiff line numberDiff line change
Expand Up@@ -58,6 +58,7 @@ RUN cat /arrow/ci/etc/rprofile >> $(R RHOME)/etc/Rprofile.site
RUN echo "MAKEFLAGS=-j$(R -s -e 'cat(parallel::detectCores())')" >> $(R RHOME)/etc/Renviron.site
# We don't need arrow's dependencies, only lintr (and its dependencies)
RUN R -e "install.packages('lintr')"
RUN R -e "install.packages('cyclocomp')"

# Docker linter
COPY --from=hadolint /bin/hadolint /usr/bin/hadolint
Expand Down
4 changes: 3 additions & 1 deletion ci/scripts/r_test.sh
Original file line numberDiff line numberDiff line change
Expand Up@@ -91,7 +91,9 @@ export TEXMFVAR=/tmp/texmf-var
BEFORE=$(ls -alh ~/)

SCRIPT="as_cran <- !identical(tolower(Sys.getenv('NOT_CRAN')), 'true')
if (as_cran) {
# generally will be false, but we can override it by setting SKIP_VIGNETTES=true
skip_vignettes <- identical(tolower(Sys.getenv('SKIP_VIGNETTES')), 'true')
if (as_cran && !skip_vignettes) {
args <- '--as-cran'
build_args <- character()
} else {
Expand Down
3 changes: 3 additions & 0 deletions cpp/src/arrow/vendored/datetime/README.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -23,6 +23,9 @@ of the above project.
The following changes are made:
- fix internal inclusion paths (from "date/xxx.h" to simply "xxx.h")
- enclose the `date` namespace inside the `arrow_vendored` namespace
- fix 4 declarations like `CONSTCD11 date::day operator "" _d(unsigned long long d) NOEXCEPT;`
to not have offending whitespace for modern clang:
`CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;`

## How to update

Expand Down
8 changes: 4 additions & 4 deletions cpp/src/arrow/vendored/datetime/date.h
Original file line numberDiff line numberDiff line change
Expand Up@@ -963,8 +963,8 @@ operator<<(std::basic_ostream<CharT, Traits>& os, const year_month_weekday_last&
inline namespace literals
{

CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;
CONSTCD11 date::year operator ""_y(unsigned long long y) NOEXCEPT;
CONSTCD11 date::day operator ""_d(unsigned long long d) NOEXCEPT;
CONSTCD11 date::year operator ""_y(unsigned long long y) NOEXCEPT;

} // inline namespace literals
#endif // !defined(_MSC_VER) || (_MSC_VER >= 1900)
Expand DownExpand Up@@ -1972,15 +1972,15 @@ inline namespace literals
CONSTCD11
inline
date::day
operator ""_d(unsigned long long d) NOEXCEPT
operator ""_d(unsigned long long d) NOEXCEPT
{
return date::day{static_cast<unsigned>(d)};
}

CONSTCD11
inline
date::year
operator ""_y(unsigned long long y) NOEXCEPT
operator ""_y(unsigned long long y) NOEXCEPT
{
return date::year(static_cast<int>(y));
}
Expand Down
2 changes: 2 additions & 0 deletions cpp/src/parquet/size_statistics.cc
Original file line numberDiff line numberDiff line change
Expand Up@@ -18,9 +18,11 @@
#include "parquet/size_statistics.h"

#include <algorithm>
#include <array>
#include <numeric>
#include <ostream>
#include <string_view>
#include <vector>

#include "arrow/util/logging.h"
#include "parquet/exception.h"
Expand Down
21 changes: 11 additions & 10 deletions dev/tasks/r/github.linux.cran.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -21,20 +21,21 @@

jobs:
as-cran:
name: "rhub/{{ MATRIX }}"
name: "rhub/{{ '${{ matrix.config.r_image }}' }}"
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
# See https://hub.docker.com/r/rhub
r_image:
- ubuntu-gcc12 # ~ r-devel-linux-x86_64-debian-gcc
- ubuntu-clang # ~ r-devel-linux-x86_64-debian-clang
- ubuntu-next # ~ r-patched-linux-x86_64
- ubuntu-release # ~ r-release-linux-x86_64
config:
# See https://r-hub.github.io/containers/
- { r_image: "ubuntu-gcc12" } # ~ r-devel-linux-x86_64-debian-gcc
- { r_image: "ubuntu-clang" } # ~ r-devel-linux-x86_64-debian-clang
- { r_image: "ubuntu-next" } # ~ r-patched-linux-x86_64
- { r_image: "ubuntu-release" } # ~ r-release-linux-x86_64
- { r_image: "clang20", skip_vignettes: true } # ~ r-devel-linux-x86_64-fedora-clang
env:
R_ORG: "rhub"
R_IMAGE: {{ MATRIX }}
R_IMAGE: {{ '${{ matrix.config.r_image }}' }}
R_TAG: "latest"
ARROW_R_DEV: "FALSE"
steps:
Expand All@@ -46,7 +47,7 @@ jobs:
env:
{{ macros.github_set_sccache_envvars()|indent(8)}}
# setting ARROW_SOURCE_HOME='' here ensures that we use the cpp source copied into tools/
run: archery docker run -e ARROW_SOURCE_HOME='' r
run: archery docker run -e ARROW_SOURCE_HOME='' -e SKIP_VIGNETTES={{ '${{ matrix.config.skip_vignettes }}' }} r
- name: Dump install logs
run: cat arrow/r/check/arrow.Rcheck/00install.out
if: always()
Expand All@@ -57,5 +58,5 @@ jobs:
if: always()
uses: actions/upload-artifact@v4
with:
name: test-output-{{ "${{ matrix.r_image }}" }}
name: test-output-{{ "${{ matrix.config.r_image }}" }}
path: arrow/r/check/arrow.Rcheck/tests/testthat.Rout*
2 changes: 0 additions & 2 deletions dev/tasks/tasks.yml
Original file line numberDiff line numberDiff line change
Expand Up@@ -1198,8 +1198,6 @@ tasks:
test-r-linux-as-cran:
ci: github
template: r/github.linux.cran.yml
params:
MATRIX: {{ "${{ matrix.r_image }}" }}

test-r-macos-as-cran:
ci: github
Expand Down
9 changes: 9 additions & 0 deletions r/NEWS.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -19,6 +19,15 @@

# arrow 19.0.1

This release primarily updates the underlying Arrow C++ version used by the
package to version 19.0.1 and includes all changes from the 19.0.0 and 19.0.1
releases. For what's changed in Arrow C++ 19.0.0, please see the [blog
post](https://arrow.apache.org/blog/2025/01/16/19.0.0-release/) and
[changelog](https://arrow.apache.org/release/19.0.0.html#changelog).
For what's changed in Arrow C++ 19.0.1, please see the [blog
post](https://arrow.apache.org/blog/2025/02/16/19.0.1-release/) and
[changelog](https://arrow.apache.org/release/19.0.1.html#changelog).

# arrow 18.1.0

## Minor improvements and fixes
Expand Down
32 changes: 25 additions & 7 deletions r/R/dplyr-funcs-agg.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -150,13 +150,7 @@ register_bindings_aggregate <- function() {
options = list(skip_nulls = na.rm, min_count = 0L)
)
})
register_binding("arrow::one", function(...) {
set_agg(
fun = "one",
data = ensure_one_arg(list2(...), "one"),
options = list()
)
})
register_binding("arrow::one", one)
}

set_agg <- function(...) {
Expand DownExpand Up@@ -194,6 +188,30 @@ find_arrow_mask <- function() {
n <- n + 1
}
}
#' Get one value from each group
#'
#' Returns one arbitrary value from the input for each group. The function is
#' biased towards non-null values: if there is at least one non-null value for a
#' certain group, that value is returned, and only if all the values are null
#' for the group will the function return null.
#'
#' @param ... Unquoted column name to pull values from.
#'
#' @examples
#' \dontrun{
#' mtcars |>
#' arrow_table() |>
#' group_by(cyl) |>
#' summarize(x = one(disp))
#' }
#' @keywords internal
one <- function(...) {
set_agg(
fun = "one",
data = ensure_one_arg(list2(...), "one"),
options = list()
)
}

ensure_one_arg <- function(args, fun) {
if (length(args) == 0) {
Expand Down
7 changes: 4 additions & 3 deletions r/R/dplyr-funcs-doc.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -21,7 +21,7 @@
#'
#' The `arrow` package contains methods for 37 `dplyr` table functions, many of
#' which are "verbs" that do transformations to one or more tables.
#' The package also has mappings of 212 R functions to the corresponding
#' The package also has mappings of 213 R functions to the corresponding
#' functions in the Arrow compute library. These allow you to write code inside
#' of `dplyr` methods that call R functions, including many in packages like
#' `stringr` and `lubridate`, and they will get translated to Arrow and run
Expand All@@ -42,7 +42,7 @@
#' * [`collect()`][dplyr::collect()]
#' * [`compute()`][dplyr::compute()]
#' * [`count()`][dplyr::count()]
#' * [`distinct()`][dplyr::distinct()]: `.keep_all = TRUE` not supported
#' * [`distinct()`][dplyr::distinct()]: `.keep_all = TRUE` returns a non-missing value if present, only returning missing values if all are missing.
#' * [`explain()`][dplyr::explain()]
#' * [`filter()`][dplyr::filter()]
#' * [`full_join()`][dplyr::full_join()]: the `copy` argument is ignored
Expand DownExpand Up@@ -83,7 +83,7 @@
#' Functions can be called either as `pkg::fun()` or just `fun()`, i.e. both
#' `str_sub()` and `stringr::str_sub()` work.
#'
#' In addition to these functions, you can call any of Arrow's 262 compute
#' In addition to these functions, you can call any of Arrow's 271 compute
#' functions directly. Arrow has many functions that don't map to an existing R
#' function. In other cases where there is an R function mapping, you can still
#' call the Arrow function directly if you don't want the adaptations that the R
Expand All@@ -96,6 +96,7 @@
#'
#' * [`add_filename()`][arrow::add_filename()]
#' * [`cast()`][arrow::cast()]
#' * [`one()`][arrow::one()]
#'
#' ## base
#'
Expand Down
9 changes: 0 additions & 9 deletions r/README.md
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,5 @@
# arrow <img src="https://arrow.apache.org/img/arrow-logo_hex_black-txt_white-bg.png" align="right" alt="" width="120" />

<!-- badges: start -->

[![cran](https://www.r-pkg.org/badges/version-last-release/arrow)](https://cran.r-project.org/package=arrow)
[![CI](https://github.com/apache/arrow/workflows/R/badge.svg?event=push)](https://github.com/apache/arrow/actions?query=workflow%3AR+branch%3Amain+event%3Apush)
[![R-universe status badge](https://apache.r-universe.dev/badges/arrow)](https://apache.r-universe.dev)
[![conda-forge](https://img.shields.io/conda/vn/conda-forge/r-arrow.svg)](https://anaconda.org/conda-forge/r-arrow)

<!-- badges: end -->

## Overview

The R `{arrow}` package provides access to many of the features of the [Apache Arrow C++ library](https://arrow.apache.org/docs/cpp/index.html) for R users. The goal of arrow is to provide an Arrow C++ backend to `{dplyr}`, and access to the Arrow C++ library through familiar base R and tidyverse functions, or `{R6}` classes. The dedicated R package website is located [here](https://arrow.apache.org/docs/r/index.html).
Expand Down
7 changes: 4 additions & 3 deletions r/man/acero.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

26 changes: 26 additions & 0 deletions r/man/one.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion r/src/filesystem.cpp
Original file line numberDiff line numberDiff line change
Expand Up@@ -258,7 +258,7 @@ std::string fs___SubTreeFileSystem__base_path(

// [[arrow::export]]
cpp11::writable::list fs___FileSystemFromUri(const std::string& path) {
using cpp11::literals::operator""_nm;
using cpp11::literals::operator""_nm;

std::string out_path;
auto io_context = MainRThread::GetInstance().CancellableIOContext();
Expand Down
8 changes: 4 additions & 4 deletions r/tools/nixlibs.R
Original file line numberDiff line numberDiff line change
Expand Up@@ -84,10 +84,10 @@ try_download <- function(from_url, to_file, hush = quietly) {
return(FALSE)
}
# We download some fairly large files, so ensure the timeout is set appropriately.
# This assumes a static library size of 100 MB (generous) and a download speed
# of .3 MB/s (slow). This is to anticipate slower user connections or load on
# artifactory servers.
opts <- options(timeout = max(300, getOption("timeout")))
# This assumes a static library size of 100 MB (our current biggest is 78 MB) and
# a download speed of 0.2 MB/s (slow). This is to anticipate slower user connections
# or load on artifactory servers.
opts <- options(timeout = max(600, getOption("timeout")))
on.exit(options(opts))

status <- try(
Expand Down