Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix FASTA parsing with Windows newlines
When iterating lines of a file, Python includes the trailing `\n`, such that Windows lines ends with `\r\n`. Regex considers `$` to mean the end of the line, not end of the string. Vamb's header regex check did not take the trailing newline into account, but this happened to not matter since * Only the identifier was used in Vamb's internals, so the newline in the description was not noticed, and * It still passed the regex header check, as the regex matching stopped at the `\n` character. However, `\r\n` threw a wrench in all that. Fix it by simply removing the trailing `\r?\n` in the FASTA parser.
- Loading branch information