Skip to main content

Hello,

I'm having trouble using "Wait for a debuggable attachment" feature of Micro Focus COBOL VSCode extension with "any" parameter :

I successfully make it worked starting a "Wait for a debuggable attachment" runtime with "directory" in launch.json :

{
  "type": "cobol",
  "request": "launch",
  "name": "COBOL (native): Wait for attachment",
  "waitForAttachment": {
    "directory": "${workspaceFolder}"
  }
}
But when I change "directory" to "any", it doesn't work anymore :
The "wait" runtime starts successfully but it doesn't catch any program cobol (either with environment variable COBSW=+A or calling CBL_DEBUGBREAK in cobol program according to documentation).
Instead of, it opens "Animator".
launch.json with "any" parameter :
{
  "type": "cobol",
  "request": "launch",
  "name": "COBOL (native): Wait for attachment",
  "waitForAttachment": {
    "any": {}
  }
}

Any idea how to make it work ?


Thank you in advance for your help.

Pierre


#waitforattachment
#Extension
#VSCode

Hello,

I'm having trouble using "Wait for a debuggable attachment" feature of Micro Focus COBOL VSCode extension with "any" parameter :

I successfully make it worked starting a "Wait for a debuggable attachment" runtime with "directory" in launch.json :

{
  "type": "cobol",
  "request": "launch",
  "name": "COBOL (native): Wait for attachment",
  "waitForAttachment": {
    "directory": "${workspaceFolder}"
  }
}
But when I change "directory" to "any", it doesn't work anymore :
The "wait" runtime starts successfully but it doesn't catch any program cobol (either with environment variable COBSW=+A or calling CBL_DEBUGBREAK in cobol program according to documentation).
Instead of, it opens "Animator".
launch.json with "any" parameter :
{
  "type": "cobol",
  "request": "launch",
  "name": "COBOL (native): Wait for attachment",
  "waitForAttachment": {
    "any": {}
  }
}

Any idea how to make it work ?


Thank you in advance for your help.

Pierre


#waitforattachment
#Extension
#VSCode

 Hi Pierre Simonet 

Unfortunately the VS Code documentation is missing the details of the waitForAttachment options. It should have same information as the Visual COBOL for Eclipse documentation, namely 

  • Any - the debugger attaches to any process that is enabled for debugging. For instance, using the environment variable COBSW=+A or by a call to CBL_DEBUG_START.
    Note: This option is only available when debugging applications running on Windows.