From 9c8dd0818859e69326076b331f188c6891768896 Mon Sep 17 00:00:00 2001 From: Harrison Deng Date: Fri, 10 Mar 2023 16:28:03 -0600 Subject: [PATCH] Fixed "all" property check. --- .vscode/launch.json | 2 +- fasta_filter.py | 4 ++-- requirements.txt | 1 + 3 files changed, 4 insertions(+), 3 deletions(-) create mode 100644 requirements.txt diff --git a/.vscode/launch.json b/.vscode/launch.json index 13dd9c7..30abaec 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -11,7 +11,7 @@ "program": "fasta_filter.py", "args": [ "reference_standards.fas", - "reference_stasndards_filtered.fas", + "reference_standards_filtered.fas", "-c", "rt" ], "console": "integratedTerminal", diff --git a/fasta_filter.py b/fasta_filter.py index b3abbcf..0268ed9 100755 --- a/fasta_filter.py +++ b/fasta_filter.py @@ -14,8 +14,8 @@ def main(args): kept_records.append(s_record) elif args.property == "all" and not ( args.contains in s_record.id - and args.contains in s_record.name - and args.contains in s_record.description): + or args.contains in s_record.name + or args.contains in s_record.description): kept_records.append(s_record) SeqIO.write( kept_records, diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 0000000..808664b --- /dev/null +++ b/requirements.txt @@ -0,0 +1 @@ +Bio==1.5.6