Skip to content
Merged
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
90 changes: 90 additions & 0 deletions .github/workflows/apptainer.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
name: Apptainer Run

on:
push:
branches:
- main
- dev
workflow_dispatch:
pull_request:
branches-ignore: []
schedule:
- cron: '0 0 1 * *'

jobs:
build-linux:
runs-on: ubuntu-latest
strategy:
max-parallel: 5
matrix:
python: ['3.11']
fail-fast: false

steps:

# Clean up unnecessary preinstalled packages to free disk space
- name: Pre-cleanup
run: |
sudo rm -rf /usr/share/dotnet
sudo rm -rf "$AGENT_TOOLSDIRECTORY"

# Cache APT .deb packages
- name: Cache APT archives
uses: actions/cache@v3
with:
path: /var/cache/apt/archives
key: ${{ runner.os }}-apt-cache-v1

# Cache Apptainer installation
- name: Cache Apptainer install
id: cache-apptainer
uses: actions/cache@v3
with:
path: |
/usr/bin/apptainer
/usr/lib/apptainer
/etc/apptainer
key: ${{ runner.os }}-apptainer-v1

# Install Apptainer only if not cached
- name: Install Apptainer
if: steps.cache-apptainer.outputs.cache-hit != 'true'
run: |
sudo apt-get update
sudo apt-get install -y software-properties-common
sudo add-apt-repository -y ppa:apptainer/ppa
sudo apt-get update
sudo apt-get install -y apptainer

# Cache Apptainer image cache (~/.apptainer/cache)
- name: Cache Apptainer images
uses: actions/cache@v3
with:
path: ~/.apptainer/cache
key: ${{ runner.os }}-apptainer-images-v1

# Checkout repository
- name: Checkout repo
uses: actions/checkout@v4

# Set up Python
- name: Set up Python ${{ matrix.python }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}

# Install dependencies
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install .[testing]

# Install package
- name: Install package itself
run: |
pip install .

# Run tests using Apptainer
- name: Run Apptainer tests
run: |
sequana_quality_control --input-directory test/data/ --apptainer-prefix ~/.apptainer/cache && cd quality_control && bash quality_control.sh
20 changes: 11 additions & 9 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,46 +17,48 @@ jobs:
strategy:
max-parallel: 5
matrix:
python: [3.8,3.9,'3.10']
python: ['3.11','3.12']
fail-fast: false


steps:

- name: install graphviz
run: |
sudo apt-get update -qq
sudo apt-get install -y graphviz

- name: checkout git repo
uses: actions/checkout@v2
uses: actions/checkout@v4

- name: conda/mamba
uses: mamba-org/setup-micromamba@v1
uses: mamba-org/setup-micromamba@v2
with:
micromamba-version: '1.3.1-0'
environment-file: environment.yml
create-args: |
create-args: >-
python=${{ matrix.python }}
cache-environment: true
cache-downloads: true
generate-run-shell: true

- name: install package itself
shell: bash -el {0}
shell: micromamba-shell {0}
run: |
pip install .

- name: Install dependencies
shell: bash -el {0}
shell: micromamba-shell {0}
run: |
pip install coveralls pytest-cov pytest pytest-xdist

- name: testing
shell: bash -el {0}
shell: micromamba-shell {0}
run: |
pytest -v --cov-report term-missing --cov=sequana_pipelines.quality_control

- name: coveralls
shell: bash -l {0}
continue-on-error: true
shell: micromamba-shell {0}
run: |
echo $COVERALLS_REPO_TOKEN
coveralls --service=github
Expand Down
23 changes: 12 additions & 11 deletions .github/workflows/pypi.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: Publish to PyPI
on:
on:
workflow_dispatch:
push:
tags:
Expand All @@ -8,32 +8,33 @@ on:
jobs:
build-n-publish:
name: Build and publish to PyPI and TestPyPI
runs-on: ubuntu-20.04
runs-on: ubuntu-latest
permissions:
id-token: write
steps:
- uses: actions/checkout@main
- name: Set up Python 3.8
uses: actions/setup-python@v2
- uses: actions/checkout@v4
- name: Set up Python 3.11
uses: actions/setup-python@v5
with:
python-version: 3.8
python-version: '3.11'

- name: Install package
- name: Install package
run: |
pip install build poetry

- name: Build source tarball
run: |
rm -rf dist;
poetry build

- name: Publish distribution to Test PyPI
if: startsWith(github.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.TEST_PYPI_API_TOKEN }}
repository_url: https://test.pypi.org/legacy/
repository-url: https://test.pypi.org/legacy/
- name: Publish distribution to PyPI
if: startsWith(github.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}
10 changes: 7 additions & 3 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,12 @@
.. image:: https://github.com/sequana/quality_control/actions/workflows/main.yml/badge.svg
:target: https://github.com/sequana/quality_control/actions/workflows

.. image:: https://img.shields.io/badge/python-3.11%20%7C%203.12-blue.svg
:target: https://pypi.python.org/pypi/sequana_quality_control
:alt: Python 3.11 | 3.12

This pipeline is not maintained anymore but should be functional. It is a short-read quality control pipeline

**This pipeline is not maintained anymore but should be functional**. It is a short-read quality control pipeline
from the `Sequana <https://sequana.readthedocs.org>`_ project. We would recommend to use the fastqc, demultiplex,
and multitax pipelines instead.

Expand Down Expand Up @@ -89,8 +93,8 @@ ChangeLog
========= ====================================================================
Version Description
========= ====================================================================
0.11.0 * switch to click, pyproject. remove kraken (see multitax pipeline
instead)
1.0.0 * switch to click, pyproject. remove kraken (see multitax pipeline
instead). Uses new convention.
0.10.0 * add missing MANIFEST
0.9.0 * remove design_file for cutadapt to reflect changes in
sequana 0.12.0
Expand Down
32 changes: 15 additions & 17 deletions environment.yml
Original file line number Diff line number Diff line change
@@ -1,19 +1,17 @@
name: mapper

name: quality_control
channels:
- conda-forge
- bioconda
- defaults

- conda-forge
- bioconda
- defaults
dependencies:
- bwa
- samtools
- pigz
- fastqc
- sambamba
- pip:
- sequana
- cutadapt
- atropos


- bwa
- samtools
- pigz
- fastqc
- sambamba
- graphviz
- pulp>=2.8
- pip:
- sequana
- cutadapt
- atropos
Loading
Loading