Skip to content

Support "program" for {"request": "attach"} instead of only "processId" #14046

Description

Feature Request

Currently

{
    "name": "(Windows) Launch",
    "type": "cppvsdbg",
    "request": "launch",
    "program": "myprogram.exe",
},

is used to launch (and attach to) a new process for debugging, while

{
    "name": "(Windows) Attach",
    "type": "cppvsdbg",
    "request": "attach",
    "processId": "${command:pickProcess}",
},

is used to attach to a process that is already running.

The former is great, the latter is incredibly inconvenient, since you often know exactly which process to attach to, but have to type it every single time. LLDB (vadimcn.vscode-lldb) supports

{
    "name": "(LLDB) Attach",
    "type": "lldb",
    "request": "attach",
    "program": "myprogram.exe",
},

which will simply look for a running program called myprogram.exe, and attach to it.


A related issue is #1904, where they asked to add "processName" to the schema. I think they were under the impression that cpptools supported (they probably found the name in something like this Stack Overflow question).

Also perhaps relevant is #1272, though that applies to GDB and specifically asks to make "program" optional.

Activity

  1. github-actions commented on Nov 15, 2025

    @github-actions

    Thank you for your feature request. While we may not be able to implement it immediately, we will monitor community reactions to see how it fits into our backlog. Additionally, if you're working with GDB/LLDB, please note that the code is open source at https://github.com/microsoft/MIEngine/wiki/Contributing-Code . Your contributions are always welcome and appreciated.

  2. added
    help wanted
    on Nov 15, 2025
  3. Subham-KRLX commented on Dec 14, 2025

    @Subham-KRLX
    Contributor

    Adrian Bibby Walther (@Som1Lse) i would like to fix this issue raising a pr regarding this.

  4. moved this from Pull Request to Done in cpptoolson Feb 18, 2026
  5. added
    fixed
    on Feb 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Feature Requestdebuggerfixedhelp wanted

    Projects

    • Status
      Done

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions