Yeachan-Heo/oh-my-codex · error · Error
launch instructions file not found
Error message
launch instructions file not found: ${appendixPath} What it means
A configured launch-instructions appendix file (an extra prompt/instructions file to append at launch) was specified but does not exist on disk. The builder refuses to silently skip it, so it throws with the offending path.
Solutions
- Check the path in the error message and create or restore the file
- If the path is relative, run from the project root or change the config to an absolute/repo-relative path that resolves from the launch cwd
- Remove the appendix setting from config if the file is no longer needed
- If it should be per-machine, template the config (e.g. gitignore a local override)
Example fix
// before
instructionsAppendix: "./AGENTS_APPENDIX.local.md" // missing on this machine
// after
instructionsAppendix: existsSync("./AGENTS_APPENDIX.local.md") ? "./AGENTS_APPENDIX.local.md" : undefined Defensive patterns
Strategy: validation
Validate before calling
import { existsSync } from "node:fs";
const appendix = config.instructionsAppendix;
if (appendix && !existsSync(resolve(cwd, appendix))) config.instructionsAppendix = undefined; Try / catch
try { await launch(cfg); } catch (e) { if (e instanceof Error && e.message.startsWith("launch instructions file not found")) { /* fix path or drop setting */ } throw e; } Prevention
- Use repo-relative or absolute paths for instruction appendix files
- Commit shared instruction files; gitignore only per-machine overrides
- Validate configured file paths at startup in wrapper scripts
When it happens
Trigger: Configuration (e.g. agent config or launch flags) points at an instructions appendix path that is missing — relative path resolved against an unexpected cwd, a typo, a file not committed/created, or a worktree where the file exists only on another branch.
Common situations: Teammates cloning a repo where a local uncommitted instructions file is configured; running OMX from a different directory so a relative path no longer resolves; renamed or deleted instruction files after a refactor.
Understand the failure class
Background: "Config file not found": what it means and how to fix it in docker-sync, Maven, Vagrant, Turborepo and other tools — this error's family across 60 libraries.
Related errors
- `allowed_modes` must be a non-empty string array
- artifact_missing
- [ask] --agent-prompt role
- autoresearch_candidate_missing
- canonical_scale_down_config_missing
AI-assisted analysis of Yeachan-Heo/oh-my-codex@3ad79a8a6f (2026-08-27).
Data as JSON: /api/errors/18ecdad450e16bc0.
Report an issue: GitHub.
Appendix: source
Thrown at src/cli/index.ts:5520
args: ["set-option", "-t", sessionName, OMX_INSTANCE_OPTION, sessionId],
},
]
: []),
{ name: "split-and-capture-hud-pane", args: splitCaptureArgs },
];
}
async function readLaunchAppendInstructions(): Promise<string> {
const appendixCandidates = [
process.env[OMX_RALPH_APPEND_INSTRUCTIONS_FILE_ENV]?.trim(),
process.env[OMX_AUTORESEARCH_APPEND_INSTRUCTIONS_FILE_ENV]?.trim(),
].filter(
(value): value is string => typeof value === "string" && value.length > 0,
);
if (appendixCandidates.length === 0) return "";
const appendixPath = appendixCandidates[0];
if (!existsSync(appendixPath)) {
throw new Error(`launch instructions file not found: ${appendixPath}`);
}
const { readFile } = await import("fs/promises");
return (await readFile(appendixPath, "utf-8")).trim();
}
export function shouldAttachDetachedTmuxSession(
env: NodeJS.ProcessEnv = process.env,
): boolean {
return env.OMX_HERMES_MCP_BRIDGE !== "1";
}
function stripHermesMcpBridgeEnv(env: NodeJS.ProcessEnv): NodeJS.ProcessEnv {
const { OMX_HERMES_MCP_BRIDGE: _bridge, ...rest } = env;
return rest;
}
export function buildDetachedSessionFinalizeSteps(
sessionName: string,View on GitHub (pinned to 3ad79a8a6f)