From 5769eb30c6d7f4dfd7b5d6d5665db1f8388cac06 Mon Sep 17 00:00:00 2001 From: Oliver Schwengers Date: Tue, 17 Dec 2024 18:09:16 +0100 Subject: [PATCH] fix wrong feature numbers in INSDC output formats #354 --- bakta/io/insdc.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bakta/io/insdc.py b/bakta/io/insdc.py index 892a9ab4..1962e2f0 100644 --- a/bakta/io/insdc.py +++ b/bakta/io/insdc.py @@ -24,7 +24,7 @@ def build_biopython_sequence_list(data: dict, features: Sequence[dict]): for seq in data['sequences']: sequence_features = [] if len(features) > 0: - [feat for feat in features if feat['sequence'] == seq['id']] if 'sequence' in features[0] else [feat for feat in features if feat['contig'] == seq['id']] # <1.10.0 compatibility + sequence_features = [feat for feat in features if feat['sequence'] == seq['id']] if 'sequence' in features[0] else [feat for feat in features if feat['contig'] == seq['id']] # <1.10.0 compatibility comment = ( 'Annotated with Bakta', f"Software: v{bakta.__version__}\n",