From 62ac73cdd79bee708d50b17a2dde8c23e0b66f1e Mon Sep 17 00:00:00 2001 From: morluto <76467478+morluto@users.noreply.github.com> Date: Fri, 24 Jul 2026 03:55:08 +0000 Subject: [PATCH] fix(process): expose launcher identity mismatch --- src/process/ProcessOwnership.ts | 4 ++-- tests/processOwnership.test.ts | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/process/ProcessOwnership.ts b/src/process/ProcessOwnership.ts index bdaff58b4d..0f501234af 100644 --- a/src/process/ProcessOwnership.ts +++ b/src/process/ProcessOwnership.ts @@ -322,7 +322,7 @@ const launcherIdentityFailure = ( ownership.expectedCommand !== undefined && !matchesOwnedProcessCommand(launcher.command, ownership.expectedCommand) ) - return "owned launcher command identity did not match"; + return `owned launcher command identity did not match (observed=${launcher.command}; expected=${ownership.expectedCommand})`; return null; }; @@ -477,7 +477,7 @@ export const observeOwnedProcessLineage = async ( ) return unavailableLineage( ownership, - "owned launcher command identity did not match", + `owned launcher command identity did not match (observed=${launcher.command}; expected=${ownership.expectedCommand})`, ); const descendants = descendantsOf(launcher.pid, processes); for (const member of [launcher, ...descendants]) { diff --git a/tests/processOwnership.test.ts b/tests/processOwnership.test.ts index d3bf6d6558..6cca3295da 100644 --- a/tests/processOwnership.test.ts +++ b/tests/processOwnership.test.ts @@ -522,7 +522,8 @@ describe("owned process-group cleanup", () => { ), ).toEqual({ cleaned: false, - reason: "owned launcher command identity did not match", + reason: + "owned launcher command identity did not match (observed=fixture; expected=/owned/hopper)", }); expect(signalGroup).not.toHaveBeenCalled(); });