2

I am trying to debug my Angular application using VScode. If I start my computer up, run the application and launch my debugger straight away it works fine.

The problem begins after I have been working a while, opening programs and opening different tabs in chrome etc.

If I try to repeat the process of launching to debugger it throws an error.

enter image description here

Cannot connect to runtime process, timeout after 10000 ms - (reason: Can't find a valid target that matches: about:blank. Available pages: ["http://localhost:9877/?id%3D580327"]).

No matter if I restart VScode, close all my browsers or whatever, nothing works. I basically have to restart my computer to get it working again (not cool).

This is my 'launch.json' which I am purposefully using port 4202

    {   // For this config to work, the app must already be running on 4202
        // This simply opens the app chome with the debugger on this port
        "type": "chrome",
        "request": "launch",
        "name": "Launch Chrome against localhost",
        "url": "http://localhost:4202/",
        "webRoot": "${workspaceFolder}"
    }
2
  • Does this happen with other browsers as well? with FF/Edge or Safari ? Commented Jun 13, 2020 at 8:08
  • I just tested on Firefox and Edge and I did not get the error. It worked. But still the problem persists with chrome. Thanks for the heads up. Any Ideas why this error would be thrown when using chrome? Commented Jun 13, 2020 at 18:48

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.