Skip to content

Commit

Permalink
Broken 'select' evaluation if last columns happen to be empty; fixed.
Browse files Browse the repository at this point in the history
  • Loading branch information
agalitsyna committed Jan 10, 2025
1 parent 0a5fb1f commit 9a0b894
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pairtools/lib/select.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ def evaluate_stream(
match_func = compile(condition, "<string>", "eval")

for line in headerless_stream:
COLS = line.rstrip().split(pairsam_format.PAIRSAM_SEP)
COLS = line.rstrip('\n').split(pairsam_format.PAIRSAM_SEP)

# Evaluate filtering expression:
filter_passed = eval(match_func)
Expand Down

0 comments on commit 9a0b894

Please sign in to comment.