Release 5.4.2#1005
Conversation
Post 5.4.1 release bump
Update GUNC modules and enable it in `test_assembly_input`
fix: include all binners in dastool validation
fix: busco exit and publish dir
Bump version for release v5.4.2
|
Co-authored-by: OpenAI Codex <codex@openai.com>
|
Will look when the citations/gunc csv stability is merged in |
Use qsv/cat for merging GUNC summaries
Add citations and clean TODOs
Joon-Klaps
left a comment
There was a problem hiding this comment.
1 outdated doc & A minor suggestion for easier maintainability.
Everything else looks good.
| withName: GUNC_RUN { | ||
| publishDir = [ | ||
| path: { "${params.outdir}/GenomeBinning/QC/GUNC/raw/${meta.assembler}-${meta.binner}-${meta.domain}-${meta.refinement}-${meta.id}/${fasta.baseName}/" }, | ||
| path: { "${params.outdir}/GenomeBinning/QC/GUNC/raw/${meta.assembler}-${meta.binner}-${meta.domain}-${meta.refinement}-${meta.id}/" }, |
There was a problem hiding this comment.
Docs still stay it's in the dir with fasta basename
There was a problem hiding this comment.
I believe it's ok, but I also believe it will be very hard to maintain.
What if you defined a list of citations. and select those tools that are present in the versions channel?
def toolCitationList() {
return [
["fastqc", "Sequencing quality control was performed with FastQC (Andrews 2010)."],
["multiqc", "Pipeline results statistics were summarised with MultiQC (Ewels et al. 2016)."],
["megahit", "Metagenome assembly was performed with MEGAHIT (Li et al. 2016)."],
["metabat2", "Metagenome binning was performed with MetaBAT2 (Kang et al. 2019)."],
// ...
]
}And merge it with our versions channel?
def toolCitationText(ch_collated_versions) {
def ch_citation_map = channel.fromList(toolCitationList()) // [tool, citation]
ch_collated_versions
.splitText()
.map { line -> line.trim() }
.filter { line -> line.startsWith(' ') && line.endsWith(':') } // indented tool lines only
.map { line -> line.replace(':', '').trim().toLowerCase() }
.unique()
.combine(ch_citation_map) // [tool_found, tool_key, citation]
.filter { tool_found, tool_key, citation -> tool_found == tool_key }
.map { tool_found, tool_key, citation -> citation }
.collect()
.map { citations -> citations.sort().join('\n') }
}Can also use a dictionary and do like
ch_collated_versions
.splitText()
.map { line -> line.trim() }
.filter { line -> line.startsWith(' ') && line.endsWith(':') } // indented tool lines only
.map { line ->
def tool = line.replace(':', '').trim().toLowerCase()
def citation = citation_map.get(tool)
if (!citation) {
log.warn("[nf-core/mag] No citation mapped for tool: ${tool}")
}
return citation
.filter { it != null }
.unique()
.collect()
.map { citations -> citations.sort().join('\n') }Note this was vibe-coded in a chat with Claude; didn't actually check it works.
There was a problem hiding this comment.
This seems an interesting idea, but I think it will look cleaner when we migrate everything to topics.
One we complete that migration, I'm going to give it a go.
Address review commentws on #1005
| publishDir = [ | ||
| path: { "${params.outdir}/GenomeBinning/QC" }, | ||
| mode: params.publish_dir_mode, | ||
| saveAs: { filename -> filename.equals('versions.yml') ? null : filename }, |
There was a problem hiding this comment.
Won't this pick up versions files? Why the removal? Or becauset opics?
There was a problem hiding this comment.
Because topics. I will start cleaning those lines as we update the modules to use topics :D
Addedutils_nfcore_mag_pipelinesubworkflow (by @dialvarezs)ChangedcollectFilewithqsv/caton GUNC summary merging (by @dialvarezs)FixedDependencies