mirror of
https://github.com/galaxyproject/galaxy.git
synced 2026-09-24 16:30:27 +08:00
Sniff fastqsanger more aggressively (#8322)
Sniff fastqsanger more aggressively
This commit is contained in:
@@ -694,13 +694,16 @@ class BaseFastq(Sequence):
|
||||
>>> fname = get_test_fname('1.fastqsanger')
|
||||
>>> FastqSanger().sniff(fname)
|
||||
True
|
||||
>>> fname = get_test_fname('4.fastqsanger')
|
||||
>>> FastqSanger().sniff(fname)
|
||||
True
|
||||
>>> fname = get_test_fname('3.fastq')
|
||||
>>> FastqSanger().sniff(fname)
|
||||
False
|
||||
>>> Fastq().sniff(fname)
|
||||
True
|
||||
>>> fname = get_test_fname('2.fastq')
|
||||
>>> Fastq().sniff( fname )
|
||||
>>> Fastq().sniff(fname)
|
||||
True
|
||||
>>> FastqSanger().sniff(fname)
|
||||
False
|
||||
@@ -819,7 +822,7 @@ class FastqSanger(Fastq):
|
||||
def quality_check(lines):
|
||||
"""Presuming lines are lines from a fastq file, return True if the qualities are compatible with sanger encoding"""
|
||||
for line in islice(lines, 3, None, 4):
|
||||
if not all(_ >= '!' and _ <= 'M' for _ in line[0]) or ' ' in line:
|
||||
if not all(_ >= '!' and _ <= 'S' for _ in line[0]):
|
||||
return False
|
||||
return True
|
||||
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
@DCW97JN1:309:C0C42ACXX:4:2206:12976:57510/1
|
||||
AAATGGGCATAATATAGATGTAGAGATGTGTTGAATTTATGACTCATTT
|
||||
+
|
||||
ADECJJJJDCCECCCCMCCNCCMCNBCLBJBCLADCDC=CNDJILEDDD
|
||||
@DCW97JN1:309:C0C42ACXX:4:2211:6915:3569/1
|
||||
AAAGAAATTAAATGGGCATAATATAGATGTAGAGATGTGTTGAATTTAT
|
||||
+
|
||||
@DEJAAA?B@ECCEFFGDBBFC8ABGCBK=BI=66@HE@@JACCCDCCI
|
||||
Reference in New Issue
Block a user