Actually comare an integer (length of list) to an integer 0.
authorDiane Trout <diane@ghic.org>
Fri, 20 Mar 2015 23:30:14 +0000 (16:30 -0700)
committerDiane Trout <diane@ghic.org>
Fri, 20 Mar 2015 23:30:14 +0000 (16:30 -0700)
Why was list() > 0 ever valid code?

htsworkflow/pipelines/firecrest.py

index 11c1d4cb9f0642d8e5d9ffc556ca0e1c4c354435..fba83f9d97c782b349f5021d6bbbe0919e65b5e4 100644 (file)
@@ -145,7 +145,7 @@ def firecrest(pathname):
     if os.path.exists(matrix_pathname):
         # this is for firecrest < 1.3.2
         f.matrix = open(matrix_pathname, 'r').read()
-    elif glob(bustard_pattern) > 0:
+    elif len(glob(bustard_pattern)) > 0:
         f.matrix = None
         # there are runs here. Bustard should save the matrix.
     else: