A skill to stop your coding agent from burying the answer. ADHD-friendly output.
evals: remove redundant judge cwd shim
Ayoub G.57e65fd9e671
diff --git a/scripts/judge.py b/scripts/judge.pyindex 01022a6..3b2b736 100644--- a/scripts/judge.py+++ b/scripts/judge.py@@ -171,11 +171,6 @@ def assign_labels(group_key: tuple, conditions: list[str]) -> dict[str, str]:return dict(zip(ordered, labels))-def _neutral_cwd():- """Run the judge in the same neutral context generation uses."""- return run_evals._neutral_cwd()--def invoke_judge(command: list[str], response_format: str, prompt: str, retries: int) -> tuple[str, float | None]:@@ -188,7 +183,7 @@ def invoke_judge("""completed = Nonefor attempt in range(retries + 1):- with _neutral_cwd() as cwd:+ with run_evals._neutral_cwd() as cwd:completed = subprocess.run(list(command),check=False,diff --git a/tests/test_judge.py b/tests/test_judge.pyindex ddf844f..8a61094 100644--- a/tests/test_judge.py+++ b/tests/test_judge.py@@ -163,14 +163,14 @@ class NeutralWorkingDirectoryTest(unittest.TestCase):# An agent CLI adopts its working directory as project context. Run it# in the repo and it starts inspecting the eval harness instead of# answering the prompt, which contaminates the responses being graded.- with judge._neutral_cwd() as first:+ with run_evals._neutral_cwd() as first:cwd = Path(first).resolve()self.assertNotEqual(judge.ROOT.resolve(), cwd)self.assertFalse(str(cwd).startswith(str(judge.ROOT.resolve())))self.assertEqual([], list(cwd.iterdir()))(cwd / "state-from-prior-run").write_text("not reusable")- with judge._neutral_cwd() as second:+ with run_evals._neutral_cwd() as second:next_cwd = Path(second).resolve()self.assertNotEqual(cwd, next_cwd)self.assertEqual([], list(next_cwd.iterdir()))