qwen-code/packages/cli
pikachu 3e8b3c688f
fix(cli): serialize subagent confirmation focus to prevent concurrent input conflicts (#2930)
* fix: serialize subagent confirmation focus to prevent concurrent input conflicts

When multiple subagents run in parallel and each triggers a confirmation
prompt, all prompts previously received keyboard focus simultaneously,
causing a single keypress to be dispatched to every active confirmation.

This change introduces a first-come-first-served focus lock mechanism:
- Track subagents with pending confirmations via a type guard
- Use a useRef-based lock so only one confirmation is focused at a time
- Automatically promote focus to the next pending subagent on resolution
- Show a waiting indicator on non-focused confirmations

Fixes #2929

* fix(cli): use dedicated prop for subagent approval waiting state

---------

Co-authored-by: 思晗 <housihan.hsh@alibaba-inc.com>
2026-04-09 14:24:59 +08:00
..
src fix(cli): serialize subagent confirmation focus to prevent concurrent input conflicts (#2930) 2026-04-09 14:24:59 +08:00
index.ts fix(cli): sync PTY race condition error handling to global uncaughtException 2026-03-23 21:23:27 +08:00
package.json fix(release): run release:version 0.14.2 to sync all package versions (#3026) 2026-04-08 21:33:40 +08:00
test-setup.ts fix: prevent bogus shell permission rules in tests 2026-03-20 17:55:33 +08:00
tsconfig.json Merge pull request #2428 from qqqys/feat/mcp_reconnect_error 2026-04-01 16:53:36 +08:00
vitest.config.ts refactor(core): Unify package exports and improve dev experience 2026-02-01 11:59:05 +08:00