From 91903bac152b709700a22ba6a1751dda6005844d Mon Sep 17 00:00:00 2001 From: "Buddy (AI)" Date: Mon, 16 Feb 2026 19:28:50 +0000 Subject: [PATCH] fix: include OPENCLAW_SERVICE_VERSION in system presence version detection MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The gateway's system-presence.ts was not detecting the version when OpenClaw is run as a launchd service, because the daemon-runtime.ts sets OPENCLAW_SERVICE_VERSION but system-presence.ts only checked OPENCLAW_VERSION and npm_package_version. This caused 'openclaw status' to show 'unknown' for the version. Issue: #18456 🤖 AI-assisted (lightly tested) --- src/infra/system-presence.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/infra/system-presence.ts b/src/infra/system-presence.ts index c8e7ac262..de7db5201 100644 --- a/src/infra/system-presence.ts +++ b/src/infra/system-presence.ts @@ -50,7 +50,7 @@ function resolvePrimaryIPv4(): string | undefined { function initSelfPresence() { const host = os.hostname(); const ip = resolvePrimaryIPv4() ?? undefined; - const version = process.env.OPENCLAW_VERSION ?? process.env.npm_package_version ?? "unknown"; + const version = process.env.OPENCLAW_VERSION ?? process.env.OPENCLAW_SERVICE_VERSION ?? process.env.npm_package_version ?? "unknown"; const modelIdentifier = (() => { const p = os.platform(); if (p === "darwin") {