ngless-toolkit / ngless-toolkit/ngless
Filetype in external modules does not enforce number of inputs passed
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 152
- Forks
- 23
- PR merge metrics
- No merged PRs in 30d
Description
When using external modules one can specify
arg1:
atype: 'readset'
can_gzip: true
which passes one (.1.fq), two (.1.fq, .2.fq), or three (.1.fq, .2.fq, .single.fq) files depending on what the caller used or produced, fastq(), paired() or paired(singles=), respectively.
Current API specifies that you can add a filetype annotation/constraint to have ngless pass the expected format:
arg1:
atype: 'readset'
filetype: 'fq3'
can_gzip: true
This didn't work as expected. In the example above, even though fq3 (.1.fq, .2.fq, .single.fq) was specified ngless still passed either one, two or three .fq files.
The same happens if instead of fq3, fq1 is defined. Up to three files are still passed.
A testcase can be found here
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the linked testcase gist and trace how external module arguments interpret the filetype annotation for readset values. Verify the handling of fq1 and fq3 against callers using fastq(), paired(), and paired(singles=), and confirm that the passed file count matches the declared constraint.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- bioinformatics, compilers
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100