Skip to content
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

Bug: @remove directive not parsed correctly in config file #33

Open
bentyeh opened this issue Jan 13, 2025 · 0 comments
Open

Bug: @remove directive not parsed correctly in config file #33

bentyeh opened this issue Jan 13, 2025 · 0 comments

Comments

@bentyeh
Copy link
Contributor

bentyeh commented Jan 13, 2025

Since its introduction in version 0.29.4 (and through the current version 0.31.2), the @remove directive in the config file has not been parsed correctly, even though instructing splitcode to perform the same remove operation via the -r/--remove command line argument works correctly.

Minimum working example

  • input.fastq
    @read1
    AAA
    +
    ;;;
    
  • config.txt
    id	tag
    tag1	AAA
    
  • config_with_remove.txt
    @remove:
    tag1
    
    id	tag
    tag1	AAA
    

The command

splitcode -c config.txt --mod-names --out-fasta --nFastqs=1 -o /dev/stdout input.fastq

correctly identifies tag1

>read1::[tag1]
AAA

and adding a remove directive via the command line works as expected:

splitcode -c config.txt --mod-names --remove=<(echo "tag1") --out-fasta --nFastqs=1 -o /dev/stdout input.fastq

generates empty output. However,

splitcode -c config_with_remove.txt --mod-names --remove=<(echo "tag1") --out-fasta --nFastqs=1 -o /dev/stdout input.fastq

produces a standard output of

>read1::[tag1]
AAA

and a standard error of

Name "tag1 " does not exist
* Using a list of 1 tags (vector size: 1; map size: 1; num elements in map: 1)
* will process sample 1: input.fastq
* processing the reads ...
done 
* processed 1 reads

See also https://colab.research.google.com/drive/1NGGEudqUrxdYBtgyeBS0APOVzIo84kcX for an executable example.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant