can1357/oh-my-pi · error · Error
${displayName} executable not found on PATH
Error message
${displayName} executable not found on PATH What it means
`resolveRuntime` in runtime-env.ts locates a language interpreter (binaryName, e.g. "ruby" or "julia" or a configured interpreter path) to host eval runtimes. If no explicit interpreter is configured and `$which(binaryName)` cannot find the executable on PATH, it throws `Error("<Name> executable not found on PATH")` with the capitalized binary name.
Source
Thrown at packages/coding-agent/src/eval/runtime-env.ts:101
}
const systemPath = $which(binaryName);
return systemPath ? [createRuntime(systemPath, baseEnv)] : [];
}
/**
* Resolves the highest-priority runtime. Throws when none exists.
*/
export function resolveRuntime<T>(
cwd: string,
baseEnv: Record<string, string | undefined>,
binaryName: string,
createRuntime: (executablePath: string, env: Record<string, string | undefined>) => T,
interpreter?: string,
): T {
const [runtime] = enumerateRuntimes(cwd, baseEnv, binaryName, createRuntime, interpreter);
if (!runtime) {
const displayName = binaryName.charAt(0).toUpperCase() + binaryName.slice(1);
throw new Error(`${displayName} executable not found on PATH`);
}
return runtime;
}
View on GitHub (pinned to 9690622007)
Solutions
- Install the interpreter (e.g. `apt install ruby` / `brew install ruby` / `juliaup`) and reopen the terminal so PATH updates.
- Verify availability with `which ruby` (or `which julia`); if missing, add the version-manager shim dir to PATH.
- Configure the eval runtime's `interpreter` option to an explicit absolute path to the executable.
- In CI, add a setup step (ruby/setup-ruby, julia-actions/setup-julia) before running evals.
Example fix
// before
// throws: Ruby executable not found on PATH
// after
// option: { interpreter: "/Users/me/.rbenv/shims/ruby" } — or install ruby and ensure PATH includes it
const runtime = resolveRuntime(cwd, env, "ruby", createRuntime); Defensive patterns
Strategy: validation
Validate before calling
import { $which } from "@oh-my-pi/pi-utils";
if (!interpreter && !(await $which(binaryName))) {
throw new Error(`${binaryName} is not installed or not on PATH — install it or set the interpreter option`);
}
const runtime = resolveRuntime(cwd, env, binaryName, createRuntime, interpreter); Try / catch
let runtime: EvalRuntime;
try {
runtime = resolveRuntime(cwd, env, "ruby", createRubyRuntime);
} catch (err) {
if (err instanceof Error && err.message.endsWith("not found on PATH")) {
// surface install instructions or disable the eval language
throw new SkipEvalError(err.message);
}
throw err;
} Prevention
- Check `which <binary>` in the deployment image / CI before enabling that language's eval cells.
- Configure an explicit absolute `interpreter` path in environments with nonstandard toolchains.
- Ensure version-manager shim dirs (rbenv, asdf, juliaup) are on PATH for the process that launches omp.
- Add interpreter installation to setup scripts/Dockerfiles so PATH resolution always succeeds.
When it happens
Trigger: Starting a Ruby/Julia eval cell when the interpreter binary is not installed or not on PATH; a configured `interpreter` setting resolving to a nonexistent absolute path is also surfaced through this same throw path only when enumeration returns no runtime; running inside an env whose PATH lacks the toolchain (IDE launched from Finder, CI container, nvm/asdf shim not initialized).
Common situations: Fresh machine without ruby/julia installed; version manager (rbenv, asdf, juliaup) not on PATH in the process environment; Docker image missing the runtime; typo in configured interpreter path handled upstream but binary fallback missing here.
Related errors
- ssh binary not found on PATH
- imageUrls exposure "${name}" requires the ${name} binary on
- Could not resolve ${APP_NAME} binary path in PATH
- ${availability.reason ?? "Julia kernel unavailable"}
- ${availability.reason ?? "Julia kernel unavailable"}
AI-assisted analysis of can1357/oh-my-pi@9690622007 (2026-08-31).
Data as JSON: /api/errors/f824e8514abebb0b.
Report an issue: GitHub.