Commit graph

2638 commits

Author SHA1 Message Date
tanzhenxin
e181cfc097
Merge pull request #2315 from xuewenjie123/fix/remove-qrcode-from-oauth-progress-v2
fix: remove QR code from OAuth authentication UI to prevent screen flickering
2026-03-12 18:53:25 +08:00
Mingholy
1d87675534
Merge pull request #2298 from QwenLM/mingholy/fix/vscode-acp-error
fix: improve ACP file operation error handling
2026-03-12 17:53:23 +08:00
tanzhenxin
1da0c2bf30 refactor(ui): remove spinner from OAuth progress component
This simplifies the OAuth progress UI by removing the animated spinner,
resulting in a cleaner, more maintainable component.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-12 17:34:08 +08:00
tanzhenxin
4ee94715df feat(arena): improve cancellation handling and simplify to in-process mode
Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>

- Track user-initiated cancellation separately from failures

- Cancel round immediately when user denies a tool call

- Add message queue to handle input during streaming

- Add info messages during Arena operations (apply, stop, cleanup)

- Disable tmux/iTerm2 backends (only in-process mode supported)

- Polish UI: green tool count, updated warning prefix

This improves the Arena UX by providing clearer feedback and

properly handling user cancellations without treating them as failures.
2026-03-12 16:57:44 +08:00
xwj02155382
67089ed532 test: update OAuth progress and header tests for UI changes
- Update Header.test.tsx to expect single border (┌┐) instead of round (╭╯)
- Update QwenOAuthProgress.test.tsx:
  - Change cancel text expectation from '(Press ESC or CTRL+C to cancel)' to 'Esc to cancel'
  - Update loading state test to expect 'Qwen OAuth Authentication' title
  - Simplify animated dots test to avoid timing sensitivity
  - Rename 'gray border' test to 'single border' test

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-12 16:42:43 +08:00
xwj02155382
928701d688 refactor: simplify OAuth progress UI and use semantic colors
- Replace round border with single border style for consistency
- Use semantic-colors theme instead of Colors enum
- Add i18n translations for error messages and status text
- Simplify dots animation with fixed-width cycling patterns
- Consolidate into single bordered box layout
- Add Esc to cancel hint for better UX

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-12 16:23:05 +08:00
tanzhenxin
61fac4b15b test(cli): remove flaky tab navigation test
Remove the 'navigates between tabs with left/right arrows' test from
AskUserQuestionDialog.test.tsx due to timing-related flakiness.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-12 14:09:54 +08:00
xwj02155382
da7a0e8dbd fix: remove qrcode-terminal dependency and update tests
- Remove qrcode-terminal from packages/cli/package.json dependencies
- Remove @types/qrcode-terminal from root package.json devDependencies
- Update QwenOAuthProgress.test.tsx to remove QR code related tests
- Remove qrcode-terminal mock from qwenOAuth2.test.ts

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-12 13:42:59 +08:00
xuewenjie
74315a1aa4 fix: remove QR code from OAuth authentication UI to prevent screen flickering
Remove the terminal QR code display from the OAuth authentication progress
component. The QR code caused severe screen flickering on Windows PowerShell
due to Ink's full re-render cycle combined with the large character volume
of the QR code and high-frequency state updates (spinner + countdown timer).

The authorization URL link is preserved for users to complete authentication.

Changes:
- Remove qrcode-terminal import and QrCodeDisplay component
- Replace with simplified AuthUrlDisplay component (URL only)
- Remove qrCodeData state and QR code generation useEffect
- Remove unused createDebugLogger import and debugLogger instance
2026-03-12 13:42:58 +08:00
tanzhenxin
9890625de7 chore: bump version to 0.12.2
Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-12 10:02:48 +08:00
pomelo
2a8366390d
Merge pull request #2268 from QwenLM/fix/export-current-session
Some checks are pending
Qwen Code CI / Lint (push) Waiting to run
Qwen Code CI / Test (push) Blocked by required conditions
Qwen Code CI / Test-1 (push) Blocked by required conditions
Qwen Code CI / Test-2 (push) Blocked by required conditions
Qwen Code CI / Test-3 (push) Blocked by required conditions
Qwen Code CI / Test-4 (push) Blocked by required conditions
Qwen Code CI / Test-5 (push) Blocked by required conditions
Qwen Code CI / Test-6 (push) Blocked by required conditions
Qwen Code CI / Test-7 (push) Blocked by required conditions
Qwen Code CI / Test-8 (push) Blocked by required conditions
Qwen Code CI / Post Coverage Comment (push) Blocked by required conditions
Qwen Code CI / CodeQL (push) Waiting to run
E2E Tests / E2E Test (Linux) - sandbox:docker (push) Waiting to run
E2E Tests / E2E Test (Linux) - sandbox:none (push) Waiting to run
E2E Tests / E2E Test - macOS (push) Waiting to run
fix: export command should use current session ID instead of loadLastSession
2026-03-11 22:38:45 +08:00
mingholy.lmh
2cbd092835 fix(core): handle ENOENT from ACP readTextFileWithInfo gracefully
- Add readTextFileWithInfo implementation in AcpFileSystemService
- Convert RESOURCE_NOT_FOUND errors to ENOENT for consistent handling
- Strip UTF-8 BOM from ACP responses
- Treat ENOENT errors in write-file tool as new file creation

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-11 22:37:03 +08:00
LaZzyMan
16ca92897e fix test 2026-03-11 19:13:14 +08:00
tanzhenxin
741aa436e3 fix(cli): suppress Windows pty resize race condition
Add global uncaught exception handler to suppress known race condition
in @lydell/node-pty where a deferred resize fires after the pty process
has already exited on Windows.

Tracking bug: https://github.com/microsoft/node-pty/issues/827

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-11 18:40:04 +08:00
LaZzyMan
7450067e37 Merge branch 'main' into feat/support-permission 2026-03-11 17:11:28 +08:00
xwj02155382
d5eda197c2 refactor: extract HOOK_DEFINITION_ITEMS constant
Extract common hook definition items schema into a reusable constant
to avoid code duplication between UserPromptSubmit and Stop hooks.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-11 15:23:01 +08:00
xwj02155382
700806ce83 fix: correct hooks JSON schema type definition
The hooks array items were incorrectly typed as 'string' in the JSON
schema, causing VS Code to show type errors when users configure
HookDefinition objects. This fix adds proper schema support for complex
array item types.

- Add SettingItemDefinition interface for array item schema
- Add items schema for UserPromptSubmit and Stop hooks
- Update generate-settings-schema.ts to convert complex item types

Fixes #2246

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-11 15:09:49 +08:00
DennisYu07
91179fa6db resolve comment 2026-03-10 22:37:48 -07:00
tanzhenxin
3233d16b5c feat(arena): add system reminder and status file support for agent collaboration
Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>

Extract atomic file write utility into reusable module. Add arena system reminder injection so orchestrating agents can discover active arena sessions. Support in-process mode status file writing for external consumers.

This enables agent-to-agent collaboration where a parent agent can monitor and coordinate arena sessions via file-based status files.
2026-03-11 11:56:05 +08:00
DennisYu07
d5d7187479 move move notification auth_success from useAuth to config to support both interactive and non-interactive 2026-03-10 20:50:03 -07:00
pomelo-nwu
f13a2fdf17 fix: export command should use current session ID instead of loadLastSession
The /export commands (html, md, json, jsonl) were incorrectly using
loadLastSession() which loads the last modified session from disk,
rather than the currently active session.

This fix uses config.getSessionId() to get the current session ID
and loads the correct session with loadSession(sessionId).

Fixes #2267

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-11 11:16:29 +08:00
tanzhenxin
cecc960254 feat(arena): improve agent UI with header info and simplify worktree branches
- Add AgentHeader component showing model, path, and git branch
- Separate modelId and modelName in RegisteredAgent for cleaner display
- Simplify worktree branch naming from worktrees/session/name to base-session-name
- Change loading text from "Agent is working…" to "Thinking…"
- Make agent footer always visible (not just when input is active)

This improves the agent collaboration UX by providing context about each
agent's environment and simplifies the git worktree management.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-11 11:04:46 +08:00
LaZzyMan
e793e82729 feat(permissions): add workspace directory management tab
- Add Workspace tab to PermissionsDialog with full directory management UI
  - Directory list view: initial (non-removable) dirs shown inline,
    runtime-added dirs selectable; "Add directory…" always first
  - Add directory input view: filesystem autocomplete with ↑/↓ navigation
    and Tab-to-complete; path validation (existence, type, duplicate,
    subdirectory checks)
  - Remove directory confirmation view
  - Save directly to project settings (SettingScope.Workspace), no scope
    selection step
- Add onTab/onUp/onDown props to TextInput to intercept keys before buffer
- Add removeDirectory() and isInitialDirectory() to WorkspaceContext
- Add --add-dir CLI alias for --include-directories
- Add /add-dir slash command (alias for /directory add)
- Add permissions.additionalDirectories settings field
- Add i18n keys for all workspace directory UI strings (en/zh/de/ja/pt/ru)"
2026-03-11 10:54:59 +08:00
tanzhenxin
d7aa98a0c0 refactor(arena): move arena-bridge to context and add reactive manager tracking
- Move useArenaInProcess from AppContainer to AgentViewProvider
- Replace polling with config.onArenaManagerChange() callback
- Add success-type progress messages when agents finish tasks
- Add isSuccessStatus helper for IDLE/COMPLETED status checks
- Reset input history position when arena session starts

This improves separation of concerns and eliminates the 500ms polling
interval in favor of immediate reactive updates when the arena manager
changes.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-10 21:45:30 +08:00
tanzhenxin
9f7e3e054f feat(arena): forward chat history to spawned agents
Add stripStartupContext to remove env-info from parent history and pass
chatHistory through ArenaManager → InProcessBackend → AgentInteractive →
AgentCore. This allows arena agents to start with conversational context
from the main session.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-10 19:45:14 +08:00
Yusheng
66c625a555 fix: improve qwen mcp add option handling for arrays 2026-03-10 17:37:51 +08:00
tanzhenxin
89f8751233 feat(cli): add agent composer UI and refactor text input handling
- Extract shared BaseTextInput component with readline keyboard handling
- Add AgentComposer and AgentFooter components for agent interaction
- Add useAgentStreamingState hook for managing agent streaming state
- Refactor InputPrompt to use BaseTextInput with agent tab bar focus support
- Move calculatePromptWidths to shared layoutUtils
- Disable auto-accept indicator on agent tabs (agents handle their own)

This enables a dedicated input experience for agent tabs with proper
focus management and keyboard navigation between main input and agent tabs.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-10 16:53:10 +08:00
tanzhenxin
bf99f95602
Merge pull request #2045 from xieyonn/feat/tmp-editor-filename
Some checks failed
Qwen Code CI / Lint (push) Has been cancelled
Qwen Code CI / CodeQL (push) Has been cancelled
E2E Tests / E2E Test (Linux) - sandbox:docker (push) Has been cancelled
E2E Tests / E2E Test (Linux) - sandbox:none (push) Has been cancelled
E2E Tests / E2E Test - macOS (push) Has been cancelled
Qwen Code CI / Post Coverage Comment (push) Has been cancelled
Qwen Code CI / Test (push) Has been cancelled
Qwen Code CI / Test-1 (push) Has been cancelled
Qwen Code CI / Test-2 (push) Has been cancelled
Qwen Code CI / Test-3 (push) Has been cancelled
Qwen Code CI / Test-4 (push) Has been cancelled
Qwen Code CI / Test-5 (push) Has been cancelled
Qwen Code CI / Test-6 (push) Has been cancelled
Qwen Code CI / Test-7 (push) Has been cancelled
Qwen Code CI / Test-8 (push) Has been cancelled
feat(cli): change temporary filename prefix to qwen-edit-
2026-03-10 16:51:42 +08:00
LaZzyMan
db0e373ad7 feat test tool permissions 2026-03-10 16:30:22 +08:00
DennisYu07
98fb607ad1 merge main 2026-03-10 00:29:08 -07:00
tanzhenxin
b6dda8c08d
Merge pull request #2224 from Deng-Xian-Sheng/patch-1
improve readability of context compression description
2026-03-10 14:10:49 +08:00
tanzhenxin
9154048be2
Merge pull request #2219 from LaZzyMan/fix-mcp-extension-ui
fix: clean up MCP server display and add CONCAT merge strategy for mcp allowed/excluded lists
2026-03-10 13:55:59 +08:00
tanzhenxin
29e82822e2 fix(test): simplify AskUserQuestionDialog tests to remove flaky timing-dependent tests
Keep only essential stable tests:
- Rendering tests (6)
- Basic single-select interaction (4)
- Basic multi-select interaction (2)
- Multiple questions navigation (4)
- Focus behavior (1)

Remove timing-sensitive tests involving:
- Auto-advance after selection (setTimeout 150ms)
- Custom input state preservation across navigation
- Complex multi-select toggle state assertions

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-10 11:11:23 +08:00
tanzhenxin
3b5e9f21c2
Merge branch 'main' into release/v0.12.1 2026-03-10 10:51:50 +08:00
tanzhenxin
2643116804 fix(test): remove flaky custom input state tests from AskUserQuestionDialog
Remove 5 tests in 'custom input preserves state' describe block that were
flaky on Windows CI due to timing issues with TextInput state updates and
keyboard navigation.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-10 10:50:21 +08:00
tanzhenxin
a4136f484d
Merge pull request #2110 from QwenLM/fix/clear-message-after-change-modle
fix(cli): clear static error message when starting new query
2026-03-10 10:36:32 +08:00
tanzhenxin
e5aa9ce8e7 fix(test): increase wait times in AskUserQuestionDialog tests for Windows CI
- Increase wait times from 200ms to 250-300ms for auto-advance tests
- Windows CI can have timing issues with setTimeout precision

This fixes flaky test failures on Windows CI where the 150ms auto-advance
timeout wasn't completing before the next test action.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-10 10:29:54 +08:00
pomelo
d80199d893
Merge pull request #2212 from xuewenjie123/fix/mcp-oauth-scope-from-protected-resource
fix(mcp): use scopes from protected resource metadata (RFC 9728)
2026-03-10 10:23:12 +08:00
tanzhenxin
1376a621b8 chore(release): bump version to 0.12.1
Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-10 09:22:03 +08:00
靳灿奇
85855bbc8b
Fix translation for context compression message 2026-03-10 03:17:27 +08:00
LaZzyMan
d32dcab5db fix: remove redundant scope field from MCP server display and add CONCAT merge strategy for mcp allowed/excluded lists 2026-03-09 21:38:42 +08:00
tanzhenxin
eaef9efe90 feat(arena): add IDLE status for agent follow-up task support
- Introduce AgentStatus.IDLE for agents that finished work but can accept follow-up messages
- Add isSettledStatus() helper to check if agent is settled (IDLE or terminal)
- Update ArenaManager to transition to IDLE after agents finish initial task
- Keep agent tabs visible when session is IDLE so users can continue interacting
- Fix listener cleanup to not detach on IDLE (agents remain alive)
- Update tests to expect 'idle' status after successful completion

This enables the arena collaboration feature where agents can receive
additional tasks after completing their initial work.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-09 21:33:48 +08:00
tanzhenxin
4a681f435d Merge branch 'main' into feature/arena-agent-collaboration 2026-03-09 20:43:25 +08:00
LaZzyMan
817f24e0ea fix bugs 2026-03-09 19:11:40 +08:00
LaZzyMan
a02ed08d26 fix ui 2026-03-09 18:26:01 +08:00
xwj02155382
c074960dd7 fix: increase wait times in AskUserQuestionDialog tests for CI stability
The tests used fixed wait times (200ms) that were too close to the
auto-advance timeout (150ms). In CI environments (especially Windows
with Node 20), timing can be less predictable due to event loop
scheduling differences, causing race conditions.

Changes:
- Increased wait(200) to wait(300) for auto-advance tests
- Increased wait() to wait(100) for navigation tests in custom input state test

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-09 18:25:02 +08:00
DennisYu07
ab368e15b0 add matcher for SessionStart and SessionEnd and rafactor integration test 2026-03-09 02:34:33 -07:00
tanzhenxin
fa2f2fd5ce feat(arena): Short worktree names and UX improvements
- Use 8-char short names derived from session UUID for worktrees
- Fix cleanup to use short worktreeDirName
- Simplify model display names (remove authType prefix)
- Improve messaging when <2 models available
- Show agent worktree paths in startup output

Prevents long path issues and provides clearer model setup guidance.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-09 16:21:28 +08:00
LaZzyMan
0c21071bf6 fix ci test 2026-03-09 16:08:11 +08:00
DennisYu07
411cf08396 fix unit test 2026-03-09 01:01:35 -07:00