VS Code agent cannot capture terminal output in WSL workspace

未关闭
#13,335 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 8 天内回复

还没有人认领这个 Issue。

评估

难度
4/5
预计耗时
3-5 天
新手友好度
52/100
Issue 类型
缺陷
描述清晰度
基本清楚
活跃度
活跃
技术栈
typescript, vscode

调研方向

Start by tracing the VS Code extension’s remote terminal execution path and compare it with local workspace handling, including the ide.runCommand path mentioned in #9679. Reproduce the issue with pwd in a WSL workspace, then verify that stdout, stderr, and exit status are returned without inserting commands into unfinished user input.

由索引模型根据 Issue 内容生成。

描述

Environment
Windows with WSL2 (Ubuntu)
VS Code opened from a WSL directory using code .
Continue VS Code extension installed under both Local and WSL: Ubuntu
Continue version: 2.0.0
VS Code version: 1.140.0

Problem
When Continue’s agent runs a terminal command in the WSL workspace, the command text appears in the VS Code Ubuntu terminal. However, Continue receives neither the command’s output nor its exit status. The tool instead returns: "Command executed in remote terminal. Output capture is not yet available for remote environments"

This happens even with a harmless command such as pwd. The same command works when I run it myself in the Ubuntu terminal. In a local Windows workspace, Continue runs commands with output visible to the agent, so the failure appears specific to the remote-workspace execution path.

Steps to reproduce
On Windows, open a WSL2 Ubuntu workspace in VS Code by running code . from an Ubuntu directory.
Ask Continue in Agent mode to run pwd.
Observe that the command text is sent to an interactive Ubuntu terminal.
Observe that Continue receives the “Output capture is not yet available” message instead of the path or an exit status.

Expected behavior
Continue should execute the command in the WSL environment and return stdout, stderr, and exit status to the agent, as it does for local workspaces. It should not insert agent commands into a terminal containing unfinished user input.

Actual behavior and impact
The agent cannot determine whether a command ran or succeeded. This prevents it from reliably running tests, diagnosing build failures, or safely performing actions that require verification.

Related issues and PRs
#9731 — Terminal output not captured when Windows VS Code connects to WSL: Appears to describe this same VS Code extension behavior. It is closed, but the behavior remains reproducible.
#9679 — Use ide.runCommand when Windows host connects to WSL: Fixed a powershell.exe ENOENT error by routing commands through the VS Code terminal. That allows command text to reach WSL but does not provide output capture.
#9810 — Detect WSL and spawn appropriate shell: Changes the standalone CLI implementation, not the VS Code extension’s remote terminal output path. Its closure of #9731 does not appear to resolve this reproduction.

主要语言
TypeScript
星标
36.5k
派生
5.6k
PR 合并指标
30 天内没有已合并 PR

环境准备

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

continuedev/continue 的其他 Issue

查看 continuedev/continue 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。