Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extracting off-targets is at risk of crashing if only one sequence is processed #14

Open
jakeb1996 opened this issue Apr 28, 2023 · 0 comments · May be fixed by #20
Open

Extracting off-targets is at risk of crashing if only one sequence is processed #14

jakeb1996 opened this issue Apr 28, 2023 · 0 comments · May be fixed by #20

Comments

@jakeb1996
Copy link
Member

The extract off-target sites utility will crash if there is only one FASTA sequence provided. This leads to only one intermediate file existing; these intermediate files are sorted and merged. Importantly, the sort is successful but the merge is not.

I do not believe there will be an issue when the input(s) are either: (1) multiple FASTA files or (2) a single multi-FASTA file.

The crash is caused by a variable being referenced before assignment:
Line 191 exists outside of the while loop, and therefore, mergedFile may never be declared.

shutil.move(mergedFile.name, fpOutput)

@jakeb1996 jakeb1996 linked a pull request Jan 11, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant