rvosa / bio-phylo

Bio::Phylo - Phyloinformatic analysis using Perl
http://search.cpan.org/dist/Bio-Phylo
GNU General Public License v3.0
16 stars 6 forks source link

fix FASTA handling #21

Closed rvosa closed 4 years ago

rvosa commented 9 years ago

The FASTA parser/unparser combo is a bit screwed up. Here's the problem it was trying to solve: FASTA definition lines can be quite longish with all sorts of potentially important information hidden in there (descriptions, identifiers, names) so we don't want to throw that away. On the other hand, the potential length, with multiple words and punctuation in it, could make it problematic to go from FASTA to NEXUS, for example. The current "fix" for this was to copy the definition line to a special field ($seq->get_generic('fasta_def_line')) but this is a bit buggy when attempting to roundtrip. Give this some attention.

rvosa commented 7 years ago

The most sensible way to deal with this, and the one that causes the least amount of surprise, is to simply copy the whole definition line to get/set name and have users deal with the length.