File tree Expand file tree Collapse file tree 1 file changed +2
-4
lines changed
Expand file tree Collapse file tree 1 file changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -1252,6 +1252,8 @@ def extract_attributes(tag_content):
12521252 end_tag_pattern = rf"</{ tag } >"
12531253
12541254 if re .search (end_tag_pattern , content ):
1255+ end_flag = True
1256+
12551257 block_content = content_blocks [- 1 ]["content" ]
12561258 # Strip start and end tags from the content
12571259 start_tag_pattern = rf"<{ tag } (.*?)>"
@@ -1276,7 +1278,6 @@ def extract_attributes(tag_content):
12761278 print (f"leftover_content: { leftover_content } " )
12771279
12781280 if block_content :
1279- end_flag = True
12801281 content_blocks [- 1 ]["content" ] = block_content
12811282 content_blocks [- 1 ]["ended_at" ] = time .time ()
12821283 content_blocks [- 1 ]["duration" ] = int (
@@ -1290,9 +1291,7 @@ def extract_attributes(tag_content):
12901291 "content" : leftover_content ,
12911292 }
12921293 )
1293-
12941294 else :
1295- end_flag = True
12961295 # Remove the block if content is empty
12971296 content_blocks .pop ()
12981297
@@ -1377,7 +1376,6 @@ async def stream_body_handler(response):
13771376
13781377 try :
13791378 data = json .loads (data )
1380- print (data )
13811379
13821380 if "selected_model_id" in data :
13831381 model_id = data ["selected_model_id" ]
You can’t perform that action at this time.
0 commit comments