Check that chromosome number is >=0

This commit is contained in:
Nicola Soranzo
2016-10-11 16:53:37 +01:00
parent d93cedef8a
commit 3be66005dc
+2 -1
View File
@@ -649,7 +649,8 @@ class Pileup( Tabular ):
try:
# chrom start in column 1 (with 0-based columns)
# and reference base is in column 2
int( hdr[1] )
chrom = int( hdr[1] )
assert chrom >= 0
assert hdr[2] in [ 'A', 'C', 'G', 'T', 'N', 'a', 'c', 'g', 't', 'n' ]
except:
return False