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
8 changes: 4 additions & 4 deletions ci/docker/linux-apt-r.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,10 @@ RUN cat /arrow/ci/etc/rprofile >> $(R RHOME)/etc/Rprofile.site
# Also ensure parallel compilation of C/C++ code
RUN echo "MAKEFLAGS=-j$(R -s -e 'cat(parallel::detectCores())')" >> $(R RHOME)/etc/Renviron.site

# Set up Python 3 and its dependencies
RUN ln -s /usr/bin/python3 /usr/local/bin/python && \
ln -s /usr/bin/pip3 /usr/local/bin/pip

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Installing duckdb from source (at least from github) requires the use of Python, so we need to make sure that we have a python on the path before we do that step (for now).

COPY ci/scripts/r_deps.sh /arrow/ci/scripts/
COPY r/DESCRIPTION /arrow/r/
RUN /arrow/ci/scripts/r_deps.sh /arrow
Expand All @@ -93,10 +97,6 @@ RUN /arrow/ci/scripts/install_minio.sh ${arch} linux latest /usr/local
COPY ci/scripts/install_gcs_testbench.sh /arrow/ci/scripts/
RUN /arrow/ci/scripts/install_gcs_testbench.sh ${arch} default

# Set up Python 3 and its dependencies
RUN ln -s /usr/bin/python3 /usr/local/bin/python && \
ln -s /usr/bin/pip3 /usr/local/bin/pip

COPY python/requirements-build.txt /arrow/python/
RUN pip install -r arrow/python/requirements-build.txt

Expand Down
4 changes: 4 additions & 0 deletions ci/docker/linux-r.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,10 @@ COPY ci/scripts/install_minio.sh /arrow/ci/scripts/
COPY ci/scripts/install_gcs_testbench.sh /arrow/ci/scripts/
RUN /arrow/ci/scripts/r_docker_configure.sh

# Set up Python 3 and its dependencies
RUN ln -s /usr/bin/python3 /usr/local/bin/python && \
ln -s /usr/bin/pip3 /usr/local/bin/pip

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same above, Python(3) was already installed, but it isn't on the path as python so the duckdb source install bails

COPY ci/scripts/r_deps.sh /arrow/ci/scripts/
COPY r/DESCRIPTION /arrow/r/
RUN /arrow/ci/scripts/r_deps.sh /arrow
9 changes: 9 additions & 0 deletions ci/scripts/r_deps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,15 @@ fi
# but we want to error/fail the build.
# options(warn=2) turns warnings into errors
${R_BIN} -e "options(warn=2); install.packages('remotes'); remotes::install_cran(c('glue', 'rcmdcheck', 'sys')); remotes::install_deps(INSTALL_opts = '"${INSTALL_ARGS}"')"

# (Temporarily) install DuckDB from source to avoid their Unity builds
# (though only if we haven't filtered it out of the deps above,
# and if we can't get a binary from RSPM)
# Remove when there is a DuckDB release > 0.3.1-1
if grep -q "duckdb" DESCRIPTION; then
${R_BIN} -e "if (all(!grepl('packagemanager.rstudio', options('repos')))) { remotes::install_github('duckdb/duckdb', subdir = '/tools/rpkg', build = FALSE) }"
fi

# Separately install the optional/test dependencies but don't error on them,
# they're not available everywhere and that's ok
${R_BIN} -e "remotes::install_deps(dependencies = TRUE, INSTALL_opts = '"${INSTALL_ARGS}"')"
Expand Down
1 change: 1 addition & 0 deletions r/tests/testthat/test-duckdb.R
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ test_that("to_duckdb", {
})

test_that("to_duckdb then to_arrow", {
skip("Flaky, unskip when ARROW-14745 is merged")
ds <- InMemoryDataset$create(example_data)

ds_rt <- ds %>%
Expand Down