summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--monkey/__init__.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/monkey/__init__.py b/monkey/__init__.py
index 79dfe2d..167d0f2 100644
--- a/monkey/__init__.py
+++ b/monkey/__init__.py
@@ -91,7 +91,7 @@ def fix(code, edits, test, timeout=30, debug=False):
# Otherwise generate new solutions.
for new_program, new_step, new_cost in step(program, path):
new_path_cost = path_cost * new_cost
- if new_path_cost < 0.01:
+ if len(todo) > 500 and new_path_cost < 0.001:
continue
new_path = path + (new_step,)
todo.push((new_program, new_path, new_path_cost), -new_path_cost)