Commit graph

4838 commits

Author SHA1 Message Date
tanzhenxin
f59328aada Merge branch 'main' into pr-2021 2026-03-02 19:07:11 +08:00
tanzhenxin
5deba24d05
Merge pull request #1999 from QwenLM/split/tool-scheduler-refactor
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:none (push) Waiting to run
E2E Tests / E2E Test (Linux) - sandbox:docker (push) Waiting to run
E2E Tests / E2E Test - macOS (push) Waiting to run
refactor(core): extract single tool-call execution path
2026-03-02 18:56:06 +08:00
yiliang114
15e8c0e26c Merge branch 'main' into fix/docker-ide-host-check 2026-03-02 18:10:14 +08:00
易良
c353fbbfa3
feat(cli): add Ctrl+Y shortcut to retry failed requests (#2011)
* feat: add Ctrl+Y shortcut to retry failed requests

- Add Ctrl+Y keyboard shortcut for retrying the last failed request
- Add isNetworkError() to detect transient network failures (ECONNREFUSED, ETIMEDOUT, etc.)
- Add DashScope 1305 error code to rate limit detection
- Add error hint \"Press Ctrl+Y to retry\" in error messages
- Support user-defined error codes for retry via config
- Add retryLastPrompt() hook in useGeminiStream
- Update keyboard shortcuts documentation

* feat: improve Ctrl+Y retry feature with tests, docs, and rate limit config

- Add comprehensive tests for Ctrl+Y retry shortcut in InputPrompt
- Add unit tests for retryLastPrompt in useGeminiStream hook
- Add detailed JSDoc comments for retryLastPrompt function and Ctrl+Y shortcut
- Extend isRateLimitError to support custom error codes via retryErrorCodes config
- Fix rate limit retry log variable reference (RATE_LIMIT_RETRY_OPTIONS → maxRateLimitRetries)
- Add Eclipse IDE files to .gitignore

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>

* refactor(ui): consolidate retry countdown as inline hint in error messages

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>

* feat(cli): enhance error handling with improved retry mechanism

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>

- Modify ErrorMessage component to remove dim color from hint text

- Update useGeminiStream hook to improve retry countdown behavior with option to preserve or clear hints

- Adjust tests to match new error handling implementation

* feat: add Ctrl+Y shortcut to retry the last failed request

When a request errors out, the error message shows an inline hint
"(Press Ctrl+Y to retry.)" in secondary color. Pressing Ctrl+Y
re-submits the same prompt, commits the error text to history
(without the hint), and clears the hint from the UI.

- Add retryLastPrompt action wired to Ctrl+Y via keyBindings and InputPrompt
- Track last submitted prompt and error state in useGeminiStream refs
- Show retry hint inline with error text in ErrorMessage component,
  wrapping naturally on narrow terminals while preserving hint color
- Expose retryLastPrompt through UIActionsContext
- Add keyboard shortcut entry in KeyboardShortcuts display
- Add i18n strings for hint and no-retry-available message
- Document Ctrl+Y in keyboard-shortcuts.md

* docs(configuration): Update model provider configuration document

* chore: remove YOLO mode code from core

* fix: prevent Ctrl+Y hint from overriding auto-retry countdown

When an auto-retry countdown is active (retryCountdownTimerRef is set),
handleErrorEvent should not overwrite it with the Ctrl+Y hint. The auto-retry
hint ("retrying in Xs...") and manual retry hint ("Press Ctrl+Y to retry.")
are mutually exclusive:

- Auto-retry errors (e.g., rate limits): show countdown hint
- Other errors: show Ctrl+Y hint

Also removed retryErrorCodes from ContentGeneratorConfig as it's not part
of the minimal Ctrl+Y feature scope.

* simplify: remove complex options from clearRetryCountdown

Revert clearRetryCountdown to simplest form without options parameter.
The function now just clears the timer and pending item without any
automatic history commit logic.

* fix: restore pendingRetryCountdownItem as separate state from pendingRetryErrorItem

Auto-retry countdown and manual retry hint are now independent:
- pendingRetryErrorItem: displays error message with optional hint
- pendingRetryCountdownItem: displays separate countdown line for auto-retry

This ensures both can be shown simultaneously without overriding each other.

* fix: restore RetryCountdownMessage rendering in HistoryItemDisplay

The retry_countdown type should be rendered as a separate message,
not inline in ErrorMessage. This allows auto-retry countdown and
manual retry hint to coexist properly.

* fix(cli): properly commit retry error item to history before clearing

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>

* fix(cli): remove trailing period from retry hint translations

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>

Remove unnecessary period from 'Press Ctrl+Y to retry' translation strings in both en.js and zh.js locales. Also update the corresponding usage in useGeminiStream hook.

* chore(sdk-java): add Eclipse project configuration files

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>

Add .project configuration files for client and qwencode modules to support Eclipse IDE development environment.

* feat(cli): add retry countdown hint to error message

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>

* Revert "chore(sdk-java): add Eclipse project configuration files"

This reverts commit da83b5e571.

---------

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-02 17:59:18 +08:00
tanzhenxin
6fdd715458
Merge pull request #2017 from QwenLM/mingholy/fix/acp-config-options
Fix ACP protocol compatibility issues with Zed editor
2026-03-02 17:51:38 +08:00
tanzhenxin
6a617f5248
Merge pull request #1982 from QwenLM/fix/modality-defaults-pdf-error
fix: add modality defaults to prevent API errors when reading PDFs and other media
2026-03-02 17:42:17 +08:00
tanzhenxin
1e0f6f4fc8
Merge pull request #1994 from QwenLM/fix-docs-by-yijing
docs: update installation instructions
2026-03-02 17:41:56 +08:00
tanzhenxin
f6376d2e0b
Merge pull request #2041 from QwenLM/fix/reduce-streaming-log-output
fix(logging): reduce excessive streaming output in session history logs
2026-03-02 17:41:25 +08:00
tanzhenxin
076efa6ee8
Merge pull request #1995 from QwenLM/fix/idealtalk-api-inner
fix(core/rateLimit): add support for rate limit error code 1305 and custom retry error codes
2026-03-02 17:22:46 +08:00
mingholy.lmh
43d728e8cc fix: revert removed schema fileds 2026-03-02 17:22:20 +08:00
mingholy.lmh
9c426a7961 fix(acp): fix session/list and remove fork capability
- Make cwd optional in listSessionsRequestSchema (defaults to process.cwd())
- Remove fork from sessionCapabilities (not supported)

Fixes -32602 error when Zed calls session/list without cwd param.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-02 17:22:19 +08:00
mingholy.lmh
a08bc1bbf3 fix(acp): add sessionCapabilities to initialize response
Add sessionCapabilities with fork, list, and resume capabilities
to initialize response to match Claude Agent's format.

This enables Zed ACP client to discover session management features.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-02 17:22:19 +08:00
mingholy.lmh
c7c2ae217b fix(acp): align session/list response format with Claude Agent
Update session/list response to match Claude Agent's format:
- Change 'items' to 'sessions' array
- Add 'title' field (mapped from prompt)
- Add 'updatedAt' field (ISO format from mtime)
- Remove 'hasMore' and 'nextCursor' fields

This fixes session list display in Zed ACP client.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-02 17:22:18 +08:00
mingholy.lmh
e5bdd5b635 fix(acp): add modes and configOptions to session/new response
Add missing 'modes' and 'configOptions' fields to NewSessionResponse
to enable mode switching (plan/yolo/auto-edit) in Zed ACP client.

- Update schema.ts: add configOptionSchema and extend newSessionResponseSchema
- Update acpAgent.ts: add buildModesData() and buildConfigOptions() helpers

Fixes ACP mode control issue where Zed couldn't switch approval modes.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-02 17:22:18 +08:00
tanzhenxin
74f5b76754
Merge pull request #1993 from zhangxy-zju/fix/subagent-output-language
fix(subagent): append output-language.md to subagent system prompt and prioritize project-level settings
2026-03-02 17:08:52 +08:00
tanzhenxin
f2a6d3b3f8
Merge pull request #2018 from QwenLM/feature/support-agents-md-default
feat: support AGENTS.md as default context file
2026-03-02 17:05:38 +08:00
DennisYu07
2629902ebf use concat result instead of override 2026-03-02 00:48:34 -08:00
tanzhenxin
4c70374640 Merge branch 'fix/reduce-streaming-log-output' into feature/arena-agent-collaboration 2026-03-02 15:44:45 +08:00
tanzhenxin
46bcd8e1b8 fix(logging): remove excessive streaming output from session history logs
Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-02 15:34:40 +08:00
mingholy.lmh
d38077423d refactor: use pre-defined utils 2026-03-02 12:38:26 +08:00
mingholy.lmh
d0c1547c60 test: add test fixtures 2026-03-02 11:54:54 +08:00
DennisYu07
3b229c08dd fix test 2026-03-01 19:51:59 -08:00
DennisYu07
5da1f07796 rename UserPromptSubmit 2026-03-01 19:24:08 -08:00
DennisYu07
2fe5bee96f add more test 2026-03-01 19:11:46 -08:00
LaZzyMan
79e6afb85d fix: prioritize QWEN.md for backward compatibility
Keep QWEN.md as the first element in the default context filenames array
to maintain backward compatibility with /init command and save_memory tool.
Both QWEN.md and AGENTS.md will still be searched and loaded, but QWEN.md
takes precedence for file creation operations.
2026-03-02 10:31:17 +08:00
DennisYu07
4b18cfe3f3 Revert "implementation 10 hooks"
This reverts commit c9126e043f.
2026-03-01 17:58:11 -08:00
DennisYu07
c9126e043f implementation 10 hooks 2026-03-01 17:50:48 -08:00
mingholy.lmh
ae8c0d3d4e refactor(settings): sequential settings migration 2026-03-02 00:12:51 +08:00
tanzhenxin
e04479f6a1 feat(auth): improve Qwen OAuth quota error messaging
Update error handling to display user-friendly quota exceeded messages with links to Alibaba Cloud Coding Plan upgrade options.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-01 16:31:49 +08:00
tanzhenxin
d3cdad5100 feat(cli): improve auth dialog UX with clearer three-option layout
- Replace nested API-KEY submenu with flat three-option layout
- Add descriptive labels for each authentication method:
  - Qwen OAuth: Free, up to 1,000 requests/day
  - Alibaba Cloud Coding Plan: Paid, multiple model providers
  - API Key: Bring your own API key
- Simplify region selection for Coding Plan (China vs Global)
- Use DescriptiveRadioButtonSelect for better visual hierarchy
- Add itemGap prop to BaseSelectionList for spacing
- Update i18n strings in en.js, zh.js, and ru.js
- Simplify custom API key configuration info view
- Clean up unused region-specific strings

Closes #2016

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-01 15:22:35 +08:00
tanzhenxin
1f46ed28d9
Merge pull request #2026 from QwenLM/bump-version-0.11.1
Some checks are pending
Qwen Code CI / CodeQL (push) Waiting to run
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
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
chore: bump version to 0.11.1
2026-03-01 11:32:23 +08:00
tanzhenxin
8d3ab4894a chore: bump version to 0.11.1
Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-01 10:51:30 +08:00
Drew Duncan
de20bb12bd fix(core): reject PDF files to prevent session corruption (fixes #2020) 2026-02-28 10:23:36 -08:00
tanzhenxin
74b342623c Merge branch 'main' into feature/arena-agent-collaboration 2026-02-28 22:01:10 +08:00
tanzhenxin
a0f266b202 fix(core): Update PDF error hint to guide users to install pdf skill
Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>

Replace generic skill suggestion with specific guidance to install

the document-skills extension for PDF processing.
2026-02-28 20:15:08 +08:00
tanzhenxin
44bc322a19 fix(core): Reduce file size limit to 10MB and fix PDF encoding size check
- Reduce general file size limit from 20MB to 10MB (using 9.9MB threshold)
- Remove per-type size limits (5MB images, 10MB PDFs)
- Add base64 encoding size check for PDFs to prevent data URI limit errors
- Update all tests to reflect new 10MB limit

This fixes issue #1880 where large PDFs could exceed API data URI limits
after base64 encoding, causing errors. The 9.9MB threshold provides
margin for encoding overhead.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-02-28 19:51:43 +08:00
tanzhenxin
8727c56a30 test(cli): fix ModelDialog test by removing rigid help text assertion
- Removed exact match assertion for help text that changed in UI
- Test now only verifies the dialog title renders correctly

The help text changed from 'Enter to select · Esc to close' to
'Enter to select, ↑↓ to navigate, Esc to close', causing the test
to fail unnecessarily.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-02-28 19:36:53 +08:00
tanzhenxin
14df5a5702
Merge pull request #2019 from QwenLM/feat/increase-insight-exposure
Some checks are pending
Qwen Code CI / Test (push) Blocked by required conditions
Qwen Code CI / Lint (push) Waiting to run
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
feat(cli): Increase /insight feature exposure via weighted tips
2026-02-28 18:23:07 +08:00
tanzhenxin
1b7d153a4c feat(cli): Increase /insight feature exposure via weighted tips
- Add weighted tip system to make certain tips appear more frequently
- Set /insight tip to weight 3 (3x more likely than regular tips)
- Add i18n translations for the new tip across all supported languages
- Add comprehensive unit tests for weighted tip selection

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-02-28 18:08:37 +08:00
LaZzyMan
89a8ce85a0 feat: support AGENTS.md as default context file
Add AGENT_CONTEXT_FILENAME constant and include AGENTS.md in default
context file search alongside QWEN.md. This enables out-of-the-box
support for the AGENTS.md standard (https://agents.md/) without
requiring manual configuration.

Changes:
- Add AGENT_CONTEXT_FILENAME = 'AGENTS.md' constant
- Update currentGeminiMdFilename default to include both AGENTS.md and QWEN.md
- AGENTS.md takes precedence (first in array) for the de facto standard

Closes #2006
2026-02-28 18:03:31 +08:00
DennisYu07
4db2aa9865 remove redundant clienthooktrigger 2026-02-28 01:59:44 -08:00
LaZzyMan
4879ea4a36 fix: 修复 extensionsCommand 测试并简化 listAction
- 更新 extensionsCommand.test.ts 以匹配新的命令结构
- 移除对已删除子命令(update, uninstall, disable, enable, detail)的测试
- 简化 listAction 函数,始终返回 extensions_manage 对话框
- 移除未使用的 showMessageIfNoExtensions 函数
2026-02-28 17:20:18 +08:00
SunDapeng
a6cbb8e114 fix: detect and protect against truncated tool call output
When LLM streaming output exceeds token limits, JSON arguments for tool calls
can be truncated mid-stream. This causes validation errors or silent data
corruption when the truncated JSON passes validation but writes incomplete files.

The fix adds truncation detection at the streaming parser level and overrides
misleading finish_reason values from providers (e.g., DashScope/Qwen reporting
'stop' instead of 'length'). This ensures downstream code correctly identifies
truncated responses and provides clear guidance to the LLM for retrying with
split content.

Changes:
- turn.ts: Add wasOutputTruncated flag to ToolCallRequestInfo
- coreToolScheduler.ts: Reject truncated edit tool calls, append guidance for write_file
- converter.ts: Override finish_reason when streaming parser detects incomplete JSON
- streamingToolCallParser.ts: Add hasIncompleteToolCalls() method
- Tests: Add comprehensive test coverage for truncation detection scenarios

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-02-28 16:38:39 +08:00
LaZzyMan
0072c47996 fix: 修复扩展管理对话框测试和代码质量问题
- 为 ActionSelectionStep.test.tsx 和 ExtensionListStep.test.tsx 添加 KeypressProvider 包裹
- 修复 KeypressContext 导入路径
- 更新测试快照
- 重构 ExtensionsManagerDialog:提取 enable/disable 公共逻辑到 handleToggleExtensionState
- 添加错误消息状态和用户友好的错误提示
2026-02-28 16:38:10 +08:00
tanzhenxin
dcea557adb fix(core): add per-type size limits for image and PDF files
Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>

- Add 5MB limit for image files to prevent API errors

- Add 10MB limit for PDF files based on provider constraints

- Return FILE_TOO_LARGE error with clear message when limits exceeded

- Add tests for both image and PDF size limit enforcement

This prevents errors when attempting to process large binary files that exceed provider API limits.
2026-02-28 16:35:10 +08:00
LaZzyMan
4d27950a95 feat: Add interactive TUI for extension management 2026-02-28 16:06:34 +08:00
tanzhenxin
89f5f9c4c4 fix(openai): improve modality error messages and docs
- Update error messages for unsupported image/PDF inputs with clearer guidance
- Add `modalities` setting to override auto-detected input modalities
- Document `modalities` config in model-providers.md and settings.md
- Update converter tests to match new error message format

This provides users with actionable alternatives when their selected model doesn't support certain input types, and allows manual modality overrides for models not recognized by auto-detection.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-02-28 16:05:22 +08:00
DennisYu07
3c9fcf9749 add integration test for hook 2026-02-28 00:03:44 -08:00
易良
7fba0934c5 fix(core/ide): support cloud IDE environments (Codespaces, Cloud Shell, Dev Container)
- Detect cloud IDE environments via environment variables
- Use host.docker.internal for IDE server connection in containers
- Add DNS lookup with timeout and fallback to 127.0.0.1
- Improve error messages and troubleshooting guidance for cloud IDEs
- Update /ide status, /ide install, and /ide enable commands with cloud-specific info

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-02-28 07:57:45 +00:00
DennisYu07
b68650ce41 fix permission request issue 2026-02-27 23:42:47 -08:00