vsdbg via docker: Invalid protocol message received
- Dominant language
- TypeScript
- Stars
- 3.1k
- Forks
- 737
- Avg merge
- 17h 56m
- Merged PRs (30d)
- 21
Description
_From @evil-shrike on February 12, 2018 14:17_
I remotely debug my .net core unit tests running in a Linux Docker container. Code is running in vstest.console/testhost which I attach from VSCode to.
VSCode launch confiruation:
```
{
"name": "Attach Tests in Docker",
"type": "coreclr",
"request": "attach",
"processId": "2494",
"pipeTransport": {
"debuggerPath": "/vsdbg/vsdbg",
"pipeProgram": "docker",
"pipeArgs": ["exec", "-i", "CONTAINER_NAME"],
"quoteArgs": false
}
}
```
Tests are run in Docker with VSTEST_HOST_DEBUG=1 env variable to make it wait for debugger to attach:
```
docker exec -it -e VSTEST_HOST_DEBUG=1 CONTAINER_NAME /usr/bin/dotnet exec /usr/share/dotnet/sdk/2.1.4/vstest.console.dll MyTests.dll
```
In general it works but sometimes (pretty often) debugging terminates with the error:
Error from pipe program 'docker': Error: Invalid protocol message received. Aborting the debug session.
The pipe program 'docker' exited unexpectedly with code 0.
Any ideas what can fail?
_Copied from original issue: Microsoft/MIEngine#690_
Contributor guide
Assessment
This issue has not been assessed yet.