Skip to content

Commit 3cab8ea

Browse files
committed
change max workers to one
1 parent b269f87 commit 3cab8ea

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

codeflash/optimization/function_optimizer.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -362,7 +362,7 @@ def determine_best_candidate(
362362
candidates = deque(candidates)
363363
# Start a new thread for AI service request, start loop in main thread
364364
# check if aiservice request is complete, when it is complete, append result to the candidates list
365-
with concurrent.futures.ThreadPoolExecutor() as executor:
365+
with concurrent.futures.ThreadPoolExecutor(max_workers=1) as executor:
366366
future_line_profile_results = executor.submit(
367367
self.aiservice_client.optimize_python_code_line_profiler,
368368
source_code=code_context.read_writable_code,

0 commit comments

Comments
 (0)