-
Notifications
You must be signed in to change notification settings - Fork 678
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Deduplication for the ext.args of the STAR module #934
Merged
drpatelh
merged 7 commits into
nf-core:dev
from
MatthiasZepper:extra_star_align_args_duplicates
Feb 8, 2023
Merged
Deduplication for the ext.args of the STAR module #934
drpatelh
merged 7 commits into
nf-core:dev
from
MatthiasZepper:extra_star_align_args_duplicates
Feb 8, 2023
Conversation
This file contains 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
|
46fc3a1
to
b0170df
Compare
b0170df
to
27e8097
Compare
…rgs in the STAR module.
…nique(false) in contrast returns a new, deduplicated list and leaves the params intact.
27e8097
to
869fab4
Compare
maxulysse
approved these changes
Feb 3, 2023
drpatelh
approved these changes
Feb 8, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome! Thanks @MatthiasZepper
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.
Potential for parameter clashes
The introduction of the
--extra_star_align_args
parameter in Version 3.10 (#907) of the pipeline introduced potential parameter clashes in the STAR module. If the same parameter is specified inparams.extra_star_align_args
andext.args
, they will both be retained in the module:Approach
For this error to occur, a user must provide a STAR parameter to
--extra_star_align_args
that has already been specified in themodules.config
or a custom config.rnaseq/conf/modules.config
Lines 534 to 549 in 6e1e448
Now, the union of
params.extra_star_align_args
andext.args
is provided arguments to STAR.A deduplication happens silently when needed.
Minimal reproducible example
Minimal reproducible example for the Groovy Web Console:
.split("\\s(?=--)")
splits the arguments toparams.extra_star_align_args
at each whitespace followed by two dashes. The dashes are retained with a(?=)
zero-width positive lookahead.The resulting nested list is flattened with
.flatten()
and.unique(false)
is used to create a new list of the union.Limitations
This approach does not eliminate a parameter duplication with dissimilar specifications.
Providing
--outFilterMultimapNmax 40
to--extra_star_align_args
would still cause a parameter clash, because the parameter value in the config is20
.I presume, this is the desired behaviour, since
--extra_star_align_args
is likely intended as a convenience parameter that should never take precedence over the module configuration.PR checklist
nf-core lint
).nextflow run . -profile test,docker --outdir <OUTDIR>
).docs/usage.md
is updated.docs/output.md
is updated.CHANGELOG.md
is updated.README.md
is updated (including new tool citations and authors/contributors).