Skip to content

Need a way to avoid quoting 'debuggerPath' when using pipe transport #1318

@weinand

Description

@weinand

From @tanaka-takayoshi on March 13, 2017 9:7

  • VSCode Version:
    1.11.0-insider
  • OS Version:
    RHEL 7.3

Steps to Reproduce:

  1. Generate launch.json to set up remote debug configuration.
{
  "version": "0.2.0",
  "configurations": [        
    {
        "name": ".NET Core Docker Remote Attach",
        "type": "coreclr",
        "request": "attach",
        "processId": "21",
        "pipeTransport": {
            "pipeProgram": "docler",
            "pipeArgs": [ "exec", "remotedebug-1-mispn"],
            "debuggerPath": "/opt/app-root/src/clrdbg/clrdbg",
            "pipeCwd": "${workspaceRoot}"
        },
        "sourceFileMap": {
            "/opt/app-root/src": "${workspaceRoot}"
        }
    }
  ]
}
  1. Start debug ".NET Core Docker Remote Attach"

  2. Failed to execute docker command. This is because VS Code escape the debuggerPath with parameters.

"docker" exec remotedebug-1-mispn "/opt/app-root/src/clrdbg/clrdbg --interpreter=mi"

The docker command recognizes "/opt/app-root/src/clrdbg/clrdbg --interpreter=mi" as one file path, then failed. I'm not sure which version, but the previous version (maybe 1.10.x-insider or 1.9.x-insider) VS Code didn't escape with option but not escaped like below.

"docker" exec remotedebug-1-mispn /opt/app-root/src/clrdbg/clrdbg --interpreter=mi

I submitted to StackOverflow as a question. But, I found this issue occurred with not only "oc (OpenShit CLI)" command but also "docker" command. So I decided to submit this issue as a bug.
http://stackoverflow.com/questions/42731558/how-not-to-escape-debuggerpath-of-pipetransport-in-launch-json

This issue prevents me from executing remote debug from VS Code to docker.

Copied from original issue: microsoft/vscode#22514

Metadata

Metadata

Assignees

Labels

DebuggerfixedFixed and available in the stable version of C# Extension.

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions