can1357/oh-my-pi · error · Error
Timed out fetching release info for ${pkg} after ${Math.roun
Error message
Timed out fetching release info for ${pkg} after ${Math.round(timeoutMs / 1000)}s What it means
Thrown when the HTTP request to the npm registry (NPM_REGISTRY/<pkg>/latest or /canary) during an `omp update` check does not complete within `timeoutMs`. The underlying fetch abort is detected via `isTimeoutError` and rethrown as this user-facing Error with the original abort as `cause`. It guards the updater against hanging indefinitely on a slow or unresponsive network path.
Source
Thrown at packages/coding-agent/src/cli/update-cli.ts:773
throw new Error(`Could not resolve ${APP_NAME} binary path in PATH`);
}
/** Bound on `omp.rename` hops so a broken pointer chain cannot loop forever. */
const MAX_RENAME_HOPS = 3;
async function fetchLatestManifest(
pkg: string,
timeoutMs: number,
channel: UpdateChannel,
): Promise<{ version: string; manifest: Record<string, unknown> }> {
let response: Response;
try {
response = await fetch(`${NPM_REGISTRY}${pkg}/${channel === "canary" ? "canary" : "latest"}`, {
signal: withTimeoutSignal(timeoutMs),
});
} catch (err) {
if (isTimeoutError(err)) {
throw new Error(`Timed out fetching release info for ${pkg} after ${Math.round(timeoutMs / 1000)}s`, {
cause: err,
});
}
if (isUnsupportedProxyError(err)) throw new Error(unsupportedProxyMessage(), { cause: err });
throw err;
}
if (!response.ok) {
if (response.status === 404 && channel === "canary") {
throw new Error(`No canary release has been published for ${pkg} yet. Try \`${APP_NAME} update --stable\`.`);
}
throw new Error(`Failed to fetch release info for ${pkg}: ${response.statusText}`);
}
const data: unknown = await response.json();
if (!isRecord(data) || typeof data.version !== "string") {
throw new Error(`Malformed npm registry response for ${pkg}: missing version`);
}
return { version: data.version, manifest: data };View on GitHub (pinned to 9690622007)
Solutions
- Check network connectivity to the npm registry (curl https://registry.npmjs.org/<pkg>/latest) and retry the update
- Verify HTTP_PROXY/HTTPS_PROXY point at a working http(s) proxy; fix or unset them
- Retry later or from a different network (VPN off, corporate proxy bypassed)
- If timeouts persist despite good connectivity, reinstall manually via the official installer
Example fix
// before: update fails behind a dead proxy export HTTPS_PROXY=http://127.0.0.1:9999 omp update // after: point at a reachable proxy or unset unset HTTPS_PROXY HTTP_PROXY omp update
Defensive patterns
Strategy: retry
Validate before calling
// quick reachability probe before running the updater curl -sf --max-time 10 https://registry.npmjs.org/oh-my-pi/latest >/dev/null && echo ok || echo registry-unreachable
Try / catch
try {
await runUpdate();
} catch (err) {
if (isTimeoutError(err)) {
// exponential backoff, then surface a friendly offline message
await Bun.sleep(2000);
return retryUpdate(2);
}
throw err;
} Prevention
- Ensure stable connectivity or a working proxy before updating
- Run updates on a network that can reach registry.npmjs.org
- Keep the default timeout generous; don't shrink it on slow links
- Check for captive portals on hotel/conference Wi-Fi before updating
When it happens
Trigger: Running the update check (fetch of latest/canary release metadata from the npm registry) when the fetch aborts via `withTimeoutSignal(timeoutMs)` because the response did not arrive in time.
Common situations: Slow or flaky network, offline machine with long DNS hangs, corporate firewalls silently dropping packets to registry.npmjs.org, heavily loaded proxy, or an excessively small timeout value.
Understand the failure class
- Timeouts: ETIMEDOUT, deadlines, and hung requests — what actually expires when a request times out.
Related errors
- Failed to fetch release info for ${pkg}: ${response.statusTe
- timed out: {command}
- AnthropicConnectionTimeoutError
- xAI device-code request failed: ${error instanceof Error ? e
- xAI device-code token polling failed: ${error instanceof Err
AI-assisted analysis of can1357/oh-my-pi@9690622007 (2026-08-31).
Data as JSON: /api/errors/e373cd5140fe8a67.
Report an issue: GitHub.