Skip to content

Commit

Permalink
Fix TypeError: cannot unpack non-iterable int object when using --count
Browse files Browse the repository at this point in the history
  • Loading branch information
matthuska committed Oct 30, 2023
1 parent 45332c3 commit 1fa68f9
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions lib/sonardb.py
Original file line number Diff line number Diff line change
Expand Up @@ -2001,7 +2001,9 @@ def match(

cursor = self.cursor.execute(sql, where_vals)
column_names = [description[0] for description in cursor.description]
return cursor.fetchall(), column_names
rows = cursor.fetchall()

return rows, column_names

# UPDATE DATA

Expand Down Expand Up @@ -3479,7 +3481,7 @@ def match(
rows[i]["aa_profile"], self.iupac_explicit_aa_code, keep
)
elif count:
return rows[0]["count"]
return rows[0]["count"], "count"

return rows, column_names

Expand Down

0 comments on commit 1fa68f9

Please sign in to comment.