Coding Agents & Terminal · recorded 2026-08-29 · applies to 1 tool(s) ✓ Verified

Problem: Install succeeds but omp --version reports SyntaxError (old bun) —— Trove problem library

Verified 2026-08-29omp --version throws SyntaxError — old bun is incompatible; upgrade bun to >=1.3.14 and re-verify.

Quick fix

# One-liner: upgrade bun to >=1.3.14, then verify the version
curl -fsSL https://bun.sh/install | bash && bun --version && omp --version

What you will run into

bun install -g @oh-my-pi/pi-coding-agent shows a successful install, but omp --version throws SyntaxError (or fails silently with no version output). Installed but won't run, and the error doesn't even hint at a version incompatibility.

Why this happens

package.json engines requires bun >=1.3.14 (measured in this marketplace by actually reading the engines field);

bun 1.3.11 and earlier fail to parse the new syntax when running this package, throwing SyntaxError without mentioning the version incompatibility (source: Qiita kai_kou, retrieved 2026-08;

OrcaRouter Chinese docs also mark bun >=1.3.14, cross-confirmed).

bun install -g only handles "put the package into the global directory" (install time); it does not handle "will this package run afterwards" (runtime) — it's a static installer, not a runtime.

What's installed is JS code; execution only happens later when the bun runtime parses and runs it line by line. When the runtime is too old, new syntax in the package's code (new sugar/new APIs) fails to parse.

The insidious part of SyntaxError is that it points at "which line the parser doesn't recognize", not at "version" — if the package's entry file uses new syntax, the old runtime crashes at the first new syntax in cli.js, and the error gives no hint that it's a version problem.

So the check order for "install succeeded ≠ it can run" is fixed: bun --version first (verify the runtime against the engines-declared line, e.g. >=1.3.14) -> then omp --version (verify the command surface).

Conversely, silent failure (no output at all) is the same root cause — the entry crashes at parse time before it ever gets a chance to print a version.

bun versionomp --version result
1.3.11 and earlier❌ SyntaxError (measured: SyntaxError: Unexpected identifier 'u', cli.js:159:1)
≥1.3.14 (measured 1.4.0)✅ omp/18.0.9 normal

Step by step

1. Upgrade bun — Required

curl -fsSL https://bun.sh/install | bash

Or upgrade via a package manager; verify bun --version ≥1.3.14.

2. Rerun the version command — Required

omp --version

Expected output omp/<version> (measured 18.0.9).

How to confirm it works

Version output normal (measured output shape):

omp --version
→ omp/18.0.9 (measured on bun 1.4.0)

Before upgrade: bun 1.3.11 → SyntaxError: Unexpected identifier 'u' (measured reproduction, matching the Qiita symptom).

Other environments

EnvironmentNotes
bun <1.3.14Upgrade bun first, then run
Package-manager upgradebrew/apt etc. per bun's official method
Silent failureNo version output = same root cause; check the bun version first
Windowsbun installer applies the same way

Symptom

bun install -g @oh-my-pi/pi-coding-agent reports success, but omp --version throws SyntaxError (or fails silently with no version output).

Cause

package.json engines requires bun >=1.3.14 (engines field actually read in this marketplace); bun 1.3.11 and earlier fail to parse the new syntax when running this package, throwing SyntaxError without mentioning the version incompatibility (source: Qiita kai_kou, retrieved 2026-08; OrcaRouter Chinese docs also mark bun >=1.3.14, cross-confirmed).

Solution

  1. Upgrade bun to >=1.3.14: curl -fsSL https://bun.sh/install | bash (or upgrade via a package manager), verify with bun --version.
  2. After upgrading, re-run omp --version and confirm it outputs omp/<version>.
Verification Evidence
  • Verified in this marketplace (2026-08-28, bun 1.4.0): after local project install of @oh-my-pi/pi-coding-agent@18.0.9, omp --version outputs omp/18.0.9; package.json engines actually read as {'bun': '>=1.3.14'}.
  • Old bun 1.3.11 reproduction (completed 2026-08-28): with bun 1.3.11 prepended to PATH, omp --version -> SyntaxError: Unexpected identifier 'u' (cli.js:159:1), matching the Qiita symptom; control with bun 1.4.0 -> omp/18.0.9 normal (local repro log 2026-08-28).

Applicable tools (1)

This problem is linked from the tool pages below — reachable from either side.

oh-my-pi

Source & evidence

Recorded Verified ✓ VerifiedApplies to 1 tool(s)
Entries contain locally measured or reviewable-source solutions; unmeasured items are explicitly labeled.

← Coding Agents & Terminal domain | Problem Catalog Experience | Facing another issue? Go to the Helpdesk