Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parallel run of tests gets error EADDRINUSE #3065

Closed
ochodek opened this issue Jun 27, 2018 · 2 comments
Closed

Parallel run of tests gets error EADDRINUSE #3065

ochodek opened this issue Jun 27, 2018 · 2 comments

Comments

@ochodek
Copy link

ochodek commented Jun 27, 2018

Expected behaviour

Parallel run will execute tests as expected

Actual behaviour

Parallel run results in the following error

ERROR [karma]: { Error: listen EADDRINUSE 0.0.0.0:1111
    at Object._errnoException (util.js:1019:11)
    at _exceptionWithHostPort (util.js:1041:20)
    at Server.setupListenHandle [as _listen2] (net.js:1344:14)
    at listenInCluster (net.js:1385:12)
    at doListen (net.js:1494:7)
    at _combinedTickCallback (internal/process/next_tick.js:141:11)
    at process._tickCallback (internal/process/next_tick.js:180:9)

  code: 'EADDRINUSE',
  errno: 'EADDRINUSE',
  syscall: 'listen',
  address: '0.0.0.0',
  port: 1111 }
{ Error: Command failed: /node_modules/.bin/karma start /test/karma.conf.js

    at ChildProcess.exithandler (child_process.js:271:12)
    at emitTwo (events.js:125:13)
    at ChildProcess.emit (events.js:213:7)
    at maybeClose (internal/child_process.js:927:16)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5)

  killed: false,
  code: 1,
  signal: null,
  cmd: '/node_modules/.bin/karma start /test/karma.conf.js' }

Environment Details

  • Karma version (output of karma --version): 2.0.3+ (2.0.2 worked)
  • Bluebird Queue 0.0.8 with concurrency set as number > then 1

Steps to reproduce the behaviour

  1. Set tests to Bluebird queue
  2. Run

(Running sequentially is fine.)

I've found guy with very similar or the same problem - Nx issue #606

@lusarz
Copy link
Contributor

lusarz commented Jun 27, 2018

Thanks for report,
as I wrote in this thread:
#3011 (comment)

I'll try to fix it soon :) As a workaround please revert to v2.0.2, or try to configure port separately for every pipeline.

@ochodek
Copy link
Author

ochodek commented Jun 27, 2018

oh I didn't notice, thanks! :)

sergei-startsev added a commit to sergei-startsev/karma that referenced this issue Jun 29, 2018
sergei-startsev added a commit to sergei-startsev/karma that referenced this issue Jun 29, 2018
sergei-startsev added a commit to sergei-startsev/karma that referenced this issue Jun 29, 2018
sergei-startsev added a commit to sergei-startsev/karma that referenced this issue Jun 29, 2018
sergei-startsev added a commit to sergei-startsev/karma that referenced this issue Jul 1, 2018
sergei-startsev added a commit to sergei-startsev/karma that referenced this issue Jul 3, 2018
…ner#3065)

fix(server): pass bound port to prevent`EADDRINUSE` issue. (karma-runner#3065)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants