From b9652dbfe28f8e8806a74aa0bafd1a482b4e827c Mon Sep 17 00:00:00 2001 From: Luke Curley Date: Sun, 1 Nov 2026 10:44:13 -0800 Subject: [PATCH] fix(land): run the fixer's Codex with medium reasoning effort The fixer passed a model but no model_reasoning_effort, and its jobs logged "reasoning effort: none" (found by the 2026-11-01 merge-queue audit). Fixes need reasoning; medium matches quest review's default. Co-Authored-By: Claude Opus 5.5 --- src/cli/land-fix.ts | 3 +++ test/land.test.ts | 20 ++++++++++++++++++++ 2 files changed, 23 insertions(+) diff --git a/src/cli/land-fix.ts b/src/cli/land-fix.ts index 4cebde93..072dce4e 100644 --- a/src/cli/land-fix.ts +++ b/src/cli/land-fix.ts @@ -133,6 +133,9 @@ export async function fix( 'model_providers.quest-fixer.env_key="OPENAI_API_KEY"', "-c", 'model_providers.quest-fixer.wire_api="responses"', + // Without this, Codex runs the proxy's model with no reasoning at all ("reasoning effort: none"). + "-c", + 'model_reasoning_effort="medium"', ...(model ? ["--model", model] : []), "-", ]; diff --git a/test/land.test.ts b/test/land.test.ts index dcbe35c8..261a1ea7 100644 --- a/test/land.test.ts +++ b/test/land.test.ts @@ -2139,6 +2139,26 @@ ${requeueScript} await fix(dir, log, [1], agent, ["-"]); expect(readFileSync(join(dir, "prompt.txt"), "utf8")).toContain(`PRs:\n- #1: branch pr-1 at ${head}\n`); }); + test("runs default Codex with an explicit reasoning effort", async () => { + const dir = fixRepository(); + const agent = join(dir, "agent"); + const log = join(dir, "failure.log"); + writeFileSync(log, "failed check"); + vi.stubEnv("OPENAI_BASE_URL", "http://proxy.test/v1"); + vi.stubEnv("OPENAI_API_KEY", "proxy-client"); + writeFileSync( + agent, + `#!/bin/sh +set -eu +printf '%s\\n' "$@" > argv.txt +cat > prompt.txt +${requeueScript} +`, + { mode: 0o755 }, + ); + await fix(dir, log, [1], agent); + expect(readFileSync(join(dir, "argv.txt"), "utf8").split("\n")).toContain('model_reasoning_effort="medium"'); + }); test("refuses to start an agent without a supplied PR's branch", async () => { const dir = fixRepository(); const log = join(dir, "failure.log");