Skip to content

WIP: [R] Verify CRAN release-20.0.0.1 #46472

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 4 commits into
base: maint-20.0.0-r
Choose a base branch
from
Draft
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
2 changes: 0 additions & 2 deletions cpp/cmake_modules/ThirdpartyToolchain.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -610,8 +610,6 @@ else()
# our currently used packages and doesn't fall out of sync with
# ${ARROW_BOOST_BUILD_VERSION_UNDERSCORES}
"${THIRDPARTY_MIRROR_URL}/boost_${ARROW_BOOST_BUILD_VERSION_UNDERSCORES}.tar.gz"
"https://boostorg.jfrog.io/artifactory/main/release/${ARROW_BOOST_BUILD_VERSION}/source/boost_${ARROW_BOOST_BUILD_VERSION_UNDERSCORES}.tar.gz"
"https://sourceforge.net/projects/boost/files/boost/${ARROW_BOOST_BUILD_VERSION}/boost_${ARROW_BOOST_BUILD_VERSION_UNDERSCORES}.tar.gz"
)
endif()

Expand Down
6 changes: 5 additions & 1 deletion cpp/src/arrow/csv/parser.cc
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,11 @@ class ValueDescWriter {

protected:
ValueDescWriter(MemoryPool* pool, int64_t values_capacity)
: values_size_(0), values_capacity_(values_capacity), status_(Status::OK()) {
: values_size_(0),
values_capacity_(values_capacity),
quoted_(false),
saved_values_size_(0),
status_(Status::OK()) {
status_ &= AllocateResizableBuffer(values_capacity_ * sizeof(*values_), pool)
.Value(&values_buffer_);
if (status_.ok()) {
Expand Down
60 changes: 60 additions & 0 deletions dev/tasks/r/github.linux.sanitizers.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.

{% import 'macros.jinja' as macros with context %}

{{ macros.github_header() }}

jobs:
r-linux-sanitizers:
name: "rhub/{{ '${{ matrix.config.r_image }}' }}"
runs-on: ubuntu-latest
timeout-minutes: {{ timeout|default(60) }}
env:
R_PRUNE_DEPS: TRUE
R_ORG: "rhub"
R_IMAGE: "{{ '${{ matrix.config.r_image }}' }}"
R_TAG: "latest"
strategy:
fail-fast: false
matrix:
config:
# See https://r-hub.github.io/containers/
- { r_image: "clang-asan", skip_vignettes: true }
- { r_image: "clang-ubsan", skip_vignettes: true }
- { r_image: "gcc-asan", skip_vignettes: true} # includes both asan and ubsan
steps:
{{ macros.github_checkout_arrow()|indent }}
{{ macros.github_install_archery()|indent }}

- name: Docker Run
shell: bash
env:
{{ macros.github_set_sccache_envvars()|indent(8)}}
run: archery docker run -e SKIP_VIGNETTES={{ '${{ matrix.config.skip_vignettes }}' }} r-san
- name: Dump install logs
run: cat arrow/r/arrow.Rcheck/00install.out
if: always()
- name: Dump test logs
run: cat arrow/r/arrow.Rcheck/tests/testthat.Rout*
if: always()
- name: Save the test output
if: always()
uses: actions/upload-artifact@v4
with:
name: test-output-{{ "${{ matrix.config.r_image }}" }}
path: arrow/r/arrow.Rcheck/tests/testthat.Rout*
25 changes: 3 additions & 22 deletions dev/tasks/tasks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1078,30 +1078,11 @@ tasks:
r_tag: latest
flags: "-e LIBARROW_MINIMAL=TRUE"

test-r-linux-sanitizer:
test-r-linux-sanitizers:
ci: github
template: docker-tests/github.linux.yml
params:
env:
R_PRUNE_DEPS: TRUE
image: ubuntu-r-sanitizer
timeout: 120

test-r-clang-asan:
ci: github
template: docker-tests/github.linux.yml
template: r/github.linux.sanitizers.yml
params:
env:
R_PRUNE_DEPS: TRUE
image: r-clang-asan

test-r-clang-ubsan:
ci: github
template: docker-tests/github.linux.yml
params:
env:
R_PRUNE_DEPS: TRUE
image: r-clang-ubsan
timeout: 240 # 4 hours

test-r-m1-san:
ci: github
Expand Down
67 changes: 5 additions & 62 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -158,14 +158,12 @@ x-hierarchy:
- ubuntu-cpp-sanitizer
- ubuntu-cpp-thread-sanitizer
- ubuntu-cpp-emscripten
- ubuntu-r-sanitizer
- ubuntu-r-valgrind
- ubuntu-swift
- ubuntu-verify-rc
- r-clang-asan
- r-clang-ubsan
- r
- r-revdepcheck
- r-san
# helper services
- impala
- postgres
Expand Down Expand Up @@ -1690,70 +1688,15 @@ services:
command: >
/bin/bash -c "/arrow/ci/scripts/r_test.sh /arrow"

ubuntu-r-sanitizer:
# Only amd64 supported
# Usage:
# docker compose build ubuntu-r-sanitizer
# docker compose run ubuntu-r-sanitizer
image: ${REPO}:amd64-ubuntu-r-sanitizer
cap_add:
# LeakSanitizer and gdb requires ptrace(2)
- SYS_PTRACE
r-san:
image: ${REPO}:r-${R_ORG}-${R_IMAGE}
build:
context: .
dockerfile: ci/docker/linux-r.dockerfile
cache_from:
- ${REPO}:amd64-ubuntu-r-sanitizer
- ${REPO}:r-${R_ORG}-${R_IMAGE}
args:
base: wch1/r-debug:latest
cmake: ${CMAKE}
r_bin: RDsan
tz: ${TZ}
r_prune_deps: ${R_PRUNE_DEPS}
environment:
<<: [*common, *ccache]
ARROW_SOURCE_HOME: "/arrow"
volumes: *ubuntu-volumes
command: >
/bin/bash -c "
/arrow/ci/scripts/r_sanitize.sh /arrow"

r-clang-asan:
image: ${REPO}:r-rhub-clang-devel-latest
build:
context: .
dockerfile: ci/docker/linux-r.dockerfile
cache_from:
- ${REPO}:r-rhub-clang-devel-latest
args:
base: rhub/clang-asan
cmake: ${CMAKE}
r_dev: ${ARROW_R_DEV}
r_bin: R
tz: ${TZ}
r_prune_deps: ${R_PRUNE_DEPS}
shm_size: *shm-size
environment:
<<: *common
LIBARROW_DOWNLOAD: "false"
ARROW_SOURCE_HOME: "/arrow"
ARROW_R_DEV: ${ARROW_R_DEV}
ARROW_USE_PKG_CONFIG: "false"
volumes:
- .:/arrow:delegated
command: >
/bin/bash -c "
/arrow/ci/scripts/r_sanitize.sh /arrow"

r-clang-ubsan:
image: ${REPO}:r-rhub-clang-ubsan-devel-latest
build:
context: .
dockerfile: ci/docker/linux-r.dockerfile
cache_from:
- ${REPO}:r-rhub-clang-ubsan-devel-latest
args:
base: rhub/clang-ubsan
base: ${R_ORG}/${R_IMAGE}:${R_TAG}
cmake: ${CMAKE}
r_dev: ${ARROW_R_DEV}
r_bin: R
Expand Down
2 changes: 1 addition & 1 deletion r/DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: arrow
Title: Integration to 'Apache' 'Arrow'
Version: 20.0.0
Version: 20.0.0.1
Authors@R: c(
person("Neal", "Richardson", email = "[email protected]", role = c("aut")),
person("Ian", "Cook", email = "[email protected]", role = c("aut")),
Expand Down
7 changes: 7 additions & 0 deletions r/NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,13 @@
under the License.
-->

# arrow 20.0.0.1

## Minor improvements and fixes

- Updated internal C++ code to comply with CRAN's gcc-UBSAN checks
([#46394](https://github.com/apache/arrow/issues/46394))

# arrow 20.0.0

## Minor improvements and fixes
Expand Down
Loading