ui-select icon indicating copy to clipboard operation
ui-select copied to clipboard

Attempting gulp build fails with TypeError

Open andrewmurray opened this issue 9 years ago • 8 comments

Here is the output from my shell after doing a clone locally and npm install && bower install:

$ gulp D:\Git\ui-select\node_modules\karma\node_modules\socket.io\lib\store.js:35 Store.prototype.proto = EventEmitter.prototype; ^

TypeError: Cannot read property 'prototype' of undefined at Object. (D:\Git\ui-select\node_modules\karma\node_modules\socket.io\lib\store.js:35:41) at Module._compile (module.js:573:32) at Object.Module._extensions..js (module.js:582:10) at Module.load (module.js:490:32) at tryModuleLoad (module.js:449:12) at Function.Module._load (module.js:441:3) at Module.require (module.js:500:17) at require (internal/module.js:20:19) at Object. (D:\Git\ui-select\node_modules\karma\node_modules\socket.io\lib\manager.js:16:13) at Module._compile (module.js:573:32)`

I'm running windows 10, node v7.1.0

Is a specific version of node required?

andrewmurray avatar Dec 02 '16 16:12 andrewmurray

am also getting the same error, I'm too running windows 10, node v7.1.0.

rahmanfasalu avatar Dec 02 '16 18:12 rahmanfasalu

Root Cause : You must have installed latest node.js and where as your code is still using old node.js

Fix: 1.Go to your local cloned repo, delete the folder "node_modules" 2.Go to control panel -> add/remove programs -> locate the node.js and un install 3.go to https://nodejs.org/en/download/ and download the lower version of node.js and try

*** In my case I had installed v6.9.4 on my windows 10 and faced the above issue. When I re-installed v5.10.1 resolved the issue***

Umakanth-Nelige avatar Jan 13 '17 23:01 Umakanth-Nelige

Hi @andrewmurray is this issue resolved with above comments?

Jefiozie avatar Mar 07 '17 08:03 Jefiozie

Hi, yes it seems to be resolved on my current versions of node & npm, 6.10.0 and 4.1.1 respectively. I have gone back to the LTS versions for other non-associated reasons. I have also tried at home on the node 7.2 version and it seemed to work fine. Unfortunately, lots of tests fail following a gulp but I'll raise another ticket for those if my investigations get me nowhere.

andrewmurray avatar Mar 27 '17 15:03 andrewmurray

Great so we can close down this issue?

Jefiozie avatar Mar 27 '17 18:03 Jefiozie

Yeah, please do. Thanks.

andrewmurray avatar Mar 27 '17 19:03 andrewmurray

It looks like karma package is throwing that error.

TypeError: Cannot read property 'prototype' of undefined at Object. (D:\Git\ui-select\node_modules\ karma \node_modules\socket.io\lib\store.js:35:41)

Rather than downgrading node version you can upgrade karma version to solve this issue

    "jasmine-core": "latest",
    "karma": "latest",
    "karma-chrome-launcher": "latest",
    "karma-jasmine": "latest"

RohithKP avatar May 29 '17 15:05 RohithKP

@RohithKP its working nicely

riyajk avatar Jul 30 '18 11:07 riyajk