Skip to content

Commit

Permalink
Apply suggested workaround for affected CI test
Browse files Browse the repository at this point in the history
  • Loading branch information
glatterf42 committed Dec 13, 2024
1 parent 02dadfa commit d93ed2a
Showing 1 changed file with 37 additions and 14 deletions.
51 changes: 37 additions & 14 deletions .github/workflows/pytest.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,15 @@ jobs:
run: echo "RETICULATE_PYTHON=$pythonLocation" >> $GITHUB_ENV
shell: bash

# Workaround Python Path in R issue https://github.com/actions/runner-images/issues/11137
- name: Install system dependencies for R packages
if: ${{ matrix.os == 'ubuntu-latest' && matrix.python-version == '3.12' }}
run: |
sudo apt-get update
sudo apt-get install -y libcurl4-openssl-dev libssl-dev libxml2-dev
sudo apt-get install -y python3-pip python3-dev
# pip3 install jupyter
- name: Install Python package and dependencies
# [docs] contains [tests], which contains [report,tutorial]
run: |
Expand All @@ -111,21 +120,35 @@ jobs:
# limits pint < 0.17. Override. cf. iiasa/ixmp#544
pip install --upgrade pint
- name: Install R dependencies and tutorial requirements
# - name: Install R dependencies and tutorial requirements
# run: |
# install.packages(c("remotes", "Rcpp"))
# remotes::install_cran(
# c("IRkernel", "reticulate"),
# dependencies = TRUE,
# # force = TRUE,
# )

# pip install jupyter
# Rscript -e "IRkernel::installspec()"

# # IRkernel::installspec()

# # commented: for debugging
# # print(reticulate::py_config())
# # reticulate::py_run_string("import os; print(os.environ)")
# shell: Rscript {0}

- name: Install R dependencies
run: |
R -e "install.packages(c('remotes', 'Rcpp'))"
R -e "remotes::install_cran(c('IRkernel', 'reticulate'), dependencies = TRUE)"
- name: Install Jupyter via pip
run: |
pip install jupyter
- name: Configure IRkernel
run: |
install.packages(c("remotes", "Rcpp"))
remotes::install_cran(
c("IRkernel", "reticulate"),
dependencies = TRUE,
# force = TRUE,
)
IRkernel::installspec()
# commented: for debugging
# print(reticulate::py_config())
# reticulate::py_run_string("import os; print(os.environ)")
shell: Rscript {0}
Rscript -e "IRkernel::installspec()"
- name: Run test suite using pytest
run: |
Expand Down

0 comments on commit d93ed2a

Please sign in to comment.