Skip to content

cr review rerun fails in thread_analysis resume: agent-logs/thread-analysis log file not found #699

Closed

Description

@rianjs

A cr review <pr> rerun crashed in the thread_analysis phase. It was on a PR that already had review threads from an earlier cr review run.

What happened

cr progress event=error command="review" op="resume_llm" target="llm" effort="low" harness="codex_cli" log_file="PRRT_kwDOSrNqjc6yHx9x-231021328d58.jsonl" model="gpt-6.1-terra" provider="openai" duration_ms=0 status=error error="open [path] [path] no such file or directory"
cr progress event=error command="review" op="run_llm_task" target="llm_task" ... phase="thread_analysis" resume_session_id="01a18e5c-7a99-7d61-b8d2-34b2fabf888c" source="resume" task_id="thread-analysis-PRRT_kwDOSrNqjc6yHx9x" task_status="failed_blocking" duration_ms=0 status=error ...
open ~/Library/Application Support/cr/data/runs/github.com_open-cli-collective_codereview-cli_698/8436ab952a26/c2ccbb9c4139/7dad7da07f19/run-8c9be83a-cb67-40d9-a43c-4684d14e1297/agent-logs/thread-analysis/PRRT_kwDOSrNqjc6yHx9x-231021328d58.jsonl: no such file or directory
  • Rerunning with --fresh-session worked.

Likely cause

resume_llm failed in 0 ms, before any LLM call. That points to the agent-logs/thread-analysis/ directory not being created before the log file was opened on the resume path.

Expected

The parent directory of the thread-analysis log is created before the file is opened, so a resumed thread analysis works like a fresh one. A regression test should cover resuming thread analysis on a PR with existing threads.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions