thedotmack/claude-mem · warning
claude-mem: bun --version probe failed:
Error message
claude-mem: bun --version probe failed:
What it means
getBunVersion() spawns `bun --version` through spawnVersionProbe. If the spawn itself throws (ENOENT because bun disappeared between the path lookup and the spawn, EACCES on a non-executable shim, or a broken version-manager shim), the warning prints and the function returns null, so the installer treats bun as absent and takes its missing-bun path (prompting you to install bun or use the documented fallback).
Source
Thrown at src/npx-cli/install/setup-runtime.ts:118
export function getBunPath(): string | null {
return getToolPath('bun', BUN_COMMON_PATHS);
}
function isBunInstalled(): boolean {
return getBunPath() !== null;
}
export function getBunVersion(): string | null {
const bunPath = getBunPath();
if (!bunPath) return null;
try {
const result = spawnVersionProbe(bunPath, ['--version']);
return result.status === 0 ? result.stdout.trim() : null;
} catch (error) {
const err = error instanceof Error ? error : new Error(String(error));
console.warn('claude-mem: bun --version probe failed:', err);
return null;
}
}
function getUvPath(): string | null {
return getToolPath('uv', UV_COMMON_PATHS);
}
function isUvInstalled(): boolean {
return getUvPath() !== null;
}
export function getUvVersion(): string | null {
const uvPath = getUvPath();
if (!uvPath) return null;
try {
const result = spawnVersionProbe(uvPath, ['--version']);View on GitHub (pinned to e2d1df569a)
Solutions
- Confirm bun works in the same context the installer runs: `bun --version` from a plain shell and from CI
- Reinstall bun if the shim is broken (curl -fsSL https://bun.sh/install | bash, or brew install bun)
- Check the resolved path is executable: ls -l $(which bun) and run $(which bun) --version
- If bun is intentionally absent, follow the installer's uv/Node fallback; the warning is informational
Defensive patterns
Strategy: validation
Validate before calling
import { spawnSync } from 'node:child_process';
const probe = spawnSync('bun', ['--version'], { encoding: 'utf8' });
if (probe.error) {
// ENOENT/EACCES here predicts the installer's 'bun --version probe failed' warning
// fix PATH or install bun before running `npx claude-mem install`
} Type guard
function isErrnoException(error: unknown): error is NodeJS.ErrnoException {
return error instanceof Error && typeof (error as NodeJS.ErrnoException).code === 'string'
&& ['ENOENT', 'EACCES', 'EPERM'].includes((error as NodeJS.ErrnoException).code);
} Prevention
- Install bun for the same user and environment that runs claude-mem install
- Avoid version-manager shims that require an interactive shell in service/CI contexts
- Keep PATH stable between the path probe and the version spawn during long installs
When it happens
Trigger: `npx claude-mem install` when bun was found on PATH earlier by getBunPath() but the binary is gone at spawn time, a mise/asdf/volta shim for bun is broken, or the install runs in an environment (CI, service context) whose PATH differs from your interactive shell.
Common situations: bun uninstalled or renamed mid-probe; shims that fail outside an interactive shell; bun installed for a different user; PATH ordering changing between the path probe and the version spawn.
Related errors
- claude-mem: uv --version probe failed:
- API key prompt cancelled — leaving existing configuration un
- Gateway setup cancelled — leaving existing configuration unt
- Provider=${options.provider} requested non-interactively. AP
- Couldn't reach cmem.ai — start the trial later with npx clau
AI-assisted analysis of thedotmack/claude-mem@e2d1df569a (2026-08-20).
Data as JSON: /api/errors/1a585b04115234cc.
Report an issue: GitHub.