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

DSL2 conversion #73

Merged
merged 65 commits into from Dec 15, 2021
Merged
Show file tree
Hide file tree
Changes from 63 commits
Commits
Show all changes
65 commits
Select commit Hold shift + click to select a range
884e541
Merge pull request #17 from nf-core/dev
apeltzer Dec 9, 2019
7822d1f
init dsl2 branch with cellranger modules and subworkflow
alexthiery1 Feb 18, 2021
ba4f5b1
add test data for cellranger subworkflow
alexthiery1 Mar 16, 2021
1c640c3
add config for module params and workflow testing
alexthiery1 Mar 16, 2021
a5f6e98
init cellranger subworkflow tests
alexthiery1 Mar 16, 2021
bbe48dd
edit fastq input into cellranger count
alexthiery1 Mar 16, 2021
e3eec29
init csv metadata module
alexthiery1 Mar 16, 2021
528977a
add versions and emit statements to modules
alexthiery1 Mar 19, 2021
be6daba
Merge pull request #52 from nf-core/dev
apeltzer Mar 29, 2021
f31b12f
Update CHANGELOG.md
apeltzer Mar 29, 2021
552e79c
initial refactoring
KevinMenden Apr 14, 2021
9e8eea1
initial refactoring
KevinMenden Apr 14, 2021
4cf0282
started adding modules and building pipeline
KevinMenden Apr 14, 2021
107acff
added more modules
KevinMenden Apr 14, 2021
4793ddb
move star to local modules
KevinMenden Apr 14, 2021
a8f33ba
refactored into different workflows
KevinMenden Apr 15, 2021
cd0a61b
Merge remote-tracking branch 'origin/dev' into feat-dsl2
KevinMenden Apr 15, 2021
e125b91
Merge pull request #1 from KevinMenden/feat-dsl2
KevinMenden Apr 15, 2021
e0a5b07
added local alevin modules
KevinMenden Apr 15, 2021
271d07d
half-working alevin dsl2 version
KevinMenden Apr 15, 2021
404b1a9
more updates
KevinMenden Apr 16, 2021
2ff52d1
added multiqc, get software versions
KevinMenden Apr 19, 2021
4924218
added workflow groovy class
KevinMenden Apr 19, 2021
d14c7a7
working alevin version
KevinMenden Apr 19, 2021
d017531
removed 'type' parameter
KevinMenden Apr 19, 2021
92f045f
added whitelist to salmon_alevin
KevinMenden Apr 19, 2021
19cc78f
added completion and utils classes
KevinMenden Apr 19, 2021
fa8009f
updated schema; started with star
KevinMenden Apr 19, 2021
01bb273
working STARsolo pipeline
KevinMenden Apr 19, 2021
9c9c649
added multiqc to starsolo; fixed bug
KevinMenden Apr 19, 2021
5e86a46
Merge pull request #55 from KevinMenden/dev
KevinMenden Apr 19, 2021
3782c25
started with kb pipeline
KevinMenden Apr 20, 2021
7a71690
working kallistobustools version
KevinMenden Apr 20, 2021
8f84f58
added function to format the protocol
KevinMenden Apr 21, 2021
22bdf66
working tests for DSL2
KevinMenden Apr 26, 2021
c567ef3
updated schema
KevinMenden Apr 26, 2021
2029d8a
updated NfcoreSchema
KevinMenden Apr 26, 2021
482572b
updated patterns
KevinMenden Apr 26, 2021
8deffa6
updated schema again
KevinMenden Apr 26, 2021
5534319
Apply suggestions from code review
KevinMenden Apr 27, 2021
7e0259e
Update lib/Workflow.groovy
KevinMenden Apr 27, 2021
52d902b
Merge pull request #56 from KevinMenden/dev
KevinMenden Apr 27, 2021
3facdb2
added checks
KevinMenden Apr 29, 2021
8d64aa5
Template update for nf-core/tools version 1.14
nf-core-bot May 11, 2021
da06162
updated with new modules filepaths
KevinMenden Jul 12, 2021
ca17e12
Template update for nf-core/tools version 2.0
KevinMenden Jul 13, 2021
f2743e0
Template update for nf-core/tools version 2.0.1
nf-core-bot Jul 13, 2021
1f0cbe3
Template update for nf-core/tools version 2.1
nf-core-bot Jul 27, 2021
b52bad9
Merge branch 'dsl2' of https://github.com/nf-core/scrnaseq into dsl2
ggabernet Oct 22, 2021
a005015
Merge pull request #62 from KevinMenden/dev
ggabernet Oct 28, 2021
030eb8c
Merge branch 'TEMPLATE' of https://github.com/nf-core/scrnaseq into m…
ggabernet Oct 29, 2021
b34e121
fix groovy function errors
ggabernet Oct 29, 2021
1e767a6
update changelog
ggabernet Oct 29, 2021
b3e40fd
replace software for modules folder
ggabernet Oct 29, 2021
4a9928d
update nextflow schema groovy
ggabernet Oct 29, 2021
e8479a4
update nextflow schema
ggabernet Oct 29, 2021
7f04e01
update nf-core module versions
ggabernet Oct 29, 2021
6e55bdc
bump version
ggabernet Oct 29, 2021
f7baf7d
fix mkdown lint
ggabernet Oct 29, 2021
84ae5fa
Merge branch 'dsl2' of https://github.com/nf-core/scrnaseq into merge…
ggabernet Oct 29, 2021
288ec60
fix editorconfig lint
ggabernet Oct 29, 2021
4a1b964
fix gtf error
ggabernet Oct 29, 2021
dad29ac
Merge pull request #74 from ggabernet/merge-template-update
ggabernet Oct 29, 2021
4813f7d
Update modules/local/kallistobustools_count.nf
ggabernet Oct 29, 2021
51d4ff4
Update README.md
ggabernet Nov 2, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
27 changes: 27 additions & 0 deletions .editorconfig
@@ -0,0 +1,27 @@
root = true

[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
indent_size = 4
indent_style = space

[*.{yml,yaml}]
indent_size = 2

[*.json]
insert_final_newline = unset

# These files are edited and tested upstream in nf-core/modules
[/modules/nf-core/**]
charset = unset
end_of_line = unset
insert_final_newline = unset
trim_trailing_whitespace = unset
indent_style = unset
indent_size = unset

[/assets/email*]
indent_size = unset
8 changes: 4 additions & 4 deletions .github/CONTRIBUTING.md
Expand Up @@ -19,7 +19,7 @@ If you'd like to write some code for nf-core/scrnaseq, the standard workflow is
* If there isn't one already, please create one so that others know you're working on this
2. [Fork](https://help.github.com/en/github/getting-started-with-github/fork-a-repo) the [nf-core/scrnaseq repository](https://github.com/nf-core/scrnaseq) to your GitHub account
3. Make the necessary changes / additions within your forked repository following [Pipeline conventions](#pipeline-contribution-conventions)
4. Use `nf-core schema build .` and add any new parameters to the pipeline JSON schema (requires [nf-core tools](https://github.com/nf-core/tools) >= 1.10).
4. Use `nf-core schema build` and add any new parameters to the pipeline JSON schema (requires [nf-core tools](https://github.com/nf-core/tools) >= 1.10).
5. Submit a Pull Request against the `dev` branch and wait for the code to be reviewed and merged

If you're not used to this workflow with git, you can start with some [docs from GitHub](https://help.github.com/en/github/collaborating-with-issues-and-pull-requests) or even their [excellent `git` resources](https://try.github.io/).
Expand Down Expand Up @@ -69,12 +69,12 @@ If you wish to contribute a new step, please use the following coding standards:
2. Write the process block (see below).
3. Define the output channel if needed (see below).
4. Add any new flags/options to `nextflow.config` with a default (see below).
5. Add any new flags/options to `nextflow_schema.json` with help text (with `nf-core schema build .`).
5. Add any new flags/options to `nextflow_schema.json` with help text (with `nf-core schema build`).
6. Add any new flags/options to the help message (for integer/text parameters, print to help the corresponding `nextflow.config` parameter).
7. Add sanity checks for all relevant parameters.
8. Add any new software to the `scrape_software_versions.py` script in `bin/` and the version command to the `scrape_software_versions` process in `main.nf`.
9. Do local tests that the new code works properly and as expected.
10. Add a new test command in `.github/workflow/ci.yaml`.
10. Add a new test command in `.github/workflow/ci.yml`.
11. If applicable add a [MultiQC](https://https://multiqc.info/) module.
12. Update MultiQC config `assets/multiqc_config.yaml` so relevant suffixes, name clean up, General Statistics Table column order, and module figures are in the right order.
13. Optional: Add any descriptions of MultiQC report sections and output files to `docs/output.md`.
Expand All @@ -83,7 +83,7 @@ If you wish to contribute a new step, please use the following coding standards:

Parameters should be initialised / defined with default values in `nextflow.config` under the `params` scope.

Once there, use `nf-core schema build .` to add to `nextflow_schema.json`.
Once there, use `nf-core schema build` to add to `nextflow_schema.json`.

### Default processes resource requirements

Expand Down
5 changes: 2 additions & 3 deletions .github/ISSUE_TEMPLATE/bug_report.md
Expand Up @@ -18,7 +18,7 @@ Please delete this text and anything that's not relevant from the template below
I have checked the following places for your error:

- [ ] [nf-core website: troubleshooting](https://nf-co.re/usage/troubleshooting)
- [ ] [nf-core/scrnaseq pipeline documentation](https://nf-co.re/nf-core/scrnaseq/usage)
- [ ] [nf-core/scrnaseq pipeline documentation](https://nf-co.re/scrnaseq/usage)

## Description of the bug

Expand Down Expand Up @@ -51,13 +51,12 @@ Have you provided the following extra information/files:

## Nextflow Installation

- Version: <!-- [e.g. 19.10.0] -->
- Version: <!-- [e.g. 21.04.0] -->

## Container engine

- Engine: <!-- [e.g. Conda, Docker, Singularity, Podman, Shifter or Charliecloud] -->
- version: <!-- [e.g. 1.0.0] -->
- Image tag: <!-- [e.g. nfcore/scrnaseq:1.0.0] -->

## Additional context

Expand Down
8 changes: 4 additions & 4 deletions .github/PULL_REQUEST_TEMPLATE.md
Expand Up @@ -10,15 +10,15 @@ Remember that PRs should be made against the dev branch, unless you're preparing

Learn more about contributing: [CONTRIBUTING.md](https://github.com/nf-core/scrnaseq/tree/master/.github/CONTRIBUTING.md)
-->
<!-- markdownlint-disable ul-indent -->

## PR checklist

- [ ] This comment contains a description of changes (with reason).
- [ ] If you've fixed a bug or added code that should be tested, add tests!
- [ ] If you've added a new tool - add to the software_versions process and a regex to `scrape_software_versions.py`
- [ ] If you've added a new tool - have you followed the pipeline conventions in the [contribution docs](https://github.com/nf-core/scrnaseq/tree/master/.github/CONTRIBUTING.md)
- [ ] If necessary, also make a PR on the nf-core/scrnaseq _branch_ on the [nf-core/test-datasets](https://github.com/nf-core/test-datasets) repository.
- [ ] Make sure your code lints (`nf-core lint .`).
- [ ] If you've added a new tool - have you followed the pipeline conventions in the [contribution docs](https://github.com/nf-core/scrnaseq/tree/master/.github/CONTRIBUTING.md)
- [ ] If necessary, also make a PR on the nf-core/scrnaseq _branch_ on the [nf-core/test-datasets](https://github.com/nf-core/test-datasets) repository.
- [ ] Make sure your code lints (`nf-core lint`).
- [ ] Ensure the test suite passes (`nextflow run . -profile test,docker`).
- [ ] Usage Documentation in `docs/usage.md` is updated.
- [ ] Output Documentation in `docs/output.md` is updated.
Expand Down
52 changes: 20 additions & 32 deletions .github/workflows/awsfulltest.yml
@@ -1,46 +1,34 @@
name: nf-core AWS full size tests
# This workflow is triggered on published releases.
# It can be additionally triggered manually with GitHub actions workflow dispatch.
# It can be additionally triggered manually with GitHub actions workflow dispatch button.
# It runs the -profile 'test_full' on AWS batch

on:
workflow_run:
workflows: ["nf-core Docker push (release)"]
types: [completed]
release:
types: [published]
workflow_dispatch:


env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
TOWER_ACCESS_TOKEN: ${{ secrets.AWS_TOWER_TOKEN }}
AWS_JOB_DEFINITION: ${{ secrets.AWS_JOB_DEFINITION }}
AWS_JOB_QUEUE: ${{ secrets.AWS_JOB_QUEUE }}
AWS_S3_BUCKET: ${{ secrets.AWS_S3_BUCKET }}


jobs:
run-awstest:
run-tower:
name: Run AWS full tests
if: github.repository == 'nf-core/scrnaseq'
runs-on: ubuntu-latest
steps:
- name: Setup Miniconda
uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
python-version: 3.7
- name: Install awscli
run: conda install -c conda-forge awscli
- name: Start AWS batch job
- name: Launch workflow via tower
uses: nf-core/tower-action@master
# TODO nf-core: You can customise AWS full pipeline tests as required
# Add full size test data (but still relatively small datasets for few samples)
# on the `test_full.config` test runs with only one set of parameters
# Then specify `-profile test_full` instead of `-profile test` on the AWS batch command
run: |
aws batch submit-job \
--region eu-west-1 \
--job-name nf-core-scrnaseq \
--job-queue $AWS_JOB_QUEUE \
--job-definition $AWS_JOB_DEFINITION \
--container-overrides '{"command": ["nf-core/scrnaseq", "-r '"${GITHUB_SHA}"' -profile test --outdir s3://'"${AWS_S3_BUCKET}"'/scrnaseq/results-'"${GITHUB_SHA}"' -w s3://'"${AWS_S3_BUCKET}"'/scrnaseq/work-'"${GITHUB_SHA}"' -with-tower"], "environment": [{"name": "TOWER_ACCESS_TOKEN", "value": "'"$TOWER_ACCESS_TOKEN"'"}]}'

with:
workspace_id: ${{ secrets.TOWER_WORKSPACE_ID }}
bearer_token: ${{ secrets.TOWER_BEARER_TOKEN }}
compute_env: ${{ secrets.TOWER_COMPUTE_ENV }}
pipeline: ${{ github.repository }}
revision: ${{ github.sha }}
workdir: s3://${{ secrets.AWS_S3_BUCKET }}/work/scrnaseq/work-${{ github.sha }}
parameters: |
{
"outdir": "s3://${{ secrets.AWS_S3_BUCKET }}/scrnaseq/results-${{ github.sha }}"
}
profiles: '[ "test_full", "aws_tower" ]'

50 changes: 18 additions & 32 deletions .github/workflows/awstest.yml
@@ -1,42 +1,28 @@
name: nf-core AWS test
# This workflow is triggered on push to the master branch.
# It can be additionally triggered manually with GitHub actions workflow dispatch.
# It runs the -profile 'test' on AWS batch.
# This workflow can be triggered manually with the GitHub actions workflow dispatch button.
# It runs the -profile 'test' on AWS batch

on:
workflow_dispatch:


env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
TOWER_ACCESS_TOKEN: ${{ secrets.AWS_TOWER_TOKEN }}
AWS_JOB_DEFINITION: ${{ secrets.AWS_JOB_DEFINITION }}
AWS_JOB_QUEUE: ${{ secrets.AWS_JOB_QUEUE }}
AWS_S3_BUCKET: ${{ secrets.AWS_S3_BUCKET }}


jobs:
run-awstest:
run-tower:
name: Run AWS tests
if: github.repository == 'nf-core/scrnaseq'
runs-on: ubuntu-latest
steps:
- name: Setup Miniconda
uses: conda-incubator/setup-miniconda@v2
- name: Launch workflow via tower
uses: nf-core/tower-action@master

with:
auto-update-conda: true
python-version: 3.7
- name: Install awscli
run: conda install -c conda-forge awscli
- name: Start AWS batch job
# TODO nf-core: You can customise CI pipeline run tests as required
# For example: adding multiple test runs with different parameters
# Remember that you can parallelise this by using strategy.matrix
run: |
aws batch submit-job \
--region eu-west-1 \
--job-name nf-core-scrnaseq \
--job-queue $AWS_JOB_QUEUE \
--job-definition $AWS_JOB_DEFINITION \
--container-overrides '{"command": ["nf-core/scrnaseq", "-r '"${GITHUB_SHA}"' -profile test --outdir s3://'"${AWS_S3_BUCKET}"'/scrnaseq/results-'"${GITHUB_SHA}"' -w s3://'"${AWS_S3_BUCKET}"'/scrnaseq/work-'"${GITHUB_SHA}"' -with-tower"], "environment": [{"name": "TOWER_ACCESS_TOKEN", "value": "'"$TOWER_ACCESS_TOKEN"'"}]}'
workspace_id: ${{ secrets.TOWER_WORKSPACE_ID }}
bearer_token: ${{ secrets.TOWER_BEARER_TOKEN }}
compute_env: ${{ secrets.TOWER_COMPUTE_ENV }}
pipeline: ${{ github.repository }}
revision: ${{ github.sha }}
workdir: s3://${{ secrets.AWS_S3_BUCKET }}/work/scrnaseq/work-${{ github.sha }}
parameters: |
{
"outdir": "s3://${{ secrets.AWS_S3_BUCKET }}/scrnaseq/results-${{ github.sha }}"
}
profiles: '[ "test", "aws_tower" ]'

30 changes: 10 additions & 20 deletions .github/workflows/ci.yml
Expand Up @@ -8,6 +8,9 @@ on:
release:
types: [published]

# Uncomment if we need an edge release of Nextflow again
# env: NXF_EDGE: 1

jobs:
test:
name: Run workflow tests
Expand All @@ -19,30 +22,18 @@ jobs:
NXF_ANSI_LOG: false
strategy:
matrix:
profile: ['test,docker', 'test_kallisto,docker', 'test,docker --aligner star']
profile:
[
"test,docker --aligner alevin",
"test,docker --aligner kallisto",
"test,docker --aligner star",
]
# Nextflow versions: check pipeline minimum and current latest
nxf_ver: ['20.10.0', '21.03.0-edge']
nxf_ver: ["21.04.0", ""]
steps:
- name: Check out pipeline code
uses: actions/checkout@v2

- name: Check if Dockerfile or Conda environment changed
uses: technote-space/get-diff-action@v4
with:
FILES: |
Dockerfile
environment.yml

- name: Build new docker image
if: env.MATCHED_FILES
run: docker build --no-cache . -t nfcore/scrnaseq:1.1.0

- name: Pull docker image
if: ${{ !env.MATCHED_FILES }}
run: |
docker pull nfcore/scrnaseq:dev
docker tag nfcore/scrnaseq:dev nfcore/scrnaseq:1.1.0

- name: Install Nextflow
env:
CAPSULE_LOG: none
Expand All @@ -55,4 +46,3 @@ jobs:
# Remember that you can parallelise this by using strategy.matrix
run: |
nextflow run ${GITHUB_WORKSPACE} -profile ${{ matrix.profile }}

23 changes: 18 additions & 5 deletions .github/workflows/linting.yml
Expand Up @@ -18,7 +18,7 @@ jobs:
- name: Install markdownlint
run: npm install -g markdownlint-cli
- name: Run Markdownlint
run: markdownlint ${GITHUB_WORKSPACE} -c ${GITHUB_WORKSPACE}/.github/markdownlint.yml
run: markdownlint .

# If the above check failed, post a comment on the PR explaining the failure
- name: Post PR comment
Expand All @@ -35,8 +35,8 @@ jobs:
* On Mac: `brew install markdownlint-cli`
* Everything else: [Install `npm`](https://www.npmjs.com/get-npm) then [install `markdownlint-cli`](https://www.npmjs.com/package/markdownlint-cli) (`npm install -g markdownlint-cli`)
* Fix the markdown errors
* Automatically: `markdownlint . --config .github/markdownlint.yml --fix`
* Manually resolve anything left from `markdownlint . --config .github/markdownlint.yml`
* Automatically: `markdownlint . --fix`
* Manually resolve anything left from `markdownlint .`

Once you push these changes the test should pass, and you can hide this comment :+1:

Expand All @@ -46,6 +46,20 @@ jobs:
repo-token: ${{ secrets.GITHUB_TOKEN }}
allow-repeats: false

EditorConfig:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- uses: actions/setup-node@v1
with:
node-version: '10'

- name: Install editorconfig-checker
run: npm install -g editorconfig-checker

- name: Run ECLint check
run: editorconfig-checker -exclude README.md $(git ls-files | grep -v test)

YAML:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -84,7 +98,6 @@ jobs:
repo-token: ${{ secrets.GITHUB_TOKEN }}
allow-repeats: false


nf-core:
runs-on: ubuntu-latest
steps:
Expand Down Expand Up @@ -114,7 +127,7 @@ jobs:
GITHUB_COMMENTS_URL: ${{ github.event.pull_request.comments_url }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_PR_COMMIT: ${{ github.event.pull_request.head.sha }}
run: nf-core -l lint_log.txt lint ${GITHUB_WORKSPACE} --markdown lint_results.md
run: nf-core -l lint_log.txt lint --dir ${GITHUB_WORKSPACE} --markdown lint_results.md

- name: Save PR number
if: ${{ always() }}
Expand Down
28 changes: 0 additions & 28 deletions .github/workflows/push_dockerhub_dev.yml

This file was deleted.