diff --git a/CHANGELOG.md b/CHANGELOG.md index 0fa237ad..a8fc4eae 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,6 +12,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### `Fixed` - [#655](https://github.com/nf-core/ampliseq/pull/655) - Added `NUMBA_CACHE_DIR` to fix downstream analysis with QIIME2 that failed on some systems +- [#656](https://github.com/nf-core/ampliseq/pull/656) - Moved conda-check to script-section and replaced `exit 1` with `error()` ### `Dependencies` diff --git a/modules/local/qiime2_alphararefaction.nf b/modules/local/qiime2_alphararefaction.nf index c37a8d57..23dfe602 100644 --- a/modules/local/qiime2_alphararefaction.nf +++ b/modules/local/qiime2_alphararefaction.nf @@ -3,11 +3,6 @@ process QIIME2_ALPHARAREFACTION { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: path(metadata) path(table) @@ -22,6 +17,10 @@ process QIIME2_ALPHARAREFACTION { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } """ export XDG_CONFIG_HOME="./xdgconfig" export MPLCONFIGDIR="./mplconfigdir" diff --git a/modules/local/qiime2_ancom_asv.nf b/modules/local/qiime2_ancom_asv.nf index c5ee19a3..c6584f0a 100644 --- a/modules/local/qiime2_ancom_asv.nf +++ b/modules/local/qiime2_ancom_asv.nf @@ -7,11 +7,6 @@ process QIIME2_ANCOM_ASV { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: tuple path(metadata), path(table) @@ -23,6 +18,10 @@ process QIIME2_ANCOM_ASV { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } """ export XDG_CONFIG_HOME="./xdgconfig" export MPLCONFIGDIR="./mplconfigdir" diff --git a/modules/local/qiime2_ancom_tax.nf b/modules/local/qiime2_ancom_tax.nf index 1c5eccc8..1e3d320b 100644 --- a/modules/local/qiime2_ancom_tax.nf +++ b/modules/local/qiime2_ancom_tax.nf @@ -5,11 +5,6 @@ process QIIME2_ANCOM_TAX { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: tuple path(metadata), path(table), path(taxonomy) ,val(taxlevel) @@ -21,6 +16,10 @@ process QIIME2_ANCOM_TAX { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } """ export XDG_CONFIG_HOME="./xdgconfig" export MPLCONFIGDIR="./mplconfigdir" diff --git a/modules/local/qiime2_barplot.nf b/modules/local/qiime2_barplot.nf index cea39171..55596db5 100644 --- a/modules/local/qiime2_barplot.nf +++ b/modules/local/qiime2_barplot.nf @@ -3,11 +3,6 @@ process QIIME2_BARPLOT { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: path(metadata) path(table) @@ -22,6 +17,10 @@ process QIIME2_BARPLOT { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } suffix = setting ? "_${table.baseName}" : "" def metadata_cmd = metadata ? "--m-metadata-file ${metadata}": "" """ diff --git a/modules/local/qiime2_classify.nf b/modules/local/qiime2_classify.nf index a84bde40..4b89cdb2 100644 --- a/modules/local/qiime2_classify.nf +++ b/modules/local/qiime2_classify.nf @@ -4,11 +4,6 @@ process QIIME2_CLASSIFY { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: path(trained_classifier) path(repseq) @@ -22,6 +17,10 @@ process QIIME2_CLASSIFY { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } """ export XDG_CONFIG_HOME="./xdgconfig" export MPLCONFIGDIR="./mplconfigdir" diff --git a/modules/local/qiime2_diversity_adonis.nf b/modules/local/qiime2_diversity_adonis.nf index 23016923..0672aa4f 100644 --- a/modules/local/qiime2_diversity_adonis.nf +++ b/modules/local/qiime2_diversity_adonis.nf @@ -4,11 +4,6 @@ process QIIME2_DIVERSITY_ADONIS { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: tuple path(metadata), path(core), val(formula) @@ -20,6 +15,10 @@ process QIIME2_DIVERSITY_ADONIS { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } def args = task.ext.args ?: '' """ export XDG_CONFIG_HOME="./xdgconfig" diff --git a/modules/local/qiime2_diversity_alpha.nf b/modules/local/qiime2_diversity_alpha.nf index 5062b74b..743ed518 100644 --- a/modules/local/qiime2_diversity_alpha.nf +++ b/modules/local/qiime2_diversity_alpha.nf @@ -4,11 +4,6 @@ process QIIME2_DIVERSITY_ALPHA { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: tuple path(metadata), path(core) @@ -20,6 +15,10 @@ process QIIME2_DIVERSITY_ALPHA { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } """ export XDG_CONFIG_HOME="./xdgconfig" export MPLCONFIGDIR="./mplconfigdir" diff --git a/modules/local/qiime2_diversity_beta.nf b/modules/local/qiime2_diversity_beta.nf index 2e0d5864..c48b6b4c 100644 --- a/modules/local/qiime2_diversity_beta.nf +++ b/modules/local/qiime2_diversity_beta.nf @@ -4,11 +4,6 @@ process QIIME2_DIVERSITY_BETA { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: tuple path(metadata), path(core), val(category) @@ -20,6 +15,10 @@ process QIIME2_DIVERSITY_BETA { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } """ export XDG_CONFIG_HOME="./xdgconfig" export MPLCONFIGDIR="./mplconfigdir" diff --git a/modules/local/qiime2_diversity_betaord.nf b/modules/local/qiime2_diversity_betaord.nf index ad6d8266..658cf765 100644 --- a/modules/local/qiime2_diversity_betaord.nf +++ b/modules/local/qiime2_diversity_betaord.nf @@ -4,11 +4,6 @@ process QIIME2_DIVERSITY_BETAORD { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: tuple path(metadata), path(core) @@ -20,6 +15,10 @@ process QIIME2_DIVERSITY_BETAORD { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } """ export XDG_CONFIG_HOME="./xdgconfig" export MPLCONFIGDIR="./mplconfigdir" diff --git a/modules/local/qiime2_diversity_core.nf b/modules/local/qiime2_diversity_core.nf index d0569d87..b06fd523 100644 --- a/modules/local/qiime2_diversity_core.nf +++ b/modules/local/qiime2_diversity_core.nf @@ -3,11 +3,6 @@ process QIIME2_DIVERSITY_CORE { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: path(metadata) path(table) @@ -26,6 +21,10 @@ process QIIME2_DIVERSITY_CORE { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } """ # FIX: detecting a viable GPU on your system, but the GPU is unavailable for compute, causing UniFrac to fail. # COMMENT: might be fixed in version after QIIME2 2023.5 diff --git a/modules/local/qiime2_export_absolute.nf b/modules/local/qiime2_export_absolute.nf index 5e217f4a..bf9c947e 100644 --- a/modules/local/qiime2_export_absolute.nf +++ b/modules/local/qiime2_export_absolute.nf @@ -3,11 +3,6 @@ process QIIME2_EXPORT_ABSOLUTE { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: path(table) path(repseq) @@ -28,6 +23,10 @@ process QIIME2_EXPORT_ABSOLUTE { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } """ export XDG_CONFIG_HOME="./xdgconfig" export MPLCONFIGDIR="./mplconfigdir" diff --git a/modules/local/qiime2_export_relasv.nf b/modules/local/qiime2_export_relasv.nf index 85eedcda..19977f5e 100644 --- a/modules/local/qiime2_export_relasv.nf +++ b/modules/local/qiime2_export_relasv.nf @@ -3,11 +3,6 @@ process QIIME2_EXPORT_RELASV { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: path(table) @@ -19,6 +14,10 @@ process QIIME2_EXPORT_RELASV { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } """ export XDG_CONFIG_HOME="./xdgconfig" export MPLCONFIGDIR="./mplconfigdir" diff --git a/modules/local/qiime2_export_reltax.nf b/modules/local/qiime2_export_reltax.nf index 4b287917..6309e674 100644 --- a/modules/local/qiime2_export_reltax.nf +++ b/modules/local/qiime2_export_reltax.nf @@ -3,11 +3,6 @@ process QIIME2_EXPORT_RELTAX { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: path(table) path(taxonomy) @@ -22,6 +17,10 @@ process QIIME2_EXPORT_RELTAX { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } """ export XDG_CONFIG_HOME="./xdgconfig" export MPLCONFIGDIR="./mplconfigdir" diff --git a/modules/local/qiime2_extract.nf b/modules/local/qiime2_extract.nf index 9e4bf2fa..f3a61b6e 100644 --- a/modules/local/qiime2_extract.nf +++ b/modules/local/qiime2_extract.nf @@ -5,11 +5,6 @@ process QIIME2_EXTRACT { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: tuple val(meta), path(database) @@ -21,6 +16,10 @@ process QIIME2_EXTRACT { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } """ export XDG_CONFIG_HOME="./xdgconfig" export MPLCONFIGDIR="./mplconfigdir" diff --git a/modules/local/qiime2_featuretable_group.nf b/modules/local/qiime2_featuretable_group.nf index eacb4d61..0890a5f2 100644 --- a/modules/local/qiime2_featuretable_group.nf +++ b/modules/local/qiime2_featuretable_group.nf @@ -4,11 +4,6 @@ process QIIME2_FEATURETABLE_GROUP { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: tuple path(table), path(metadata), val(category) @@ -20,6 +15,10 @@ process QIIME2_FEATURETABLE_GROUP { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } """ export XDG_CONFIG_HOME="./xdgconfig" export MPLCONFIGDIR="./mplconfigdir" diff --git a/modules/local/qiime2_filtersamples.nf b/modules/local/qiime2_filtersamples.nf index 01c9c11a..46a58529 100644 --- a/modules/local/qiime2_filtersamples.nf +++ b/modules/local/qiime2_filtersamples.nf @@ -4,11 +4,6 @@ process QIIME2_FILTERSAMPLES { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: tuple path(metadata), path(table), val(filter) @@ -20,6 +15,10 @@ process QIIME2_FILTERSAMPLES { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } def args = task.ext.args ?: "--p-where \'${filter}<>\"\"\'" def prefix = task.ext.prefix ?: "${filter}" """ diff --git a/modules/local/qiime2_filtertaxa.nf b/modules/local/qiime2_filtertaxa.nf index 3ea8828e..404552dd 100644 --- a/modules/local/qiime2_filtertaxa.nf +++ b/modules/local/qiime2_filtertaxa.nf @@ -4,11 +4,6 @@ process QIIME2_FILTERTAXA { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: path(table) path(repseq) @@ -27,6 +22,10 @@ process QIIME2_FILTERTAXA { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } """ export XDG_CONFIG_HOME="./xdgconfig" export MPLCONFIGDIR="./mplconfigdir" diff --git a/modules/local/qiime2_inasv.nf b/modules/local/qiime2_inasv.nf index 68c08d58..4ef660d7 100644 --- a/modules/local/qiime2_inasv.nf +++ b/modules/local/qiime2_inasv.nf @@ -4,11 +4,6 @@ process QIIME2_INASV { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: path(asv) @@ -20,6 +15,10 @@ process QIIME2_INASV { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } """ export MPLCONFIGDIR="./mplconfigdir" export NUMBA_CACHE_DIR="./numbacache" diff --git a/modules/local/qiime2_inseq.nf b/modules/local/qiime2_inseq.nf index a11529a3..53b43970 100644 --- a/modules/local/qiime2_inseq.nf +++ b/modules/local/qiime2_inseq.nf @@ -4,11 +4,6 @@ process QIIME2_INSEQ { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: path(seq) @@ -20,6 +15,10 @@ process QIIME2_INSEQ { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } """ export MPLCONFIGDIR="./mplconfigdir" export NUMBA_CACHE_DIR="./numbacache" diff --git a/modules/local/qiime2_intax.nf b/modules/local/qiime2_intax.nf index cb7e7269..1b1ce8b4 100644 --- a/modules/local/qiime2_intax.nf +++ b/modules/local/qiime2_intax.nf @@ -4,11 +4,6 @@ process QIIME2_INTAX { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: path(tax) //ASV_tax_species.tsv val(script) @@ -21,6 +16,10 @@ process QIIME2_INTAX { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } def script_cmd = script ? "$script $tax" : "cp $tax tax.tsv" """ export MPLCONFIGDIR="./mplconfigdir" diff --git a/modules/local/qiime2_intree.nf b/modules/local/qiime2_intree.nf index 817e2a7b..70d48331 100644 --- a/modules/local/qiime2_intree.nf +++ b/modules/local/qiime2_intree.nf @@ -4,11 +4,6 @@ process QIIME2_INTREE { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: tuple val(meta), path(tree) @@ -20,6 +15,10 @@ process QIIME2_INTREE { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } """ export MPLCONFIGDIR="./mplconfigdir" export NUMBA_CACHE_DIR="./numbacache" diff --git a/modules/local/qiime2_train.nf b/modules/local/qiime2_train.nf index 48174e3c..ca763c50 100644 --- a/modules/local/qiime2_train.nf +++ b/modules/local/qiime2_train.nf @@ -5,11 +5,6 @@ process QIIME2_TRAIN { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: tuple val(meta), path(qza) @@ -21,6 +16,10 @@ process QIIME2_TRAIN { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } """ export XDG_CONFIG_HOME="./xdgconfig" export MPLCONFIGDIR="./mplconfigdir" diff --git a/modules/local/qiime2_tree.nf b/modules/local/qiime2_tree.nf index a595b64a..d8b9cff8 100644 --- a/modules/local/qiime2_tree.nf +++ b/modules/local/qiime2_tree.nf @@ -3,11 +3,6 @@ process QIIME2_TREE { container "qiime2/core:2023.7" - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - exit 1, "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." - } - input: path(repseq) @@ -20,6 +15,10 @@ process QIIME2_TREE { task.ext.when == null || task.ext.when script: + // Exit if running this module with -profile conda / -profile mamba + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { + error "QIIME2 does not support Conda. Please use Docker / Singularity / Podman instead." + } """ export XDG_CONFIG_HOME="./xdgconfig" export MPLCONFIGDIR="./mplconfigdir"