Angular2 beta 15 npm start error

I have an issue while i’m trying to start the quick start application for Angular2.

node -v
5.10.1

npm -v
3.8.6

I’m using EL CAPTAIN on MAC OS X.

tsconfig.json :

{
  "compilerOptions": {
    "target": "es5",
    "module": "system",
    "moduleResolution": "node",
    "sourceMap": true,
    "emitDecoratorMetadata": true,
    "experimentalDecorators": true,
    "removeComments": false,
    "noImplicitAny": false
  },
  "exclude": [
    "node_modules",
    "typings/main",
    "typings/main.d.ts"
  ]
}

Packages.json :

{
  "name": "angular2-quickstart",
  "version": "1.0.0",
  "scripts": {
    "start": "tsc && concurrently "npm run tsc:w" "npm run lite" ",
    "tsc": "tsc",
    "tsc:w": "tsc -w",
    "lite": "lite-server",
    "typings": "typings",
    "postinstall": "typings install"
  },
  "license": "ISC",
  "dependencies": {
    "angular2": "2.0.0-beta.15",
    "systemjs": "0.19.26",
    "es6-shim": "^0.35.0",
    "reflect-metadata": "0.1.2",
    "rxjs": "5.0.0-beta.2",
    "zone.js": "0.6.10"
  },
  "devDependencies": {
    "concurrently": "^2.0.0",
    "lite-server": "^2.2.0",
    "typescript": "^1.8.10",
    "typings":"^0.7.12"
  }
}

NPM install :

npm WARN lifecycle angular2-quickstart@1.0.0~postinstall: cannot run in wd %s %s (wd=%s) angular2-quickstart@1.0.0 typings install /Users/vincentDMG/Documents/Git/angular2-tour-of-heroes
- ansi-escapes@1.4.0 node_modules/ansi-escapes
- cli-width@2.1.0 node_modules/cli-width
- exit-hook@1.1.1 node_modules/exit-hook
- figures@1.5.0 node_modules/figures
- ansi-regex@2.0.0 node_modules/inquirer/node_modules/ansi-regex
- ansi-styles@2.2.1 node_modules/inquirer/node_modules/ansi-styles
- has-ansi@2.0.0 node_modules/inquirer/node_modules/has-ansi
- lodash@4.11.1 node_modules/inquirer/node_modules/lodash
- strip-ansi@3.0.1 node_modules/inquirer/node_modules/strip-ansi
- supports-color@2.0.0 node_modules/inquirer/node_modules/supports-color
- chalk@1.1.3 node_modules/inquirer/node_modules/chalk
- ansi-regex@2.0.0 node_modules/insight/node_modules/ansi-regex
- ansi-styles@2.2.1 node_modules/insight/node_modules/ansi-styles
- has-ansi@2.0.0 node_modules/insight/node_modules/has-ansi
- strip-ansi@3.0.1 node_modules/insight/node_modules/strip-ansi
- supports-color@2.0.0 node_modules/insight/node_modules/supports-color
- chalk@1.1.3 node_modules/insight/node_modules/chalk
- lodash._getnative@3.9.1 node_modules/lodash._getnative
- lodash.debounce@3.1.1 node_modules/lodash.debounce
- mute-stream@0.0.5 node_modules/mute-stream
- onetime@1.1.0 node_modules/onetime
- osx-release@1.1.0 node_modules/osx-release
- readline2@1.0.1 node_modules/readline2
- restore-cursor@1.0.1 node_modules/restore-cursor
- cli-cursor@1.0.2 node_modules/cli-cursor
- run-async@0.1.0 node_modules/run-async
- rx-lite@3.1.2 node_modules/rx-lite
- through@2.3.8 node_modules/through
- inquirer@0.12.0 node_modules/inquirer
minimist@0.0.8 node_modules/update-notifier/node_modules/minimist -> node_modules/typings-core/node_modules/minimist
mkdirp@0.5.1 node_modules/typings/node_modules/mkdirp -> node_modules/typings-core/node_modules/mkdirp
- minimist@0.0.8 node_modules/typings/node_modules/mkdirp/node_modules/minimist
- typescript@1.8.7 node_modules/typings/node_modules/typescript
- mkdirp@0.5.1 node_modules/update-notifier/node_modules/mkdirp
- configstore@2.0.0 node_modules/update-notifier/node_modules/configstore
- win-release@1.1.1 node_modules/win-release
- os-name@1.0.3 node_modules/os-name
- elegant-spinner@1.0.1 node_modules/elegant-spinner
- es6-module-loader@0.17.11 node_modules/es6-module-loader
- insight@0.7.0 node_modules/insight
- cli-width@1.1.1 node_modules/insight/node_modules/cli-width
- inquirer@0.10.1 node_modules/insight/node_modules/inquirer
- lodash@3.10.1 node_modules/insight/node_modules/lodash
- log-update@1.0.2 node_modules/log-update
angular2-quickstart@1.0.0 /Users/vincentDMG/Documents/Git/angular2-tour-of-heroes
├── concurrently@2.0.0 
├── systemjs@0.19.26 
└─┬ typings@0.7.12 
  └─┬ typings-core@0.2.16 
    ├── configstore@2.0.0 
    ├── popsicle@5.0.1 
    ├── popsicle-retry@2.0.0 
    ├── throat@2.0.2 
    └── typescript@1.8.9 

npm WARN angular2-quickstart@1.0.0 No description
npm WARN angular2-quickstart@1.0.0 No repository field.

npm start :

    > angular2-quickstart@1.0.0 start /Users/vincentDMG/Documents/Git/angular2-tour-of-heroes
> tsc && concurrently "npm run tsc:w" "npm run lite" 

typings/browser/ambient/es6-shim/es6-shim.d.ts(8,14): error TS2300: Duplicate identifier 'PropertyKey'.
typings/browser/ambient/es6-shim/es6-shim.d.ts(11,5): error TS2300: Duplicate identifier 'done'.
typings/browser/ambient/es6-shim/es6-shim.d.ts(12,5): error TS2300: Duplicate identifier 'value'.
typings/browser/ambient/es6-shim/es6-shim.d.ts(250,5): error TS2300: Duplicate identifier 'EPSILON'.
typings/browser/ambient/es6-shim/es6-shim.d.ts(285,5): error TS2300: Duplicate identifier 'MAX_SAFE_INTEGER'.
typings/browser/ambient/es6-shim/es6-shim.d.ts(292,5): error TS2300: Duplicate identifier 'MIN_SAFE_INTEGER'.
typings/browser/ambient/es6-shim/es6-shim.d.ts(348,5): error TS2300: Duplicate identifier 'flags'.
typings/browser/ambient/es6-shim/es6-shim.d.ts(500,5): error TS2300: Duplicate identifier 'prototype'.
typings/browser/ambient/es6-shim/es6-shim.d.ts(563,5): error TS2300: Duplicate identifier 'size'.
typings/browser/ambient/es6-shim/es6-shim.d.ts(572,5): error TS2300: Duplicate identifier 'prototype'.
typings/browser/ambient/es6-shim/es6-shim.d.ts(583,5): error TS2300: Duplicate identifier 'size'.
typings/browser/ambient/es6-shim/es6-shim.d.ts(592,5): error TS2300: Duplicate identifier 'prototype'.
typings/browser/ambient/es6-shim/es6-shim.d.ts(607,5): error TS2300: Duplicate identifier 'prototype'.
typings/browser/ambient/es6-shim/es6-shim.d.ts(621,5): error TS2300: Duplicate identifier 'prototype'.
typings/browser/ambient/es6-shim/index.d.ts(8,14): error TS2300: Duplicate identifier 'PropertyKey'.
typings/browser/ambient/es6-shim/index.d.ts(11,5): error TS2300: Duplicate identifier 'done'.
typings/browser/ambient/es6-shim/index.d.ts(12,5): error TS2300: Duplicate identifier 'value'.
typings/browser/ambient/es6-shim/index.d.ts(250,5): error TS2300: Duplicate identifier 'EPSILON'.
typings/browser/ambient/es6-shim/index.d.ts(285,5): error TS2300: Duplicate identifier 'MAX_SAFE_INTEGER'.
typings/browser/ambient/es6-shim/index.d.ts(292,5): error TS2300: Duplicate identifier 'MIN_SAFE_INTEGER'.
typings/browser/ambient/es6-shim/index.d.ts(348,5): error TS2300: Duplicate identifier 'flags'.
typings/browser/ambient/es6-shim/index.d.ts(500,5): error TS2300: Duplicate identifier 'prototype'.
typings/browser/ambient/es6-shim/index.d.ts(563,5): error TS2300: Duplicate identifier 'size'.
typings/browser/ambient/es6-shim/index.d.ts(572,5): error TS2300: Duplicate identifier 'prototype'.
typings/browser/ambient/es6-shim/index.d.ts(583,5): error TS2300: Duplicate identifier 'size'.
typings/browser/ambient/es6-shim/index.d.ts(592,5): error TS2300: Duplicate identifier 'prototype'.
typings/browser/ambient/es6-shim/index.d.ts(607,5): error TS2300: Duplicate identifier 'prototype'.
typings/browser/ambient/es6-shim/index.d.ts(621,5): error TS2300: Duplicate identifier 'prototype'.

npm ERR! Darwin 15.4.0
npm ERR! argv "/usr/local/Cellar/node/5.10.1/bin/node" "/usr/local/bin/npm" "start"
npm ERR! node v5.10.1
npm ERR! npm  v3.8.6
npm ERR! code ELIFECYCLE
npm ERR! angular2-quickstart@1.0.0 start: `tsc && concurrently "npm run tsc:w" "npm run lite" `
npm ERR! Exit status 2
npm ERR! 
npm ERR! Failed at the angular2-quickstart@1.0.0 start script 'tsc && concurrently "npm run tsc:w" "npm run lite" '.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the angular2-quickstart package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     tsc && concurrently "npm run tsc:w" "npm run lite" 
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs angular2-quickstart
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls angular2-quickstart
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     /Users/vincentDMG/Documents/Git/angular2-tour-of-heroes/npm-debug.log

I have the last version for node.js and NPM and my package comes from the site angular.io. The last version f the quick start.

Can you help me please ?

Thanks!

3
Leave a Reply

avatar
3 Comment threads
0 Thread replies
0 Followers
 
Most reacted comment
Hottest comment thread
1 Comment authors
Jason Recent comment authors
  Subscribe  
newest oldest most voted
Notify of
Jason
Guest

It looks like your npm install went wrong. See the next error.

npm WARN lifecycle angular2-quickstart@1.0.0~postinstall: cannot run in wd %s %s (wd=%s) angular2-quickstart@1.0.0 typings install /Users/vincentDMG/Documents/Git/angular2-tour-of-heroes

What you could do is running the command typings install. The output should look like.

> typings install
├── es6-shim (ambient)
└── jasmine (ambient)

Jason
Guest

You have got definition conflict. Check you definition references (comments that start with /// <reference path=") and make sure you do not include definitions of different libraries that provide the same polyfills.

Jason
Guest

I got the same issue, it was related to my enterprise proxy.
Added a .typingsrc file in project folder with following content fixed it.

{
    "proxy":"http://xxx.xxx.xxx.xxx:80"
}

Unfortunately typings:^1.0.4 doesn’t seems to use $http_proxy env var 🙁
At least mine was set at the moment inside my docker container.