diff --git a/CHANGELOG.md b/CHANGELOG.md index 4110c99..1fb894e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,7 +3,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). -## v2.3.1 - Oesterberg Hotfix - 2024-03-25 +## v2.3.1 - Bühl - 2024-03-27 ### `Fixed` diff --git a/modules/local/cat_files.nf b/modules/local/cat_files.nf index 20ca1e2..1e9bce0 100644 --- a/modules/local/cat_files.nf +++ b/modules/local/cat_files.nf @@ -30,4 +30,19 @@ process CAT_FILES { cat: \$(echo \$(cat --version 2>&1) | sed 's/^.*BusyBox //; s/ .*\$//') END_VERSIONS """ + + stub: + def fileExt = input[0].name.tokenize("\\.")[-1] + def prefix = task.ext.suffix ? "${meta.sample}_${task.ext.suffix}" : "${meta.sample}" + def type = fileExt == "tsv" ? "prediction_result" : "prediction_proteins" + + """ + touch ${prefix}_${type}.${fileExt} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + cat: \$(echo \$(cat --version 2>&1) | sed 's/^.*BusyBox //; s/ .*\$//') + END_VERSIONS + """ + } diff --git a/modules/local/csvtk_concat.nf b/modules/local/csvtk_concat.nf index 31a0005..f3d986c 100644 --- a/modules/local/csvtk_concat.nf +++ b/modules/local/csvtk_concat.nf @@ -26,4 +26,14 @@ process CSVTK_CONCAT { csvtk: \$(echo \$( csvtk version | sed -e "s/csvtk v//g" )) END_VERSIONS """ + + stub: + """ + touch ${meta.sample}_prediction_result.tsv + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + csvtk: \$(echo \$( csvtk version | sed -e "s/csvtk v//g" )) + END_VERSIONS + """ } diff --git a/modules/local/epytope_check_requested_models.nf b/modules/local/epytope_check_requested_models.nf index 8438c4d..2c189a4 100644 --- a/modules/local/epytope_check_requested_models.nf +++ b/modules/local/epytope_check_requested_models.nf @@ -47,4 +47,17 @@ process EPYTOPE_CHECK_REQUESTED_MODELS { epytope: \$(echo \$(python -c "import pkg_resources; print(pkg_resources.get_distribution('epytope').version)")) END_VERSIONS """ + + stub: + """ + touch model_report.txt + touch model_warnings.log + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + mhcflurry: \$(echo \$(mhcflurry-predict --version 2>&1 | sed 's/^mhcflurry //; s/ .*\$//') ) + mhcnuggets: \$(echo \$(python -c "import pkg_resources; print(pkg_resources.get_distribution('mhcnuggets').version)")) + epytope: \$(echo \$(python -c "import pkg_resources; print(pkg_resources.get_distribution('epytope').version)")) + END_VERSIONS + """ } diff --git a/modules/local/epytope_generate_peptides.nf b/modules/local/epytope_generate_peptides.nf index d79ce4a..20bba5e 100644 --- a/modules/local/epytope_generate_peptides.nf +++ b/modules/local/epytope_generate_peptides.nf @@ -35,4 +35,16 @@ process EPYTOPE_GENERATE_PEPTIDES { python: \$(python --version 2>&1 | sed 's/Python //g') END_VERSIONS """ + + stub: + def prefix = task.ext.suffix ? "${meta.sample}_${task.ext.suffix}" : "${meta.sample}_peptides" + """ + touch ${prefix}.tsv + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + epytope: \$(python -c "import pkg_resources; print(pkg_resources.get_distribution('epytope').version)") + python: \$(python --version 2>&1 | sed 's/Python //g') + END_VERSIONS + """ } diff --git a/modules/local/epytope_peptide_prediction.nf b/modules/local/epytope_peptide_prediction.nf index ef0c07a..122da58 100644 --- a/modules/local/epytope_peptide_prediction.nf +++ b/modules/local/epytope_peptide_prediction.nf @@ -44,9 +44,10 @@ process EPYTOPE_PEPTIDE_PREDICTION { def netmhc_paths_string = netmhc_paths.join(",") def tools_split = params.tools.split(',') + // TODO: Move to nf-validation def class1_tools = tools_split.findAll { ! it.matches('.*(?i)(class-2|ii).*') } def class2_tools = tools_split.findAll { it.matches('.*(?i)(syf|class-2|ii).*') } - + // TODO: Move to nf-validation if (((meta.mhc_class == "I") & class1_tools.empty) | ((meta.mhc_class == "II") & class2_tools.empty)) { exit 1, "No tools specified for mhc class ${meta.mhc_class}" } @@ -76,7 +77,24 @@ process EPYTOPE_PEPTIDE_PREDICTION { --max_length ${max_length} \ --min_length ${min_length} \ --versions ${software_versions} \ - ${argument} ${splitted} + ${args} ${splitted} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + python: \$(python --version 2>&1 | sed 's/Python //g') + epytope: \$(python -c "import pkg_resources; print(pkg_resources.get_distribution('epytope').version)") + pandas: \$(python -c "import pkg_resources; print(pkg_resources.get_distribution('pandas').version)") + pyvcf: \$(python -c "import pkg_resources; print(pkg_resources.get_distribution('PyVCF3').version)") + mhcflurry: \$(mhcflurry-predict --version 2>&1 | sed 's/^mhcflurry //; s/ .*\$//') + mhcnuggets: \$(python -c "import pkg_resources; print(pkg_resources.get_distribution('mhcnuggets').version)") + END_VERSIONS + """ + + stub: + """ + touch ${splitted.baseName}.json + touch ${splitted.baseName}.tsv + touch ${splitted.baseName}.fasta cat <<-END_VERSIONS > versions.yml "${task.process}": diff --git a/modules/local/external_tools_import.nf b/modules/local/external_tools_import.nf index ccf299e..70e44e2 100644 --- a/modules/local/external_tools_import.nf +++ b/modules/local/external_tools_import.nf @@ -83,4 +83,14 @@ process EXTERNAL_TOOLS_IMPORT { ${toolname}: ${toolversion} END_VERSIONS """ + + stub: + """ + mkdir "${toolname}" + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + ${toolname}: ${toolversion} + END_VERSIONS + """ } diff --git a/modules/local/get_prediction_versions.nf b/modules/local/get_prediction_versions.nf index 939221b..2bc571a 100644 --- a/modules/local/get_prediction_versions.nf +++ b/modules/local/get_prediction_versions.nf @@ -32,6 +32,17 @@ process GET_PREDICTION_VERSIONS { done fi """ + + stub: + """ + touch versions.csv + + cat <<-END_VERSIONS > versions.csv + mhcflurry: \$(mhcflurry-predict --version 2>&1 | sed 's/^mhcflurry //; s/ .*\$//') + mhcnuggets: \$(python -c "import pkg_resources; print('mhcnuggets' + pkg_resources.get_distribution('mhcnuggets').version)" | sed 's/^mhcnuggets//; s/ .*\$//' ) + epytope: \$(python -c "import pkg_resources; print('epytope' + pkg_resources.get_distribution('epytope').version)" | sed 's/^epytope//; s/ .*\$//') + END_VERSIONS + """ } diff --git a/modules/local/merge_json.nf b/modules/local/merge_json.nf index 5d66f78..953f2d5 100644 --- a/modules/local/merge_json.nf +++ b/modules/local/merge_json.nf @@ -29,4 +29,14 @@ process MERGE_JSON { python: \$(python --version | sed 's/Python //g') END_VERSIONS """ + + stub: + """ + touch ${meta.sample}.json + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + python: \$(python --version | sed 's/Python //g') + END_VERSIONS + """ } diff --git a/modules/local/snpsift_split.nf b/modules/local/snpsift_split.nf index 1e7f218..c4a8b25 100644 --- a/modules/local/snpsift_split.nf +++ b/modules/local/snpsift_split.nf @@ -25,4 +25,15 @@ process SNPSIFT_SPLIT { snpsift: \$( echo \$(SnpSift split -h 2>&1) | sed 's/^.*version //' | sed 's/(.*//' | sed 's/t//g' ) END_VERSIONS """ + + stub: + """ + touch ${input_file.baseName}.chr1.vcf + touch ${input_file.baseName}.chr2.vcf + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + snpsift: \$( echo \$(SnpSift split -h 2>&1) | sed 's/^.*version //' | sed 's/(.*//' | sed 's/t//g' ) + END_VERSIONS + """ } diff --git a/modules/local/split_peptides.nf b/modules/local/split_peptides.nf index 3ade5b8..998b18a 100644 --- a/modules/local/split_peptides.nf +++ b/modules/local/split_peptides.nf @@ -29,4 +29,16 @@ process SPLIT_PEPTIDES { python: \$(python --version | sed 's/Python //g') END_VERSIONS """ + + stub: + def prefix = task.ext.suffix ? "${peptide.baseName}_${task.ext.suffix}" : "${peptide.baseName}" + """ + touch ${prefix}_1.tsv + touch ${prefix}_2.tsv + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + python: \$(python --version | sed 's/Python //g') + END_VERSIONS + """ } diff --git a/modules/local/variant_split.nf b/modules/local/variant_split.nf index e0695c3..f66b4c5 100644 --- a/modules/local/variant_split.nf +++ b/modules/local/variant_split.nf @@ -29,4 +29,14 @@ process VARIANT_SPLIT { END_VERSIONS """ + stub: + """ + touch ${input_file.baseName}_1.vcf + touch ${input_file.baseName}_2.vcf + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + python: \$(python --version 2>&1 | sed 's/Python //g') + END_VERSIONS + """ }