Skip to content

Commit 2bbd07c

Browse files
committed
fix: set APPMAP_CONFIG
The solver gets run in the testbed, but the config lives in the SWE-bench repo.
1 parent d7710c6 commit 2bbd07c

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

solver/solve.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,8 @@ def solve_instance(
6161
with open(issue_file, "w") as f:
6262
f.write(instance["problem_statement"])
6363

64-
solver_path = Path(__file__).parent / "solve" / "solver.py"
64+
parent = Path(__file__).parent
65+
solver_path = parent / "solve" / "solver.py"
6566
solve_args = [
6667
"env",
6768
"appmap-python",
@@ -90,7 +91,7 @@ def solve_instance(
9091
solve_args.extend(["--steps", steps])
9192

9293
# Run this as a separate process so that it can change the working directory.
93-
solve_result = run(solve_args, cwd=testbed)
94+
solve_result = run(solve_args, cwd=testbed, env={"APPMAP_CONFIG": str(parent / "appmap.yml")})
9495
if solve_result.returncode != 0:
9596
print(
9697
f"Solver reported exit code {solve_result.returncode} for {instance['instance_id']}/{iteration + 1}."

0 commit comments

Comments
 (0)