Skip to content

Commit bf7883e

Browse files
authored
Merge pull request #1265 from drpatelh/fixes
Small updates noticed during code review
2 parents 8858f7f + 9584d70 commit bf7883e

File tree

9 files changed

+126
-108
lines changed

9 files changed

+126
-108
lines changed

CHANGELOG.md

+15-11
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,8 @@ Thank you to everyone else that has contributed by reporting bugs, enhancements
4343
- [PR #1232](https://github.com/nf-core/rnaseq/pull/1232) - Add nf-test tests to star_genomegenerate_igenomes
4444
- [PR #1233](https://github.com/nf-core/rnaseq/pull/1233) - Add nf-test tests to star_align_igenomes
4545
- [PR #1234](https://github.com/nf-core/rnaseq/pull/1234) - Use genomecov from nf-core/modules
46-
- [PR #1235](https://github.com/nf-core/rnaseq/pull/1235) - Add nf-test tests to gtf_filter
47-
- [PR #1236](https://github.com/nf-core/rnaseq/pull/1236) - Add nf-test tests to utils_nfcore_rnaseq_pipeline
46+
- [PR #1235](https://github.com/nf-core/rnaseq/pull/1235) - Add nf-test tests to utils_nfcore_rnaseq_pipeline tests
47+
- [PR #1236](https://github.com/nf-core/rnaseq/pull/1236) - Add nf-test tests to gtf_filter
4848
- [PR #1237](https://github.com/nf-core/rnaseq/pull/1237) - Fix concurrency error in Github CI workflow
4949
- [PR #1238](https://github.com/nf-core/rnaseq/pull/1238) - Add nf-test tests to preprocess_transcripts_fasta_gencode
5050
- [PR #1239](https://github.com/nf-core/rnaseq/pull/1239) - Add nf-test tests to align_star
@@ -58,7 +58,8 @@ Thank you to everyone else that has contributed by reporting bugs, enhancements
5858
- [PR #1247](https://github.com/nf-core/rnaseq/pull/1247) - nf-test prepare_genome
5959
- [PR #1249](https://github.com/nf-core/rnaseq/pull/1249) - Include nf-tests for rsem_merge_counts module
6060
- [PR #1250](https://github.com/nf-core/rnaseq/pull/1250) - Remove all tags.yml files because the testing system has changed
61-
- [PR #1251](https://github.com/nf-core/rnaseq/pull/1251) - Replace deseq2qc paths
61+
- [PR #1251](https://github.com/nf-core/rnaseq/pull/1251) - Replace deseq2_qc paths
62+
- [PR #1265](https://github.com/nf-core/rnaseq/pull/1265) - Small updates noticed during code review
6263

6364
### Parameters
6465

@@ -68,14 +69,17 @@ Thank you to everyone else that has contributed by reporting bugs, enhancements
6869

6970
### Software dependencies
7071

71-
| Dependency | Old version | New version |
72-
| ----------- | ----------- | ----------- |
73-
| `bedtools` | 2.30.0 | 2.31.1 |
74-
| `multiqc` | 1.20 | 1.21 |
75-
| `picard` | 3.0.0 | 3.1.1 |
76-
| `samtools` | 1.17 | 1.19.2 |
77-
| `sortmerna` | 4.3.4 | 4.3.6 |
78-
| `umi_tools` | 1.14 | 1.15 |
72+
| Dependency | Old version | New version |
73+
| ----------------------------------- | ----------- | ----------- |
74+
| `bedtools` | 2.30.0 | 2.31.1 |
75+
| `bioconductor-dupradar` | 1.28.0 | 1.32.0 |
76+
| `bioconductor-summarizedexperiment` | 1.24.0 | 1.32.0 |
77+
| `bioconductor-tximeta` | 1.12.0 | 1.20.1 |
78+
| `multiqc` | 1.20 | 1.21 |
79+
| `picard` | 3.0.0 | 3.1.1 |
80+
| `samtools` | 1.17 | 1.19.2 |
81+
| `sortmerna` | 4.3.4 | 4.3.6 |
82+
| `umi_tools` | 1.14 | 1.15 |
7983

8084
> **NB:** Dependency has been **updated** if both old and new version information is present.
8185
>

modules/nf-core/bedtools/genomecov/nextflow.config

-19
This file was deleted.

subworkflows/local/prepare_genome/main.nf

+10-10
Original file line numberDiff line numberDiff line change
@@ -135,13 +135,13 @@ workflow PREPARE_GENOME {
135135
ch_add_fasta = Channel.value(file(additional_fasta))
136136
}
137137

138-
CUSTOM_CATADDITIONALFASTA(
139-
ch_fasta.combine(ch_gtf).map{fasta, gtf -> [[:], fasta, gtf]},
140-
ch_add_fasta.map{[[:], it]},
138+
CUSTOM_CATADDITIONALFASTA (
139+
ch_fasta.combine(ch_gtf).map { fasta, gtf -> [ [:], fasta, gtf ] },
140+
ch_add_fasta.map { [ [:], it ] },
141141
biotype
142142
)
143-
ch_fasta = CUSTOM_CATADDITIONALFASTA.out.fasta.map{it[1]}.first()
144-
ch_gtf = CUSTOM_CATADDITIONALFASTA.out.gtf.map{it[1]}.first()
143+
ch_fasta = CUSTOM_CATADDITIONALFASTA.out.fasta.map { it[1] }.first()
144+
ch_gtf = CUSTOM_CATADDITIONALFASTA.out.gtf.map { it[1] }.first()
145145
ch_versions = ch_versions.mix(CUSTOM_CATADDITIONALFASTA.out.versions)
146146
}
147147

@@ -232,20 +232,20 @@ workflow PREPARE_GENOME {
232232
if (sortmerna_index) {
233233
if (sortmerna_index.endsWith('.tar.gz')) {
234234
ch_sortmerna_index = UNTAR_SORTMERNA_INDEX ( [ [:], sortmerna_index ] ).untar.map { it[1] }
235-
ch_versions = ch_versions.mix(UNTAR_SORTMERNA_INDEX.out.versions)
235+
ch_versions = ch_versions.mix(UNTAR_SORTMERNA_INDEX.out.versions)
236236
} else {
237237
ch_sortmerna_index = Channel.value(file(sortmerna_index))
238238
}
239239
} else {
240240
ch_sortmerna_fastas = Channel.from(file(sortmerna_fasta_list).readLines())
241241
.map { row -> file(row, checkIfExists: true) }
242242
.collect()
243-
.map{ ['rrna_refs', it] }
243+
.map { [ 'rrna_refs', it ] }
244244

245245
SORTMERNA_INDEX (
246-
Channel.of([[],[]]),
246+
Channel.of([ [],[] ]),
247247
ch_sortmerna_fastas,
248-
Channel.of([[],[]])
248+
Channel.of([ [],[] ])
249249
)
250250
ch_sortmerna_index = SORTMERNA_INDEX.out.index.first()
251251
ch_versions = ch_versions.mix(SORTMERNA_INDEX.out.versions)
@@ -356,7 +356,7 @@ workflow PREPARE_GENOME {
356356
}
357357
} else {
358358
if ('kallisto' in prepare_tool_indices) {
359-
ch_kallisto_index = KALLISTO_INDEX ( ch_transcript_fasta.map{[ [:], it]} ).index
359+
ch_kallisto_index = KALLISTO_INDEX ( ch_transcript_fasta.map { [ [:], it] } ).index
360360
ch_versions = ch_versions.mix(KALLISTO_INDEX.out.versions)
361361
}
362362
}

subworkflows/local/quantify_pseudo_alignment/main.nf

+35-21
Original file line numberDiff line numberDiff line change
@@ -35,28 +35,42 @@ workflow QUANTIFY_PSEUDO_ALIGNMENT {
3535
//
3636
// NOTE: MultiQC needs Salmon outputs, but Kallisto logs
3737
if (pseudo_aligner == 'salmon') {
38-
SALMON_QUANT ( reads, index, gtf, transcript_fasta, alignment_mode, lib_type )
38+
SALMON_QUANT (
39+
reads,
40+
index,
41+
gtf,
42+
transcript_fasta,
43+
alignment_mode,
44+
lib_type
45+
)
3946
ch_pseudo_results = SALMON_QUANT.out.results
4047
ch_pseudo_multiqc = ch_pseudo_results
4148
ch_versions = ch_versions.mix(SALMON_QUANT.out.versions.first())
4249
} else {
43-
KALLISTO_QUANT ( reads, index, gtf, [], kallisto_quant_fraglen, kallisto_quant_fraglen_sd)
50+
KALLISTO_QUANT (
51+
reads,
52+
index,
53+
gtf,
54+
[],
55+
kallisto_quant_fraglen,
56+
kallisto_quant_fraglen_sd
57+
)
4458
ch_pseudo_results = KALLISTO_QUANT.out.results
4559
ch_pseudo_multiqc = KALLISTO_QUANT.out.log
4660
ch_versions = ch_versions.mix(KALLISTO_QUANT.out.versions.first())
4761
}
4862

4963
CUSTOM_TX2GENE (
5064
gtf.map { [ [:], it ] },
51-
ch_pseudo_results.collect{it[1]}.map { [ [:], it ] },
65+
ch_pseudo_results.collect{ it[1] }.map { [ [:], it ] },
5266
pseudo_aligner,
5367
gtf_id_attribute,
5468
gtf_extra_attribute
5569
)
5670
ch_versions = ch_versions.mix(CUSTOM_TX2GENE.out.versions)
5771

5872
TXIMETA_TXIMPORT (
59-
ch_pseudo_results.collect{it[1]}.map { [ ['id': 'all_samples'], it ] },
73+
ch_pseudo_results.collect{ it[1] }.map { [ ['id': 'all_samples'], it ] },
6074
CUSTOM_TX2GENE.out.tx2gene,
6175
pseudo_aligner
6276
)
@@ -88,25 +102,25 @@ workflow QUANTIFY_PSEUDO_ALIGNMENT {
88102
)
89103

90104
emit:
91-
results = ch_pseudo_results // channel: [ val(meta), results_dir ]
92-
multiqc = ch_pseudo_multiqc // channel: [ val(meta), files_for_multiqc ]
93-
94-
tpm_gene = TXIMETA_TXIMPORT.out.tpm_gene // path *gene_tpm.tsv
95-
counts_gene = TXIMETA_TXIMPORT.out.counts_gene // path *gene_counts.tsv
96-
lengths_gene = TXIMETA_TXIMPORT.out.lengths_gene // path *gene_lengths.tsv
97-
counts_gene_length_scaled = TXIMETA_TXIMPORT.out.counts_gene_length_scaled // path *gene_counts_length_scaled.tsv
98-
counts_gene_scaled = TXIMETA_TXIMPORT.out.counts_gene_scaled // path *gene_counts_scaled.tsv
99-
tpm_transcript = TXIMETA_TXIMPORT.out.tpm_transcript // path *gene_tpm.tsv
100-
counts_transcript = TXIMETA_TXIMPORT.out.counts_transcript // path *transcript_counts.tsv
101-
lengths_transcript = TXIMETA_TXIMPORT.out.lengths_transcript // path *transcript_lengths.tsv
102-
103-
merged_gene_rds = SE_GENE.out.rds // path: *.rds
104-
merged_gene_rds_length_scaled = SE_GENE_LENGTH_SCALED.out.rds // path: *.rds
105-
merged_gene_rds_scaled = SE_GENE_SCALED.out.rds // path: *.rds
105+
results = ch_pseudo_results // channel: [ val(meta), results_dir ]
106+
multiqc = ch_pseudo_multiqc // channel: [ val(meta), files_for_multiqc ]
107+
108+
tpm_gene = TXIMETA_TXIMPORT.out.tpm_gene // path: *gene_tpm.tsv
109+
counts_gene = TXIMETA_TXIMPORT.out.counts_gene // path: *gene_counts.tsv
110+
lengths_gene = TXIMETA_TXIMPORT.out.lengths_gene // path: *gene_lengths.tsv
111+
counts_gene_length_scaled = TXIMETA_TXIMPORT.out.counts_gene_length_scaled // path: *gene_counts_length_scaled.tsv
112+
counts_gene_scaled = TXIMETA_TXIMPORT.out.counts_gene_scaled // path: *gene_counts_scaled.tsv
113+
tpm_transcript = TXIMETA_TXIMPORT.out.tpm_transcript // path: *gene_tpm.tsv
114+
counts_transcript = TXIMETA_TXIMPORT.out.counts_transcript // path: *transcript_counts.tsv
115+
lengths_transcript = TXIMETA_TXIMPORT.out.lengths_transcript // path: *transcript_lengths.tsv
116+
117+
merged_gene_rds = SE_GENE.out.rds // path: *.rds
118+
merged_gene_rds_length_scaled = SE_GENE_LENGTH_SCALED.out.rds // path: *.rds
119+
merged_gene_rds_scaled = SE_GENE_SCALED.out.rds // path: *.rds
106120

107121
merged_counts_transcript = TXIMETA_TXIMPORT.out.counts_transcript // path: *.transcript_counts.tsv
108122
merged_tpm_transcript = TXIMETA_TXIMPORT.out.tpm_transcript // path: *.transcript_tpm.tsv
109-
merged_transcript_rds = SE_TRANSCRIPT.out.rds // path: *.rds
123+
merged_transcript_rds = SE_TRANSCRIPT.out.rds // path: *.rds
110124

111-
versions = ch_versions // channel: [ versions.yml ]
125+
versions = ch_versions // channel: [ versions.yml ]
112126
}

subworkflows/local/utils_nfcore_rnaseq_pipeline/main.nf

+5-1
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,10 @@ workflow PIPELINE_COMPLETION {
115115
imNotification(summary_params, hook_url)
116116
}
117117
}
118+
119+
workflow.onError {
120+
log.error "Pipeline failed. Please refer to troubleshooting docs: https://nf-co.re/docs/usage/troubleshooting"
121+
}
118122
}
119123

120124
/*
@@ -126,7 +130,7 @@ workflow PIPELINE_COMPLETION {
126130
//
127131
// Function to check samples are internally consistent after being grouped
128132
//
129-
def checkSamplesAreConsistent(input) {
133+
def checkSamplesAfterGrouping(input) {
130134
def (metas, fastqs) = input[1..2]
131135

132136
// Check that multiple runs of the same sample are of the same strandedness

subworkflows/local/utils_nfcore_rnaseq_pipeline/tests/main.function.nf.test

+6-6
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@ nextflow_function {
33
name "Test Functions"
44
script "../main.nf"
55

6-
test("Test Function checkSamplesAreConsistent success") {
6+
test("Test Function checkSamplesAfterGrouping success") {
77

8-
function "checkSamplesAreConsistent"
8+
function "checkSamplesAfterGrouping"
99

1010
when {
1111
function {
@@ -34,9 +34,9 @@ nextflow_function {
3434

3535
}
3636

37-
test("Test Function checkSamplesAreConsistent invalid strandedness") {
37+
test("Test Function checkSamplesAfterGrouping invalid strandedness") {
3838

39-
function "checkSamplesAreConsistent"
39+
function "checkSamplesAfterGrouping"
4040

4141
when {
4242
function {
@@ -65,9 +65,9 @@ nextflow_function {
6565

6666
}
6767

68-
test("Test Function checkSamplesAreConsistent invalid endedness") {
68+
test("Test Function checkSamplesAfterGrouping invalid endedness") {
6969

70-
function "checkSamplesAreConsistent"
70+
function "checkSamplesAfterGrouping"
7171

7272
when {
7373
function {

subworkflows/local/utils_nfcore_rnaseq_pipeline/tests/main.function.nf.test.snap

+3-3
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@
6363
},
6464
"timestamp": "2024-03-06T14:33:46.772392"
6565
},
66-
"Test Function checkSamplesAreConsistent invalid strandedness": {
66+
"Test Function checkSamplesAfterGrouping invalid strandedness": {
6767
"content": null,
6868
"meta": {
6969
"nf-test": "0.8.4",
@@ -143,7 +143,7 @@
143143
},
144144
"timestamp": "2024-03-06T14:33:43.671826"
145145
},
146-
"Test Function checkSamplesAreConsistent success": {
146+
"Test Function checkSamplesAfterGrouping success": {
147147
"content": [
148148
[
149149
{
@@ -167,7 +167,7 @@
167167
},
168168
"timestamp": "2024-03-06T14:32:37.450298"
169169
},
170-
"Test Function checkSamplesAreConsistent invalid endedness": {
170+
"Test Function checkSamplesAfterGrouping invalid endedness": {
171171
"content": null,
172172
"meta": {
173173
"nf-test": "0.8.4",

0 commit comments

Comments
 (0)