stablyai/orca · error
bin.orca target is not executable: ${binTarget}
Error message
bin.orca target is not executable: ${binTarget} What it means
On non-Windows platforms the bin target must have at least one executable bit set (mode & 0o111). The check reads stats.mode captured earlier; if no exec bit is set and --fix-executable was not passed, it throws. With --fix-executable it chmods the path to add 0o755. This guarantees the published CLI is invokable as `orca` from PATH on macOS/Linux.
Source
Thrown at config/scripts/verify-cli-bin.mjs:76
if (error && typeof error === 'object' && 'code' in error && error.code === 'ENOENT') {
throw new Error(
`compiled CLI package boundary is missing: ${path.relative(projectDir, outPackageJsonPath)}`
)
}
throw error
}
if (outPackageJson.type !== 'commonjs') {
throw new Error(
`compiled CLI package boundary must declare type=commonjs: ${path.relative(
projectDir,
outPackageJsonPath
)}`
)
}
if (process.platform !== 'win32' && (stats.mode & 0o111) === 0) {
if (!fixExecutable) {
throw new Error(`bin.orca target is not executable: ${binTarget}`)
}
chmodSync(binPath, stats.mode | 0o755)
}
if (runHelp) {
execFileSync(process.execPath, [binPath, '--help'], {
cwd: projectDir,
stdio: 'ignore'
})
}
return { binPath, outPackageJsonPath, size: statSync(binPath).size }
}
/** Runs CLI verification from npm scripts and local release checks. */
function main() {
const args = new Set(process.argv.slice(2))
const result = verifyPackageCliBin({View on GitHub (pinned to 1136503c6a)
Solutions
- Re-run verify-cli-bin with --fix-executable so it sets the exec bits (chmod | 0o755).
- Or `chmod +x <bin-path>` manually and re-run without flags.
- Fix the build/packaging step to preserve the exec bit so future builds don't regress.
Example fix
# before node config/scripts/verify-cli-bin.mjs # after node config/scripts/verify-cli-bin.mjs --fix-executable
Defensive patterns
Strategy: validation
Validate before calling
if (process.platform !== 'win32' && (statSync(binPath).mode & 0o111) === 0) {
// pass --fix-executable to the verifier, or chmod here
chmodSync(binPath, statSync(binPath).mode | 0o755)
} Prevention
- Run verify-cli-bin --fix-executable in CI to set exec bits automatically.
- Ensure packaging preserves the exec bit (use `cp -p`, tar with perms).
When it happens
Trigger: process.platform !== 'win32' AND (stats.mode & 0o111) === 0 AND fixExecutable is false, at line 74-76. Triggered when the build emits the bin without exec permission (e.g. a cp that reset mode, or a tarball extraction without --no-same-owner preserving perms).
Common situations: Building the CLI on one host and packaging on another where exec bits were stripped; a `cp` without -p; npm pack/unpack that normalized permissions.
Related errors
- bin.orca target must start with a Node shebang: ${binTarget}
- package.json must declare bin.orca
- bin.orca target is not a file: ${binTarget}
- bin.orca target is empty: ${binTarget}
- compiled CLI package boundary is missing: ${path.relative(pr
AI-assisted analysis of stablyai/orca@1136503c6a (2026-08-12).
Data as JSON: /api/errors/af2ea20aee232df4.
Report an issue: GitHub.