IGBB / quack

A FASTQ quality assessment tool
GNU General Public License v3.0
14 stars 5 forks source link

-name option corrupting the output #17

Closed nmendozam closed 4 years ago

nmendozam commented 4 years ago

I get a corrupt SVG when using the -name option. I'm using the current master.

./quack -1 B-LFC1.fq.gz -2 B-LFC2.fq.gz -a Sequencing_adaptors.fasta.gz  -name B-LFC > B-LFC.svg
convert B-LFC.svg B-LFC.png

(process:124903): librsvg-CRITICAL **: 18:02:56.985: Handle could not read or parse the SVG; did you check for errors during the loading stage?

(process:124903): librsvg-CRITICAL **: 18:02:56.985: Handle could not read or parse the SVG; did you check for errors during the loading stage?
convert: negative or zero image size `B-LFC.svg' @ error/image.c/SetImageExtent/2702.
convert: no decode delegate for this image format `B-LFC.svg' @ error/svg.c/ReadSVGImage/3419.
convert: no images defined `B-LFC.png' @ error/convert.c/ConvertImageCommand/3226.

But by removing the -name option, I'm able to get the image.

./quack -1 B-LFC1.fq.gz -2 B-LFC2.fq.gz -a Sequencing_adaptors.fasta.gz > B-LFC.svg
convert B-LFC.svg B-LFC.png

Here is the corrupted file. https://drive.google.com/file/d/1WdyK4JG2f4uzEDzIo1RudcXCUGhySpaC/view?usp=sharing

maa146 commented 4 years ago

-name isn't a valid option. The option is either --name or -n.

The corrupted svg came from the error message being printed to the svg file instead of stderr. The latest commit fixed this as well as stops on any argument error.