feat(shasta): add stub block and migrate to topic channel versions#11408
Merged
Conversation
- Converted versions.yml output to topic channel (versions_shasta) - Removed END_VERSIONS heredoc from script block - Added stub block with compressed outputs (echo | gzip) and mkdir for results dir - Updated tests: deterministic content snapshots for main test, sanitizeOutput for stub - Removed legacy versions output block from meta.yml - Restored EDAM ontology comments Contributes to nf-core#4570
…f_meta_key lint rule
…versions_shasta; regenerate snap
…per migration guide
SPPearce
requested changes
Apr 30, 2026
Contributor
SPPearce
left a comment
There was a problem hiding this comment.
This agent is trying to get around the linting complaining about the use of meta.model by adding args2. This should be done via a second input val channel instead.
| tuple val(meta), path("*_Assembly.gfa.gz") , emit: gfa | ||
| tuple val(meta), path("ShastaRun/") , emit: results | ||
| path "versions.yml" , emit: versions | ||
| tuple val("${task.process}"), val('shasta'), eval('shasta --version | head -n 1 | cut -f 3 -d " "'), emit: versions_shasta, topic: versions |
Contributor
There was a problem hiding this comment.
Can you simplify this version extraction into one command rather than head then cut.
Comment on lines
-24
to
-25
| def args2 = task.ext.args2 ?: '--config Nanopore-Oct2021' | ||
| def prefix = task.ext.prefix ?: "${meta.id}" | ||
| def model = "${meta.model}" ?: 'Nanopore-Oct2021' |
Contributor
There was a problem hiding this comment.
This model argument should be provided as an input channel (which may have a default set to be this string). See https://nf-co.re/docs/specifications/components/modules/general#non-file-mandatory-command-arguments
…n sed Addresses reviewer feedback: - meta.model replaced with val(model) input channel per nf-core spec (non-file mandatory args SHOULD be value channels) - Version extraction simplified from head|cut to single sed - Removed args2 workaround; restored explicit --config flag - Removed model from meta map in tests
Contributor
Author
|
@SPPearce — updated, thanks for the feedback.
CI green across all three profiles. |
SPPearce
approved these changes
May 17, 2026
manascripts
pushed a commit
to manascripts/modules
that referenced
this pull request
May 21, 2026
…f-core#11408) * Migrate shasta to topic channel versions and add stub block - Converted versions.yml output to topic channel (versions_shasta) - Removed END_VERSIONS heredoc from script block - Added stub block with compressed outputs (echo | gzip) and mkdir for results dir - Updated tests: deterministic content snapshots for main test, sanitizeOutput for stub - Removed legacy versions output block from meta.yml - Restored EDAM ontology comments Contributes to nf-core#4570 * fix(shasta): replace meta.model with task.ext.args2 to satisfy main_nf_meta_key lint rule * fix(shasta): add memory=8.GB to test config; update assertion to use versions_shasta; regenerate snap * fix(shasta): remove redundant named-key versions snapshot assertions per migration guide * fix(shasta): migrate meta.model to val input channel; simplify version sed Addresses reviewer feedback: - meta.model replaced with val(model) input channel per nf-core spec (non-file mandatory args SHOULD be value channels) - Version extraction simplified from head|cut to single sed - Removed args2 workaround; restored explicit --config flag - Removed model from meta map in tests
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Contribution to #4570 — Stub+Topic Channel Migration
Migrates
shastato the nf-core v4.0.1 topic channel versioning standard and adds a stub block.Changes
main.nf: Replacedversions.yml/END_VERSIONSheredoc with topic channel emit (versions_shasta). Addedstubblock withecho "" | gzipfor compressed outputs andmkdir -p ShastaRunfor the results directory.meta.yml: Removed legacyversions:output block; lint fixed to addversions_shastaandtopics:. Restored EDAM ontology comments.tests/main.nf.test: Main test uses deterministic content assertions (linesGzip,file.name); stub test usessanitizeOutput. Added stub test case.tests/main.nf.test.snap: Regenerated snapshots (2 created).Test results (local,
--profile docker)Stability run: ✅ 2/2 passed
Part of the systematic migration tracked in #4570.