gruntjs / grunt-contrib-jasmine

Run jasmine specs headlessly through Headless Chrome

Home Page:http://gruntjs.com/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

2.0.3 does not work on CircleCI

alranel opened this issue · comments

Upgrading to 2.0.3 from 2.0.1 broke our CI setup.

See this build log:
https://circleci.com/gh/italia/spid-smart-button/91

Basically, npm test hangs on Testing specs with Jasmine/latest via HeadlessChrome/72.0.3582.0 and then after a while times out with the following output:

(node:150) UnhandledPromiseRejectionWarning: Error: Protocol error (Page.enable): Target closed.
  at Promise (/tmp/spid-smart-button/node_modules/puppeteer/lib/Connection.js:186:56)
  at new Promise (<anonymous>:null:null)
  at CDPSession.send (/tmp/spid-smart-button/node_modules/puppeteer/lib/Connection.js:185:12)
  at Function.create (/tmp/spid-smart-button/node_modules/puppeteer/lib/Page.js:44:18)
  at _pagePromise._sessionFactory.then.client (/tmp/spid-smart-button/node_modules/puppeteer/lib/Target.js:43:32)
  at <anonymous>:null:null
  at process._tickCallback (internal/process/next_tick.js:189:7)

  -- ASYNC --
  at Target.<anonymous> (/tmp/spid-smart-button/node_modules/puppeteer/lib/helper.js:144:27)
  at Browser._createPageInContext (/tmp/spid-smart-button/node_modules/puppeteer/lib/Browser.js:177:31)
  at <anonymous>:null:null
  at process._tickCallback (internal/process/next_tick.js:189:7)

  -- ASYNC --
  at Browser.<anonymous> (/tmp/spid-smart-button/node_modules/puppeteer/lib/helper.js:144:27)
  at launchPuppeteer (/tmp/spid-smart-button/node_modules/grunt-contrib-jasmine/tasks/jasmine.js:151:32)
  at <anonymous>:null:null
  at process._tickCallback (internal/process/next_tick.js:189:7)

(node:150) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:150) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

I'm not sure what else could I provide for helping to troubleshoot the issue. Meanwhile we downgraded to 2.0.1.

Experiencing the same thing on Travis too.

I am also having this issue, though for me it's also hanging when I go to 2.0.1 or 2.0.2 as well. Not sure if this is an issue with this plugin or if there's a problem with headless chrome itself.

I had the same issue, even on the latest v3.0.0. This workaround fixed it for me: #339