marbl / gingr

Other
13 stars 5 forks source link

Crash/exception when loading a multi-fasta alignment file #2

Closed tseemann closed 10 years ago

tseemann commented 10 years ago

When I try to import my "snps.mfa" which is my own core-SNP alignment file (no gaps, 20 taxa, ~10000 SNPs) it croaks with this message:

Qt has caught an exception thrown from an event handler. Throwing
exceptions from an event handler is not supported in Qt. You must
reimplement QApplication::notify() and catch all exceptions there.

terminate called after throwing an instance of 'std::logic_error'
  what():  basic_string::_S_construct null not valid

My colleague suggests it is expecting some particular ID or DESC format?

aphillippy commented 10 years ago

Brian is looking into this. Do you have a file (or snippet) you can share that replicates the error? If you wouldn't mind, you can dump it here: ftp://ftp.cbcb.umd.edu/incoming/amp Thank you!

ondovb commented 10 years ago

Your colleague is correct; there is apparently a parsing bug that causes a crash when there is no description (anything after the ID, separated by a space), which I suspect is causing your error. This will be fixed in the next version.

Another caveat for loading core-SNPs (like Mauve SNP files) - Gingr can technically load these, but it expects full alignments. You will have to adjust the filters (Window->Variants) to see the heatmap, since most of the variants will be flagged as poorly aligned. The positions in the ruler will also be SNP indices, rather than genomic positions, since that information isn't captured by core SNP files.

tseemann commented 10 years ago

Thanks guys!

I'd written a quick hack scalled Scapper: https://github.com/Victorian-Bioinformatics-Consortium/scapper which does the whole genome alignments using your old friend nucmer, so that the spatial coherency was maintained, and we used BratNextGen for recombination detection, but I think Mugsy and now Parsnp supersede it.

PS. I'm jealous I didn't think of the Harvest/Food tool naming suite pattern first :+1:

ondovb commented 10 years ago

The parsing error should be fixed in v1.0.1.