Skip to content
This repository has been archived by the owner on Sep 11, 2018. It is now read-only.

speed up test build time breaks Codeship CI #572

Closed
GerritWanderer opened this issue Feb 17, 2016 · 12 comments
Closed

speed up test build time breaks Codeship CI #572

GerritWanderer opened this issue Feb 17, 2016 · 12 comments

Comments

@GerritWanderer
Copy link

Hey Devs,

after we merged the latest improvements regarding the test build time (commit 998cce6), we recognized that our builds on Codeship CI are failing due to an SyntaxError: Expected token ']' error.
On our local machines (MacOSX and Ubuntu with PhantomJS 2.1.1) it works fine to run the tests though.

I can also easily reproduce this error, when I fork the original react-redux-starter-kit master and connect it with codeship. It breaks with this error and I assume it belongs to the karma-webpack-with-fast-source-maps package.

Screenshot is attached:
bildschirmfoto 2016-02-17 um 16 41 42

Any hints?

@dvdzkwsk
Copy link
Owner

Having never used Codeship, is there anything different about its environment than yours? I just signed up for Codeship and will try to reproduce, but it seems incredibly strange that this only occurs in that environment. On a related note, I also merged those same fixes into our applications at work (CircleCI) and we haven't run into any issues.

Will try to repro on Codeship and see how it goes.

@GerritWanderer
Copy link
Author

No, never had the feeling that the codeship environment is different from ours. Thanks for investigating this issue.

@dvdzkwsk
Copy link
Owner

Well, reproducing at least: https://codeship.com/projects/134857/builds/12222450

@Pintouch
Copy link

I have the same error on CodeShip.

I think that is because the phantomjs version on codeship servers is "1.9.7", and on local I use "2.1.1".
I'm trying to make a script to update the phantomjs version on the CodeShip server.
I let you know if I find something.

@Pintouch
Copy link

Installing phantomjs 2.1.1 before running test solved the issue above but now, the build silently fails without any error...
group

I'll continue investigating, if you have some ideas, let me know.

@adrianObel
Copy link

I'm having the exact same problem when running tests on Codeship. Mine although is running on Phantom 2.1.1.

PhantomJS 2.1.1 (Linux 0.0.0) ERROR
SyntaxError: Expected token ']'

from test-bundler.js

@jeremyw
Copy link

jeremyw commented Apr 8, 2016

Could this be related to eslint/eslint#2228?

@gerbal
Copy link

gerbal commented Apr 11, 2016

Same Issue running tests inside a local Docker image

@gerbal
Copy link

gerbal commented Apr 11, 2016

I don't know what the cause of this was, but I resolved it by changing this line

from:

const __karmaWebpackManifest__ = [] // eslint-disable-line

to:

const __karmaWebpackManifest__ = new Array() // eslint-disable-line

Alternatively a semicolon at the end of the line seems to resolve the problem.

@dvdzkwsk
Copy link
Owner

@gerbal that's so strange to me. Especially that it would only cause issues in very particular environments.

@dvdzkwsk
Copy link
Owner

All hail @gerbal .

Fixed with #709.

@GerritWanderer
Copy link
Author

Thank you @gerbal for your research.

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

No branches or pull requests

6 participants