Skip to content

fix(land): the fixer's model is read from Codex's banner, a cancelled build is a failure, and handback summaries end at a word - #816

Merged
kixelated merged 2 commits into
mainfrom
quest/m0/land-fixer-crash
Nov 22, 2026
Merged

kixelated merged 2 commits into
mainfrom
quest/m0/land-fixer-crash

Conversation

@kixelated

@kixelated kixelated commented Nov 22, 2026 •

Copy link
Copy Markdown
Collaborator

Finishes quest/m0/land-fixer-crash.md: its Waiting condition cleared, so the quest is deleted. The three problems the evidence run showed are fixed here too, since each is small and rooted in this repository.

Summary

  • Evidence. kixel-ai/dotfiles#226 (the fixer uploads only .git) merged 2026-11-22T05:09Z. url 2.5.9 fixes RUSTSEC-2026-0592, which fails cargo deny on every PR kixel-ai/rind#967 was then dropped by the merge queue (failed_checks, 16:33Z) and got a real Codex run (gpt-6.1-sol, medium, 76,391 tokens) that handed back at 16:55Z naming what it needs, not fixer crashed (exit 1). The quest is done.
  • The watcher "found no failing merge_group job". Root cause: the queue's only job (Queue build / Build) ran into GitHub's 1 h job limit and ended cancelled (annotation "The job has exceeded the maximum execution time of 1h0m0s"). The watcher counted only failure, timed_out, and startup_failure, so the fixer got just the PR's own skipped checks. failingJobs now falls back to cancelled jobs when none failed (a failure's fail-fast siblings stay out), naming the cancelled step, and reads logs only for the jobs it keeps.
  • "codex, unknown". Root cause: fix read only the first 4,096 bytes of the agent's stderr for the model: banner line, and the host's Nix shell printed 5,119 bytes (43 lines of copying path) before Codex's banner. Now fix reads stderr line by line, and takes model: only from Codex's own banner (OpenAI Codex v… to the second -------- rule), so wrapper output of any length passes and nothing the agent prints later can set it.
  • Cut summary. The one-line handback summary sliced the diagnosis at 200 characters, mid-word, then appended . Recommendation. It now ends at a word with …. The stray fi·x is deliberate and unchanged: fixerText defuses closing keywords so a fixer's text cannot close an issue by fixes <URL>; narrowing it is not worth the risk.

Validation

  • Read the evidence on the maintainer's host: the rind watcher's watch-job-fix-AAHbI7.json.log shows Codex v0.167.1 starting (model: gpt-6.1-sol, reasoning effort: medium) after 43 lines of Nix output totalling 5,119 bytes, and removal-967.json has "jobs":[]. gh api shows the merge group's run 45038867826 with one job, Queue build / Build, cancelled after 1h0m, its step Check and test the merge group cancelled, and the 1 h annotation.
  • Red then green: test/land.test.ts "finds Codex's banner after any amount of wrapper output" (200 lines of Nix noise, a forged model: line before the banner, a forged second banner after) returns unknown on the base and passes now; test/land-watch.test.ts "a build GitHub cancelled past its time limit…" fails on the base (no failing job) and passes now, and also asserts a cancelled sibling of a failed job is neither listed nor has its log read. A unit test covers clip.
  • Second way: fed rind#967's real fixer log through the built fix as a fake agent's stderr; the result now records "model":"gpt-6.1-sol" where it recorded unknown.
  • just check and just test pass.

Public API

None on the CLI. Handback and removal comments name a cancelled job when it is the only failure, and fixer signatures carry the model whenever Codex printed it.

Caused by

  • moq-dev/quest#494 - read the model from only the first 4,096 bytes of stderr, so a long wrapper preamble hid Codex's banner (found by person)
  • moq-dev/quest#388 - treated only failure, timed_out, and startup_failure as failing, so a job cancelled at the time limit left the fixer no failing job (found by person)
  • moq-dev/quest#389 - cut a handback's summary at a fixed length, mid-sentence (found by person)

Follow-ups

  • kixel-ai/dotfiles, for /quest-plan there: the fixer's shell stalled for minutes at "waiting for the big garbage collector lock..." during nix develop and could not finish the gate. Its quest/m0/nixos/fixer-upload.md waits on the same run and can finish on it.
  • kixel-ai/rind, for /quest-plan there: Queue build / Build has no timeout-minutes, so a hung build holds the queue for GitHub's 1 h limit. #967's build hung that long and the PR merged unchanged on its second enqueue.

No quest here owns any of these (no open PR touches these files).

Decisions

Settled by the maintainer in the pick round:

  • Pick: ✅ /quest-merge (rejected: /quest-iterate, skip).
  • Follow-up, kixel-ai/dotfiles, the fixer's shell stalling on the Nix garbage-collector lock: ✅ keep (rejected: drop).
  • Follow-up, kixel-ai/dotfiles, the wrapper's 43 lines of Nix fetch output before Codex starts: ✅ drop (rejected: keep), since this PR already reads the banner wherever it appears.
  • Follow-up, kixel-ai/rind, Queue build / Build with no timeout-minutes: ✅ keep (rejected: drop).

Models

Size: XS
Implementer: Claude Code, claude-sonnet-5-5, unknown effort (arm A)
Implementer: Claude Code, claude-sonnet-5-5, unknown effort (iterate, XS, arm A)

🤖 Generated with Claude Code

(Written by Claude Sonnet 5.5)

Review

Rewritten by quest review after each round.

  • Head: b55ae04

  • Base: origin/main at 277d0e8

  • Risk: medium, It fixes bugs in the land fixer's behavior: the model is now read from Codex's startup banner, cancelled jobs (such as a timed-out build) now count as the failing job so the watcher can hand them to the fixer, and handback comments are clipped at a word. A wrong read could mislabel a fixer's model or post a misleading job cause in a PR comment for the maintainer and contributors on rind, and a revert undoes all of it.

  • Classified: medium by Claude Code, claude-haiku-5-5, low effort, session 71a7ba11-8f36-4bb1-adce-499d1eba68ef

  • Reviewer: Codex, gpt-6.1-sol, medium effort

  • Session: 01a204be-caf6-7ac2-ae53-bb25443e5d1c, round 1

  • Score: 9/10, No actionable regressions were found in the altered contracts or their dependents, though builds and tests were not run as instructed.

  • Rounds: 1; first round 0; findings 0: fixed 0, refuted 0, open 0

  • Findings: none

kixelated and others added 2 commits November 22, 2026 11:20
… build is a failure, and handback summaries end at a word

Finishes the land fixer crash quest: kixel-ai/rind#967 got a real Codex run that named what it needed.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@kixelated kixelated changed the title The land fixer stops crashing on kixel-ai/rind fix(land): the fixer's model is read from Codex's banner, a cancelled build is a failure, and handback summaries end at a word Nov 22, 2026
@kixelated
kixelated marked this pull request as ready for review November 22, 2026 19:32
@coderabbitai

coderabbitai Bot commented Nov 22, 2026

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 20 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 5adc1df0-ca40-4bdc-9bd5-2fd73f0cfaee
Commits

Reviewing files that changed from the base of the PR and between 1d1177c and b55ae04.

Files selected for processing: 6

  • quest/m0/land-fixer-crash.md
  • src/cli/land-fix.ts
  • src/cli/land-watch-fix.ts
  • src/cli/land-watch.ts
  • test/land-watch.test.ts
  • test/land.test.ts
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Approach: sound. Each fix targets a root cause the evidence run showed: the model is now parsed from Codex's own banner instead of a fixed-size stderr prefix, cancelled jobs are a fallback only when no job failed, and summaries are clipped at a word.

Reviewed changes

This review covers the full diff: the fixer's banner parsing, the watcher's failing-job selection, handback clipping, their tests, and the finished quest file.

  • Banner in land-fix.ts: reads stderr line by line and takes model: only between OpenAI Codex v… and the second -------- rule. Wrapper output of any length before the banner is skipped, and agent output after it cannot set the model.
  • failingJobs cancelled fallback: a cancelled job is reported, with its cancelled step, only when no job failed. Fail-fast siblings stay out, and logs are fetched only for the jobs kept. This also applies to quest's own queue drops in land-queue.ts, where the same behavior is the right one.
  • clip for handback summaries: ends at a word with … when the text is cut. When it is not cut, it appends the terminator only if the text lacks one.
  • Tests: cover a 200-line wrapper preamble, a forged model: line before the banner, a second banner after it, a time-limited cancelled build next to a failed build with a cancelled sibling, and clip.
  • quest/m0/land-fixer-crash.md: deleted because its Waiting condition cleared.

Pullfrog  | View workflow run | Using claude-opus-5-5 | 𝕏

@kixelated

Copy link
Copy Markdown
Collaborator Author

Maintainer decision (2026-11-22, /quest-run, pick round):

  • Pick: ✅ /quest-merge (rejected: /quest-iterate, skip).
  • Follow-up, kixel-ai/dotfiles, the fixer's shell stalling on the Nix garbage-collector lock: ✅ keep (rejected: drop).
  • Follow-up, kixel-ai/dotfiles, the wrapper's 43 lines of Nix fetch output before Codex starts: ✅ drop (rejected: keep). This PR already reads the banner wherever it appears.
  • Follow-up, kixel-ai/rind, Queue build / Build with no timeout-minutes: ✅ keep (rejected: drop).

(Written by Opus 5.5)

@kixelated

Copy link
Copy Markdown
Collaborator Author

Applied the maintainer's decision at #816 (comment): the pick, and the three follow-up answers, are recorded under ## Decisions, and the dropped dotfiles follow-up (the wrapper's Nix fetch output) is removed from ## Follow-ups. No code changed: the head stays b55ae0430a and its review record still counts.

(Written by Claude Sonnet 5.5)

@kixelated
kixelated added this pull request to the merge queue Nov 22, 2026
Merged via the queue into main with commit 06b30e4 Nov 22, 2026
28 checks passed
@kixelated
kixelated deleted the quest/m0/land-fixer-crash branch November 22, 2026 20:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant