What was the valid way that we could document `arg...
# tools
j
What was the valid way that we could document
args
in the
meta.yaml
?
I think it was @Júlia Mir who I had this discussion with last time...
In cases where we have
args
and
args2
In this cas eI have the challenge that you have two commands from the same tool, so they are not indepdent tools that
args
can be referred to against
Or could I we just have krakenuniq twice in the tool list?
m
I really wish we had gone with
tool_({trailing_,leading_})?args
as a naming pattern.
j
Maybe...
Although it wouldn't get around this issue necessarily,
Maybe we do need a dedicated
args
part of the
meta.yaml
j
j
Aha! I can use the
extra_args
thing without current version of tools complaining?
j
the linting will probably complain 🙊 until we merge the changes
j
Poop, OK, then I guess we have to wait
Would it complain if i just replicate the tool twice in the tool info section?
j
the best would be to merge this https://github.com/nf-core/modules/pull/7783
I think this can be merged before the tools release
and then linting will pass
j
OK fair
I shall be patient
j
but we need a decision on the comment that's left there 😄 I think it's a good time for 📢 the <!subteam^S044DU0NG68>
j
Waht would the difference be between the two?
(practically) If it was an array it would use the
-
bullet-like notation?
j
yes!
j
That's fine with me for consistency 💯
👍🏻 1
j
for a map we would write
Copy code
extra_args:
  args:
    description: 'samtools index'
a list would be
Copy code
extra_args:
  - args:
        description: 'samtools index'
j
I've left a comment but maybe get a couple more
👌🏻 1
keanu thanks 1
i
As the two are functionally equivalent (unless you're writing plugins), the only argument I see is the list being more consistent with the overall format
👍 1
j
I agree
p
I may be missing something, but wouldn't we want a list of mappings rather than a list of mappings of mappings?
Copy code
extra_args:
  - description: first arg
     ... 
  - description: second arg
     ...
?
s
I really wish we had gone with
<tool>_({trailing_,leading_})?args
as a naming pattern. (edited)
Anything that isn't the stupid
args2
,
args3
etc.
j
I'm still fine with args2, args3 to be honest 😅 Anything other than a 2/3 notation will just fail miserable to be standaridsed
Because what if you have like 5 samtools 'after' tools
j
@pontus we want the name of the args, that's why we have some nesting
p
Thanks, but I don't think I understood,
args
there would be the name? (Feel free to just ignore me if that's a stupid question, I just thought the nesting looked weird.)
j
yes,
args
is the name. It's confusing because we use
args
as a standard, but now some modules have
args2
,
args3
... and we want to add documentation for all of these
🙇 1
🤷 1
r
Is this a similar way of how we should document and specialities for the prefix?
j
🤔 I think they are different
prefix could be documented within the pattern of the output if needed
j
Agree it's different. What do you mean about documenting specialties of prefix?
r
i thought there was some maintainers discussions when a prefix is not just hte meta.id, but needs to have like a bam or cram ending
j
I thought that was still being debated (IIRC I was against it... but I don't remembe rthe exact outcome)
r
in some modules it's kinda tricky todo otherwise I find. If there is still debate around then I will do as I please for now 😄 https://github.com/nf-core/modules/pull/8461
j
But that looks like a mandatory argument, that shoudl come via a input channel, no?
r
hm I wouldn't say so. It defaults to cram. prefix is not a tool argument
j
Ah I seeeee, I'm following now sorry wrong debate!
(it's combing back to me)
I think yeah it would be reasoable to have an (optional) meta.yaml description to say any special uses of prefixes
a
Copy code
input:
    tuple val(meta), path(bam), path(bai)
    tuple val(prefix), val(tool1_args), val(tool2_args)
eyebrows
😱 1
r
are we back to carrying tool arguments through three levels of workflows? screams
😱 1
a
Get rid of the nested levels of workflows
i
Are you suggesting a switch back to DSL1?
evil laugh 1
a
No, but we probably don't need to do workflow -> workflow -> workflow -> workflow -> workflow -> workflow -> fastqc
i
I haven't seen a case that bad, but it's usually 4 levels total (3 effective) with the approach that we're using
a
I'm exaggerating of course! With Ben's typing system, it will be way easier to pass in arguments because we can make collections of arguments.
Copy code
record ToolParams {
   fastqc_args : String
   fq_lint_args : String
}

tool_params(
   fastqc_args = "--quiet"
   fq_lint_args = "--ignore-duplicates"
}

FASTQ_QC_WORKFLOW(
   ch_fastqs,
   tool_params
)
Sorry, digressing the conversation 😆
Left a comment on the GH issue
s
IMO
prefix
should only be used for the prefix, not the file extension. Some modules use a
file_ext
or similarly named input channel, or some older modules use
ext.args.suffix
this 3
r
Why did I ask and not just accept Maximes approval 😆
🤣 8
m
You should all listen to me and let me rule the world
😆 1
nod 2
m
Ben has an idea also about passing process specific inputs through the
params
config scope. I can't find the exact comment atm. He definitely sees the value in it though
👍 1