Skip to content
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

GH-38906: [R] Improve Windows CI configuration #38927

Merged
merged 5 commits into from
Nov 29, 2023
Merged
Changes from 4 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
35 changes: 18 additions & 17 deletions .github/workflows/r.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ jobs:
strategy:
fail-fast: false
matrix:
r: ["4.2"]
r: ["4.3"]
ubuntu: [20.04]
force-tests: ["true"]
env:
Expand All @@ -72,16 +72,6 @@ jobs:
with:
fetch-depth: 0
submodules: recursive
- name: Cache Docker Volumes
uses: actions/cache@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3.3.1
with:
path: .docker
# As this key is identical on both matrix builds only one will be able to successfully cache,
# this is fine as there are no differences in the build
key: ubuntu-${{ matrix.ubuntu }}-r-${{ matrix.r }}-${{ hashFiles('cpp/src/**/*.cc','cpp/src/**/*.h)') }}-${{ github.run_id }}
restore-keys: |
ubuntu-${{ matrix.ubuntu }}-r-${{ matrix.r }}-${{ hashFiles('cpp/src/**/*.cc','cpp/src/**/*.h)') }}-
ubuntu-${{ matrix.ubuntu }}-r-${{ matrix.r }}-
- name: Setup Python
Copy link
Member

Choose a reason for hiding this comment

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

why the removal?

uses: actions/setup-python@61a6322f88396a6271a6ee3565807d608ecaddd1 # v4.7.0
with:
Expand Down Expand Up @@ -143,6 +133,16 @@ jobs:
with:
fetch-depth: 0
submodules: recursive
- name: Cache Docker Volumes
uses: actions/cache@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3.3.1
with:
path: .docker
# As this key is identical on both matrix builds only one will be able to successfully cache,
# this is fine as there are no differences in the build
key: ubuntu-${{ matrix.ubuntu }}-r-${{ matrix.r }}-${{ hashFiles('cpp/src/**/*.cc','cpp/src/**/*.h)') }}-${{ github.run_id }}
Copy link
Member

Choose a reason for hiding this comment

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

the key doesn't work here as the values are not in the matrix, was this intentional?

Copy link
Member

Choose a reason for hiding this comment

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

just saw the commit message^^ so this needs to be move up to it's intended place^^

Copy link
Member Author

Choose a reason for hiding this comment

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

Ok, I think this is fixed!

restore-keys: |
ubuntu-${{ matrix.ubuntu }}-r-${{ matrix.r }}-${{ hashFiles('cpp/src/**/*.cc','cpp/src/**/*.h)') }}-
ubuntu-${{ matrix.ubuntu }}-r-${{ matrix.r }}-
- name: Setup Python
uses: actions/setup-python@61a6322f88396a6271a6ee3565807d608ecaddd1 # v4.7.0
with:
Expand Down Expand Up @@ -215,6 +215,9 @@ jobs:
r-${{ matrix.config.rtools }}-ccache-mingw-${{ matrix.config.arch }}-
- uses: r-lib/actions/setup-r@v2
with:
# Note: RTools must be 40 here because RTools40 + ucrt is how we build the Arrow C++
# static library. The R is not used here but R 4.1 was the last R to use
# Rtools40.
r-version: "4.1"
rtools-version: 40
Ncpus: 2
Expand All @@ -234,16 +237,16 @@ jobs:

windows-r:
needs: [windows-cpp]
name: AMD64 Windows R ${{ matrix.config.rversion }} RTools ${{ matrix.config.rtools }}
name: AMD64 Windows R ${{ matrix.config.rversion }}
runs-on: windows-2019
if: ${{ !contains(github.event.pull_request.title, 'WIP') }}
timeout-minutes: 75
strategy:
fail-fast: false
matrix:
config:
- { rtools: 42, rversion: "4.2" }
- { rtools: 42, rversion: "devel" }
- { rversion: "release" }

env:
ARROW_R_CXXFLAGS: "-Werror"
_R_CHECK_TESTS_NLINES_: 0
Expand All @@ -255,7 +258,6 @@ jobs:
fetch-depth: 0
- run: mkdir r/windows
- name: Download artifacts
if: ${{ matrix.config.rtools == 42 }}
uses: actions/download-artifact@v3
with:
name: libarrow-rtools40-ucrt64.zip
Expand All @@ -269,7 +271,6 @@ jobs:
- uses: r-lib/actions/setup-r@v2
with:
r-version: ${{ matrix.config.rversion }}
rtools-version: ${{ matrix.config.rtools }}
Ncpus: 2
- uses: r-lib/actions/setup-r-dependencies@v2
env:
Expand Down Expand Up @@ -318,7 +319,7 @@ jobs:
timeout = 3600
)
- name: Run lintr
if: ${{ matrix.config.rversion == '4.2' }}
if: ${{ matrix.config.rversion == 'release' }}
env:
NOT_CRAN: "true"
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand Down
Loading