Add step to filter conflicting chain/segment rows in CreateMergedTcrClonotypeFile #227
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# For help debugging build failures open an issue on the RStudio community with the 'github-actions' tag. | |
# https://community.rstudio.com/new-topic?category=Package%20development&tags=github-actions | |
on: | |
workflow_dispatch: | |
push: | |
branches: [ master ] | |
pull_request: | |
name: R Build and Checks | |
jobs: | |
R-CMD-check: | |
runs-on: ubuntu-${{ matrix.config.os }} | |
name: ubuntu-${{ matrix.config.os }} (${{ matrix.config.r }} / ${{ matrix.config.bioc }}) | |
strategy: | |
fail-fast: false | |
matrix: | |
config: | |
- {os: 22.04, r: 'devel', bioc: 'devel'} | |
- {os: 22.04, r: '4.3', bioc: '3.18'} | |
- {os: 22.04, r: '4.3', bioc: '3.17', pkgdown: "true"} | |
env: | |
R_REMOTES_NO_ERRORS_FROM_WARNINGS: true | |
RSPM: ${{ matrix.config.rspm }} | |
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: r-lib/actions/setup-r@v2 | |
with: | |
r-version: ${{ matrix.config.r }} | |
http-user-agent: ${{ matrix.config.http-user-agent }} | |
- uses: r-lib/actions/setup-pandoc@v2 | |
# libpoppler-cpp-dev added for pdftools, which is part of cellhashR | |
# libhdf5-dev added for cellmembrane/SeuratDisk | |
# libsodium-dev installed for VISION | |
- name: Install packages | |
if: runner.os != 'Windows' | |
run: | | |
sudo apt-get update && sudo apt-get install -yq python3-pip libpoppler-cpp-dev libmagick++-dev libhdf5-dev libsodium-dev | |
python3 -m pip install --upgrade pip | |
python3 -m pip install --user wheel setuptools | |
- name: Setup CoNGA | |
run: | | |
# NOTE: seaborn added for: https://github.com/scverse/scanpy/issues/2680 | |
python3 -m pip install --user scanpy fastcluster seaborn==0.12.2 | |
cd ../ | |
git clone -b rhesus https://github.com/phbradley/conga.git conga | |
cd conga/tcrdist_cpp | |
make | |
cd ../../ | |
pip3 install -e conga | |
cd Rdiscvr | |
# Note: the environment variable R_BIOC_VERSION is set to force remotes::install_bioc to follow the proper version | |
- name: Setup Bioconductor | |
run: | | |
install.packages('devtools') | |
if (!requireNamespace("BiocManager", quietly=TRUE)) install.packages("BiocManager"); | |
BiocManager::install(version = "${{ matrix.config.bioc }}", ask = FALSE); | |
cat(append = TRUE, file = "~/.Rprofile", "options(repos = BiocManager::repositories());") | |
cat(append = TRUE, file = "~/.Rprofile", "Sys.setenv(R_BIOC_VERSION=as.character(BiocManager::version()));"); | |
shell: Rscript {0} | |
- name: Query dependencies | |
run: | | |
install.packages('remotes') | |
print(paste0("R_BIOC_VERSION: ", Sys.getenv("R_BIOC_VERSION"))); | |
saveRDS(remotes::dev_package_deps(dependencies = TRUE), ".github/depends.Rds", version = 2) | |
writeLines(sprintf("R-%i.%i", getRversion()$major, getRversion()$minor), ".github/R-version") | |
shell: Rscript {0} | |
- name: Cache R packages | |
if: runner.os != 'Windows' | |
uses: actions/cache@v3 | |
with: | |
path: ${{ env.R_LIBS_USER }} | |
key: ${{ runner.os }}-${{ hashFiles('.github/R-version') }}-${{ matrix.config.bioc }}-${{ secrets.CACHE_VERSION || 1 }}-${{ hashFiles('.github/depends.Rds') }} | |
restore-keys: ${{ runner.os }}-${{ hashFiles('.github/R-version') }}-${{ matrix.config.bioc }}-${{ secrets.CACHE_VERSION || 1 }}- | |
# The install_github() on remotes is to ensure system_requirements() supports 22.04 | |
- name: Install r-lib/remotes | |
run: | | |
remotes::install_github("r-lib/remotes", force = TRUE) | |
print(paste0("Remotes version: ", packageVersion("remotes"))) | |
shell: Rscript {0} | |
- name: Install system dependencies | |
if: runner.os == 'Linux' | |
run: | | |
while read -r cmd | |
do | |
eval sudo $cmd | |
done < <(Rscript -e 'writeLines(remotes::system_requirements("ubuntu", "${{ matrix.config.os }}"))') | |
- name: Install dependencies | |
run: | | |
getOption('repos'); | |
print(paste0("R_BIOC_VERSION: ", Sys.getenv("R_BIOC_VERSION"))); | |
# TODO: remove this once Seurat 5 is supported. Install RIRA and CellMembrane first, since it depends on seurat 4.4 and the upgrade would otherwise force-update it: | |
devtools::install_version('Seurat', version = '4.4.0', ask = FALSE, upgrade = 'never', type = 'source', repos = 'https://cloud.r-project.org') | |
devtools::install_github(repo = 'bimberlabinternal/RIRA', ref = 'master', dependencies = TRUE, upgrade = 'never') | |
devtools::install_github(repo = 'bimberlabinternal/CellMembrane', ref = 'master', dependencies = TRUE, upgrade = 'never') | |
devtools::install_github(repo = 'bimberlab/cellhashR', ref = 'master', dependencies = TRUE, upgrade = 'never') | |
remotes::install_deps(dependencies = TRUE, upgrade = "never") | |
# Force 4.x for Seurat | |
devtools::install_version('Seurat', version = '4.4.0', ask = FALSE, upgrade = 'never') | |
remotes::install_cran("rcmdcheck") | |
# Due to Matrix/SeuratObject: https://github.com/mojaveazure/seurat-object/issues/166 | |
install.packages('SeuratObject', ask = FALSE, force = TRUE, type = 'source', repos = 'https://cloud.r-project.org') | |
shell: Rscript {0} | |
- name: Session info | |
run: | | |
options(width = 100) | |
pkgs <- installed.packages()[, "Package"] | |
sessioninfo::session_info(pkgs, include_base = TRUE) | |
shell: Rscript {0} | |
- name: Check | |
env: | |
_R_CHECK_CRAN_INCOMING_: false | |
run: rcmdcheck::rcmdcheck(args = c("--no-manual"), error_on = "error", check_dir = "check") | |
shell: Rscript {0} | |
- name: Show testthat output | |
if: always() | |
run: find check -name 'testthat.Rout*' -exec cat '{}' \; || true | |
shell: bash | |
- name: Upload check results | |
if: failure() | |
uses: actions/upload-artifact@main | |
with: | |
name: ${{ runner.os }}-r${{ matrix.config.r }}-results | |
path: check |