From a26533b43958dfced309f129a43466c043948068 Mon Sep 17 00:00:00 2001 From: GAUTREAU Guillaume Date: Tue, 6 Mar 2018 11:30:23 +0100 Subject: [PATCH] fix again bug #15 --- ppanggolin/ppanggolin.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/ppanggolin/ppanggolin.py b/ppanggolin/ppanggolin.py index d4f52d7..73c9058 100755 --- a/ppanggolin/ppanggolin.py +++ b/ppanggolin/ppanggolin.py @@ -456,7 +456,11 @@ def __neighborhood_computation(self, directed = False):#,light = False, untangle if contig in self.circular_contig_size:#circularization self.__add_link(gene_info_start[FAMILY],family_id_nei,organism, (self.circular_contig_size[contig] - end_family_nei) + gene_info_start[START]) - ordered_dict_prepend(contig_annot,gene_start,gene_info_start)#insert at the top + if sys.version_info < (3,): + ordered_dict_prepend(contig_annot,gene_start,gene_info_start)#insert at the top + else: + contig_annot[gene_start]=gene_info_start + contig_annot.move_to_end(gene_start, last=False)#move to the beginning # if light: # del self.annotations[organism] @@ -575,7 +579,7 @@ def validate_family(result): pan_size = stats["accessory"]+stats["core_exact"] while len(validated)1 else True:# # print(organisms) # print(chunck_size) # print(proba_sample.values())