Skip to content

Commit

Permalink
Prevent crash from slash-containing contig names
Browse files Browse the repository at this point in the history
  • Loading branch information
rrwick committed Feb 23, 2021
1 parent 25b9768 commit b4f548d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions trycycler/cluster.py
Expand Up @@ -80,6 +80,8 @@ def check_input_assemblies(filenames):
seqs = load_fasta(f)
contig_names = set()
for contig_name, _ in seqs:
if '/' in contig_name:
sys.exit(f'\nError: contig names cannot contain a slash character: {contig_name}')
if contig_name in contig_names:
sys.exit(f'\nError: duplicate contig name: {contig_name}')
contig_names.add(contig_name)
Expand Down
2 changes: 1 addition & 1 deletion trycycler/version.py
Expand Up @@ -14,4 +14,4 @@
If not, see <http://www.gnu.org/licenses/>.
"""

__version__ = '0.4.1'
__version__ = '0.4.3'

0 comments on commit b4f548d

Please sign in to comment.