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

Chromium crashing with karma supplied --user-data-dir #188

Open
Lalem001 opened this issue Oct 11, 2018 · 2 comments
Open

Chromium crashing with karma supplied --user-data-dir #188

Lalem001 opened this issue Oct 11, 2018 · 2 comments

Comments

@Lalem001
Copy link

Expected behaviour

Chromium should run forever, until karma exits.

Actual behaviour

Chromium is crashing approximately 30 seconds after starting.

Chromium crash log shown in Karma's log:

Received signal 11 SEGV_MAPERR 000000000000
 [0x0001127796fc]
 [0x000112779611]
 [0x7fff7a65cf5a]
 [0x7fb21105e238]
 [0x000113d94e45]
 [0x000113d95206]
 [0x000113d99791]
 [0x0001126c5d82]
 [0x0001127410be]
 [0x000112782ff4]
 [0x0001127408f4]
 [0x0001127387af]
 [0x000112738514]
 [0x0001127834c7]
 [0x7fff7a666661]
 [0x7fff7a66650d]
 [0x7fff7a665bf9]
[end of stack trace]

Environment Details

  • Karma version (output of karma --version): 3.0.0
  • Relevant part of your karma.config.js file
const puppeteer = require('puppeteer');
process.env.CHROME_BIN = puppeteer.executablePath();
module.exports = function(config) {
  config.set({
    frameworks: ['jasmine'],
    files: ['app/**/*.spec.js'],
    reporters: ['progress'],
    port: 9876,
    colors: false,
    logLevel: config.LOG_INFO,
    autoWatch: true,
    browsers: ['ChromeHeadless'],
    singleRun: false,
    concurrency: Infinity
  })
}
  • Other potentially relevant version info
    • Mac OS 10.13.6
    • Node: 8.12.0
    • npm: 6.4.1
    • Puppeteer: 1.9.0
    • Chromium: 594312

Steps to reproduce the behaviour

  1. $(npm bin)/karma start
  2. Observe crash at around the 30 second mark
  3. [Optional] Manually run chromium with the same args that karma uses, but with --user-data-dir either removed or pointing to an empty directory. No crash, tests pass fine.

While 3 is optional, please note the implication of 3.

@sinedied
Copy link

Tried with:

    customLaunchers: {
      ChromeHeadless_WithoutCrashing: {
        base: 'ChromeHeadless',
        chromeDataDir: path.resolve(__dirname, '.chrome-karma')
      }
    }

To replicate point 3) with an empty dir, still crashing for me :/ any workaround?

@sinedied
Copy link

FWIW I had this issue using a Chrome binary provided by the puppeteer package, but after upgrading to the latest version it's gone completely, so it might not be directly related to karma-chrome-launcher after all.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants