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.

Karma doesn't start server in browsers

See original GitHub issue

I’m having a problem where karma never actually starts the server. It seems to start the browsers, but never the server. I’ve tested in Chrome, and after it’s launched the http://localhost:9876/ never loads. Running on windows 8, and node 0.10.33

The weird part is, I have the same exact configuration for grunt-karma, and it works no problem.

I get the error below:

INFO [karma]: Karma v0.12.28 server started at http://localhost:9876/
INFO [launcher]: Starting browser PhantomJS
INFO [launcher]: Starting browser Chrome
WARN [launcher]: PhantomJS have not captured in 60000 ms, killing.
WARN [launcher]: Chrome have not captured in 60000 ms, killing.
WARN [launcher]: PhantomJS was not killed in 2000 ms, sending SIGKILL
WARN [launcher]: Chrome was not killed in 2000 ms, sending SIGKILL.

Here is my package.json for karma

"karma": "^0.12.3",
"karma-chrome-launcher": "^0.1.3",
"karma-coverage": "^0.2.1",
"karma-jasmine": "^0.1.5",
"karma-ng-html2js-preprocessor": "^0.1.0",
"karma-phantomjs-launcher": "^0.1.4",

Issue Analytics

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

github_iconTop GitHub Comments

32reactions
nicopeeterscommented, Apr 6, 2016

I’m having the same issue on debian:

06 04 2016 14:30:43.056:WARN [launcher]: PhantomJS have not captured in 60000 ms, killing.
06 04 2016 14:30:45.062:WARN [launcher]: PhantomJS was not killed in 2000 ms, sending SIGKILL.
06 04 2016 14:30:47.068:WARN [launcher]: PhantomJS was not killed by SIGKILL in 2000 ms, continuing.

Did anyone solve this?

2reactions
ivanyurchenko1commented, May 27, 2020

I encountered the same issue. What helped me:

  1. Remove node_modules folder completely.
  2. Run npm install.

Apparently karma files got corrupted and couldn’t be fixed automatically.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Troubleshooting - Karma test runner
The --no-single-run option causes the server to print a URL and wait. Open the URL in a browser and use the browsers devtools...
Read more >
Karma not running unit tests due to "No captured browser ...
This error can mean that the browser can't find the server. Check if you can reach the server at the URL it mentions....
Read more >
Karma launch configuration does not allow passing command ...
I when I start karma runner and I want it to auto launch dartium browser in assert/checked mode and have it auto capture...
Read more >
How to debug karma-based unit tests in Chrome or Firefox
The other thing that seems odd is that it doesn't seem as if the unit tests are being executed. The browser starts up,...
Read more >
Faster Karma test runs that work in VSTS with Chrome ...
Because Karma doesn't care what test framework, assertion library, ... on the build server, and the new-ish Chrome headless browser sounded ...
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