Target the newest shell instance for IPC calls
qs parses -n before the ipc subcommand as its top-level --no-duplicate launch flag and silently ignores it, so IPC still went to the oldest matching instance - exactly the stale one left behind around a restart. The --newest flag belongs to the ipc subcommand: qs ipc -n. Verified against two live instances; the test now pins the flag position. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Fable 5
parent
289e6d12fc
commit
094619fbd5
+1
-1
@@ -48,7 +48,7 @@ fi
|
||||
# positionals. qs reports connection failures with a nonzero exit, but IPC-level
|
||||
# failures (unknown target/function, bad arguments) go to stdout with exit 0.
|
||||
ipc_timeout=${OMARCHY_SHELL_IPC_TIMEOUT:-2s}
|
||||
output=$(timeout --kill-after=1s "$ipc_timeout" qs -p "$OMARCHY_PATH/shell" ipc call -- "$@" 2>/dev/null)
|
||||
output=$(timeout --kill-after=1s "$ipc_timeout" qs ipc -n -p "$OMARCHY_PATH/shell" call -- "$@" 2>/dev/null)
|
||||
ipc_status=$?
|
||||
|
||||
if (( ipc_status == 124 || ipc_status == 137 )); then
|
||||
|
||||
Reference in New Issue
Block a user