Skip to content

Tasks with input variables that run VSCode commands fail #251417

Closed as not planned
@nortakales

Description

@nortakales

Does this issue occur when all extensions are disabled?: Yes

  • VS Code Version: 1.100.3
  • OS Version: Windows 11 Build 22631

Steps to Reproduce:

  1. Set up tasks exactly like the "Terminate All Tasks" example mentioned here: https://code.visualstudio.com/docs/reference/variables-reference#_input-variables
  2. Run the "Terminate All Tasks" task

Task setup looks like:

{
  "version": "2.0.0",
  "tasks": [
    {
      "label": "Terminate All Tasks",
      "command": "echo ${input:terminate}",
      "type": "shell",
      "problemMatcher": []
    }
  ],
  "inputs": [
    {
      "id": "terminate",
      "type": "command",
      "command": "workbench.action.tasks.terminate",
      "args": "terminateAll"
    }
  ]
}

Expected:

All tasks are terminated

Actual:

 *  Executing task in folder <redacted>: echo ${input:terminate} 

zsh:1: unrecognized modifier

 *  The terminal process "/usr/bin/zsh '-c', 'echo ${input:terminate}'" failed to launch (exit code: 1).

Note

I first noticed this back in April, mentioned here: #246854. That was resolved, so I guess it was unrelated. This one may be related: #246074

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions