From fb35cf6aa54a0ef9171ab7de58d819308aced175 Mon Sep 17 00:00:00 2001 From: Arun Kumar Thiagarajan <222980227+HMAKT99@users.noreply.github.com> Date: Tue, 24 Nov 2026 09:09:09 +0530 Subject: [PATCH 1/2] Detect agents started through an npm bin link (Qwen Code, Gemini CLI) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit A global npm install or npx runs an agent as `node /…/bin/qwen`. That path doesn't contain the package name, so the argument markers missed it and Qwen Code (and Gemini CLI, Amp) weren't recognised. For a Node, Bun, Deno or Python launcher, the script it runs now also matches the agent's names. Verified live: a Qwen Code 0.28.4 session started from its bin link was missed by 0.1.10 and is now detected with its project. Co-Authored-By: Claude Opus 5.5 --- crates/process-manager/src/agents.rs | 58 +++++++++++++++++++++++++++- 1 file changed, 57 insertions(+), 1 deletion(-) diff --git a/crates/process-manager/src/agents.rs b/crates/process-manager/src/agents.rs index 4e77ff3..54cd0f7 100644 --- a/crates/process-manager/src/agents.rs +++ b/crates/process-manager/src/agents.rs @@ -186,8 +186,17 @@ pub fn identify(p: &ProcessInfo) -> Option<&'static AgentSignature> { .take(3) .map(|a| a.replace('\\', "/")) .collect(); + // The script a launcher runs: `node /opt/homebrew/bin/qwen` runs `qwen`. + // Global npm installs and npx start agents through such a bin link, whose + // path does not contain the package name. + let launched = is_launcher(name) + .then(|| args.iter().skip(1).find(|a| !a.starts_with('-'))) + .flatten() + .and_then(|a| a.rsplit('/').next()); AGENTS.iter().find(|a| { - a.names.iter().any(|n| name == *n || exe_name == Some(n)) + a.names + .iter() + .any(|n| name == *n || exe_name == Some(n) || launched == Some(n)) // Node/Python launchers: the agent is named in the first few arguments. || (is_launcher(name) && args.iter().any(|arg| a.arg_markers.iter().any(|m| arg.contains(m)))) @@ -787,6 +796,53 @@ mod tests { assert_eq!(identify(&plain).map(|a| a.id), None); } + #[test] + fn identifies_agents_started_through_a_bin_link() { + // `npm i -g` / npx: node runs the bin link, not the package path. + let cases = [ + (&["node", "/opt/homebrew/bin/qwen"][..], "qwen-code"), + ( + &["node", "/Users/u/.npm/_npx/1a2b/node_modules/.bin/qwen"][..], + "qwen-code", + ), + ( + &["node", "--no-warnings", "/usr/local/bin/gemini"][..], + "gemini-cli", + ), + ( + &["node", "/opt/homebrew/bin/openclaw", "gateway"][..], + "openclaw", + ), + (&["python3", "/Users/u/.local/bin/aider"][..], "aider"), + ]; + for (args, want) in cases { + assert_eq!( + identify(&proc(10, 1, args[0], args, 100)).map(|a| a.id), + Some(want), + "{args:?}" + ); + } + // The package path still works, and ordinary scripts are not agents. + let pkg = [ + "node", + "/opt/homebrew/lib/node_modules/@qwen-code/qwen-code/cli-entry.js", + ]; + assert_eq!( + identify(&proc(11, 1, "node", &pkg, 100)).map(|a| a.id), + Some("qwen-code") + ); + for args in [ + &["node", "server.js", "qwen"][..], + &["node", "/srv/app/index.js"][..], + ] { + assert_eq!( + identify(&proc(12, 1, "node", args, 100)).map(|a| a.id), + None, + "{args:?}" + ); + } + } + #[test] fn gui_apps_are_hosts_not_sessions() { let mut p = proc(5, 1, "claude", &[], 10); From 14326340f2e65383bb0a60f14a7d72ea49c6964e Mon Sep 17 00:00:00 2001 From: Arun Kumar Thiagarajan <222980227+HMAKT99@users.noreply.github.com> Date: Tue, 24 Nov 2026 09:23:42 +0530 Subject: [PATCH 2/2] Update cookie to 0.18.3 (RUSTSEC-2026-0594) Published today; cargo-deny now fails every PR. cookie comes in through Tauri. AGASTHY doesn't use private cookies or fork, but the patched version clears the advisory. Co-Authored-By: Claude Opus 5.5 --- Cargo.lock | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index a429ade..7987daf 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -732,9 +732,9 @@ dependencies = [ [[package]] name = "cookie" -version = "0.18.2" +version = "0.18.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a373e3602691c3cdea496d2f0ee5935151e6168fe87739483c463db1b2f2f87" +checksum = "d55f2d6c30eeec7d5c6f98bd4395d4abb1895629eab97ee6522d340623615f8a" dependencies = [ "time", "version_check",