question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Debugging in a Docker container (UI Mode): Unable to find Chrome version stable

See original GitHub issue

Describe the bug

Chrome debugger refuses to launch inside of mcr.microsoft.com/dotnet/core/sdk:3.1 container (ui mode) after latest update. Produces error:

image

Setting runtimeExecutable to dev as idicated produces the same error, except saying it couldn’t find version dev

This doesn’t seem to be a totally new issue, but it only started happening after the latest update (see https://github.com/microsoft/vscode-js-debug/issues/212). I’d be okay with a workaround for now, but since this is running in a container, I’m not sure what I should set the runtimeExecutable setting to…

To Reproduce Steps to reproduce the behavior:

  1. use VSCode to build a .net core 3.1 dev container (specific container probably isn’t relavent)
  2. create a launch config:
{
    "version": "0.2.0",
    "configurations": [
        {
            "type": "chrome",
            "request": "launch",
            "name": "Launch Chrome",
            "url": "http://localhost:5000/Leaderboards/Recents",
            "webRoot": "${workspaceFolder}/wwwroot",
			"runtimeArgs": [
				"--auto-open-devtools-for-tabs"
			],
            "sourceMapPathOverrides": {
                "webpack:///*": "${workspaceFolder}/../ClientApp/*"
            }
        }
   ]
}
  1. try to launch the config

Log File vscode-debugadapter-0.json.gz

VS Code Version: Version: 1.47.0 (user setup) Commit: d5e9aa0227e057a60c82568bf31c04730dc15dcd Date: 2020-07-09T08:02:06.629Z Electron: 7.3.2 Chrome: 78.0.3904.130 Node.js: 12.8.1 V8: 7.8.279.23-electron.0 OS: Windows_NT x64 10.0.18362

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

3reactions
thomasrea0113commented, Jul 11, 2020

The fix for this is to set your launch type to pwa-chrome instead of chrome. With just chrome, the config gets resolved using the old extension which is missing some bits. Let me know if that works for you.

This’ll be fixed when the redirection is removed, for now I’ll also add an extra default check when the config gets to the new debugger.

Awesome, this worked. You guys are the reason I love VS Code! keep up the good work.

3reactions
connor4312commented, Jul 11, 2020

The fix for this is to set your launch type to pwa-chrome instead of chrome. With just chrome, the config gets resolved using the old extension which is missing some bits. Let me know if that works for you.

This’ll be fixed when the redirection is removed, for now I’ll also add an extra default check when the config gets to the new debugger.

Read more comments on GitHub >

github_iconTop Results From Across the Web

headless chrome on docker M1 error - unable to discover ...
Found an answer! The key is: match container version to host version. it could accomplished by just do not specifying platform version.
Read more >
How to Fix and Debug Docker Containers Like a Superhero
Container errors are tricky to diagnose, but some investigative magic works wonders. Read along to learn how to debug Docker containers.
Read more >
Debug Browser Apps using Visual Studio Code
Visual Studio Code includes a built-in debugger for Edge and Chrome. There are a couple ways to get started with it. Use the...
Read more >
Troubleshooting - DDEV Docs
Use ddev debug dockercheck and ddev debug test to help sort out Docker problems. ... See troubleshooting for more detailed problem-solving.
Read more >
Configuration - DAP Mode
Latest version of LSP Java will automatically discover if dap-mode is present and it will download and install the required server side components....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found