Skip to content

BLD: fix the build (pin ubuntu version to 20.04)? #35

BLD: fix the build (pin ubuntu version to 20.04)?

BLD: fix the build (pin ubuntu version to 20.04)? #35

Workflow file for this run

# Based on
# https://github.com/fedarko/strainFlye/blob/main/.github/workflows/main.yml
# (which was based on EMPress' workflow); some of the Node.js stuff based on
# MetagenomeScope's JS workflow
name: QIIME 2 CI
on: [push, pull_request]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
# Test on multiple QIIME 2 versions. This is a nice way of making sure
# that Qurro works on all of the QIIME 2 versions it actually, you
# know, supports. As of writing, this includes QIIME 2 versions
#
# 1. 2020.11
# 2. 2021.2
# 3. 2021.4
# 4. 2021.8
# 5. 2021.11
# 6. 2022.2
# 7. 2022.8
#
# We currently test just a subset of these versions, because each of
# these builds takes a while (and testing each of these would probs be
# overkill).
#
# We could use a matrix of just QIIME 2 version strings (e.g.
# "2020.11", ...), but other stuff about the URLs change across QIIME 2
# versions (e.g. the "-py36-" or "-py38-" thing). It ends up being
# easier just have the variable here be the URLs to the YAMLs. That
# sentence has too many acronyms. Look, you get the point.
#
# Worth noting: the final of these URLs (with qiime2-latest) will
# always be set to the latest version of QIIME 2. Thanks @thermokarst
# for the heads up about this :)
q2-yaml: [
"https://raw.githubusercontent.com/qiime2/environment-files/master/2020.11/release/qiime2-2020.11-py36-linux-conda.yml",
"https://raw.githubusercontent.com/qiime2/environment-files/master/2021.8/release/qiime2-2021.8-py38-linux-conda.yml",
"https://raw.githubusercontent.com/qiime2/environment-files/master/2022.2/release/qiime2-2022.2-py38-linux-conda.yml",
"https://raw.githubusercontent.com/qiime2/environment-files/master/latest/staging/qiime2-latest-py38-linux-conda.yml"
]
steps:
# Updating from v2 to v3 to match, as of writing,
# https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python
- name: Check out code
uses: actions/checkout@v3
- name: Download the QIIME 2 conda environment YAML
run: wget -O q2-env.yml ${{ matrix.q2-yaml }}
# https://github.com/conda-incubator/setup-miniconda#example-3-other-options
- name: Hit the yoinky sploinky (install QIIME 2)
uses: conda-incubator/setup-miniconda@v2
with:
activate-environment: qiime2-dev
environment-file: q2-env.yml
- name: Install Qurro (and its pip dependencies)
run: conda run -n qiime2-dev pip install -e .[dev]
- name: Set up Node.js
uses: actions/setup-node@v1
- name: Install Qurro's Node.js development dependencies
run: npm install -g mocha-headless-chrome nyc prettier@2.0.5 jshint
- name: Run tests
run: conda run -n qiime2-dev make test
- name: Lint and stylecheck (not using Black to check Python code)
run: conda run -n qiime2-dev make stylecheck_not_black
# It's possible to install packages that break QIIME 2's CLI (e.g.
# installing Click >= 8 into a Q2 2022.2 environment seems to break it --
# this is discussed in the developer documentation, CONTRIBUTING.md).
# Verify that, by installing Qurro, we have not "broken" QIIME 2 in this
# way.
- name: Test that QIIME 2's CLI works
run: conda run -n qiime2-dev qiime info
- name: Upload code coverage information to Codecov
uses: codecov/codecov-action@v2