{"record":{"id":"86212bdb659a8085","repo":"Yeachan-Heo/oh-my-codex","slug":"failed-to-create-tmux-question-renderer-container","errorCode":null,"errorMessage":"Failed to create tmux question renderer container.","messagePattern":"Failed to create tmux question renderer container\\.","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/question/renderer.ts","lineNumber":319,"sourceCode":"  return undefined;\n}\n\nfunction launchQuestionPane(\n  execTmux: ExecTmuxSync,\n  sleepImpl: SleepSync,\n  args: string[],\n  launchedAt: string,\n  returnTarget: string | undefined,\n): {\n  renderer: 'tmux-pane';\n  target: string;\n  launched_at: string;\n  return_target?: string;\n  return_transport?: 'tmux-send-keys';\n} {\n  const rawPane = execTmux(args);\n  const paneId = parsePaneIdFromTmuxOutput(rawPane);\n  if (!paneId) throw new Error('Failed to create tmux question renderer container.');\n  sleepImpl(QUESTION_RENDERER_PANE_SETTLE_MS);\n  if (!isLaunchedQuestionPaneAlive(paneId, execTmux)) {\n    throw new Error(`Question UI pane ${paneId} disappeared immediately after launch.`);\n  }\n  return {\n    renderer: 'tmux-pane',\n    target: paneId,\n    launched_at: launchedAt,\n    ...(returnTarget ? { return_target: returnTarget, return_transport: 'tmux-send-keys' as const } : {}),\n  };\n}\n\nfunction resolveQuestionUiProcessArgs(\n  recordPath: string,\n  options: {\n    cwd: string;\n    env?: NodeJS.ProcessEnv;\n  },","sourceCodeStart":301,"sourceCodeEnd":337,"githubUrl":"https://github.com/Yeachan-Heo/oh-my-codex/blob/3ad79a8a6fe6e95fdbb8c00e40716fffe4011ce2/src/question/renderer.ts#L301-L337","documentation":"launchQuestionPane runs a tmux command (e.g. split-window) to create the pane that renders the question UI, then parses a pane id from tmux's output. If parsePaneIdFromTmuxOutput cannot extract a %{pane_id}, the launch aborts because subsequent keystrokes/targeting have nothing to address. Usually the tmux command itself failed or emitted an error message instead of a pane id.","triggerScenarios":"tmux display-message -p '#{pane_id}' (or split-window output) returning empty or an error string; tmux server not running so no session exists to split into; running outside tmux so the target session is unresolvable; tmux too old/new output format not matching the parser.","commonSituations":"CI or non-interactive shells with no tmux session; TMUX env var stale after detaching; psmux/wintmux compatibility shim printing extra output on Windows; tmux binary present but server dead.","solutions":["Verify a tmux session exists and is attached: run `tmux ls` and reattach with `tmux attach`.","Run the omx question command from inside an attached tmux pane.","If on Windows, confirm the psmux/wintmux shim is installed and returns standard tmux output.","Check that tmux version output formats match what the parser expects (run the underlying tmux command manually to inspect output)."],"exampleFix":null,"handlingStrategy":"fallback","validationCode":"import { execFileSync } from 'node:child_process';\nfunction tmuxWorks(): boolean {\n  try { execFileSync('tmux', ['-V'], { encoding: 'utf-8' }); return true; } catch { return false; }\n}","typeGuard":null,"tryCatchPattern":"try { launchQuestionRenderer(opts); } catch (e) { if (e instanceof Error && /Failed to create tmux question renderer container/.test(e.message)) { /* fall back to non-interactive/stdout question mode */ } else throw e; }","preventionTips":["Run inside an attached tmux session before launching question UI.","Health-check tmux (`tmux ls`) before calling launch APIs.","Prefer a headless question mode when tmux availability is uncertain."],"tags":["tmux","renderer","process-launch"],"backgroundTag":"tmux-pane-creation-failed","analyzedSha":"3ad79a8a6fe6e95fdbb8c00e40716fffe4011ce2","analyzedAt":"2026-08-27T22:18:39.783Z","schemaVersion":2},"datasetVersion":"2026-08-28T00:17:15.603Z"}