From 7110c04453b11506fe20c72edcfee732e8a91ee7 Mon Sep 17 00:00:00 2001
From: oboulle <olivier.boulle@inria.fr>
Date: Thu, 29 Feb 2024 15:33:11 +0100
Subject: [PATCH] buffer is now the reverse complement of a next payload part

---
 eBlocks_design.py | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/eBlocks_design.py b/eBlocks_design.py
index 0f717b1..3214283 100755
--- a/eBlocks_design.py
+++ b/eBlocks_design.py
@@ -170,7 +170,7 @@ def add_bsaI(block_dict: dict, output_path: str = None) -> dict:
 def add_buffer(block_dict: str, output_path: str = None) -> dict:
     """
     add a buffering zone around each block
-    just pick some payload of an other block, the buffer will be removed in biology
+    just pick some payload of another block, the buffer will be removed in biology
     buff1  + B1  + buff2
     ...
     buff19 + B10 + buff20
@@ -187,8 +187,8 @@ def add_buffer(block_dict: str, output_path: str = None) -> dict:
     for i, frag_name in enumerate(list(block_dict.keys())):
         mid_block_index = len(block_list[i+1])//2
         
-        start_buffer = block_list[i+1][mid_block_index-buffer_size:mid_block_index-1]
-        stop_buffer = block_list[i+1][mid_block_index:mid_block_index+buffer_size-1]
+        start_buffer = dfr.reverse_complement(block_list[i+1][mid_block_index-buffer_size:mid_block_index-1])
+        stop_buffer = dfr.reverse_complement(block_list[i+1][mid_block_index:mid_block_index+buffer_size-1])
         
         #the addition of the buffer can create homopolymere
         #set a base different from extremity and start of buffer in between
-- 
GitLab