Skip to content

Commit

Permalink
Merge pull request #173 from labgem/fix_non_uniq_ids
Browse files Browse the repository at this point in the history
Fix usage of non uniq gene ids when writting sequences
  • Loading branch information
axbazin authored Jan 25, 2024
2 parents da4a7e7 + 3947988 commit 91d0e39
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2.0.1
2.0.2
3 changes: 1 addition & 2 deletions ppanggolin/formats/writeSequences.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,7 @@ def write_gene_sequences_from_annotations(genes_to_write: Iterable[Gene], file_o
logging.getLogger("PPanGGOLiN").info(f"Writing all CDS sequences in {file_obj.name}")
for gene in tqdm(genes_to_write, unit="gene", disable=disable_bar):
if gene.type == "CDS":
gene_id = gene.ID if gene.local_identifier == "" else gene.local_identifier
file_obj.write(f'>{add}{gene_id}\n')
file_obj.write(f'>{add}{gene.ID}\n')
file_obj.write(f'{gene.dna}\n')
file_obj.flush()

Expand Down

0 comments on commit 91d0e39

Please sign in to comment.