简体   繁体   中英

npm ERR! jspm bundle

I was cloning an already existing project. As I was building, I got this error saved in the npm-debug.log :

0 info it worked if it ends with ok
1 verbose cli [ 'c:\\Program Files\\nodejs\\node.exe',
1 verbose cli   'c:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js',
1 verbose cli   'run',
1 verbose cli   'bundle-dep' ]
2 info using npm@2.10.1
3 info using node@v0.12.4
4 verbose run-script [ 'prebundle-dep', 'bundle-dep', 'postbundle-dep' ]
5 info prebundle-dep sdk@1.0.0
6 info bundle-dep sdk@1.0.0
7 verbose unsafe-perm in lifecycle true
8 info sdk@1.0.0 Failed to exec bundle-dep script
9 verbose stack Error: sdk@1.0.0 bundle-dep: `jspm bundle "src - [src/**/*] - [components/**/*]" www/bundle.js`
9 verbose stack Exit status 1
9 verbose stack     at EventEmitter.<anonymous> (c:\Program Files\nodejs\node_modules\npm\lib\utils\lifecycle.js:213:16)
9 verbose stack     at EventEmitter.emit (events.js:110:17)
9 verbose stack     at ChildProcess.<anonymous> (c:\Program Files\nodejs\node_modules\npm\lib\utils\spawn.js:24:14)
9 verbose stack     at ChildProcess.emit (events.js:110:17)
9 verbose stack     at maybeClose (child_process.js:1015:16)
9 verbose stack     at Process.ChildProcess._handle.onexit (child_process.js:1087:5)
10 verbose pkgid sdk@1.0.0
11 verbose cwd c:\GIT\mas\Rapid\hide
12 error Windows_NT 6.1.7601
13 error argv "c:\\Program Files\\nodejs\\node.exe" "c:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "run" "bundle-dep"
14 error node v0.12.4
15 error npm  v2.10.1
16 error code ELIFECYCLE
17 error sdk@1.0.0 bundle-dep: `jspm bundle "src - [src/**/*] - [components/**/*]" www/bundle.js`
17 error Exit status 1
18 error Failed at the sdk@1.0.0 bundle-dep script 'jspm bundle "src - [src/**/*] - [components/**/*]" www/bundle.js'.
18 error This is most likely a problem with the sdk package,
18 error not with npm itself.
18 error Tell the author that this fails on your system:
18 error     jspm bundle "src - [src/**/*] - [components/**/*]" www/bundle.js
18 error You can get their info via:
18 error     npm owner ls sdk
18 error There is likely additional logging output above.
19 verbose exit [ 1, true ]

While here's the package.json :

{
  "name": "sdk",
  "version": "1.0.0",
  "description": "",
  "main": "index.js",
  "scripts": {
    "postinstall": "typings install && bower install --production && jspm install && node src/tools/updateDependencies.js && npm run bundle-dep",
    "_jspm": "jspm install",
    "_postjspm": "node src/tools/updateDependencies.js && npm run bundle-dep",
    "bundle-dep": "jspm bundle \"src - [src/**/*] - [components/**/*]\" www/bundle.js",
    "start": "node dev-server.js"
  },
  "author": "",
  "license": "ISC",
  "dependencies": {
    "jspm": "^0.17.0-beta.12",
    "typings": "^0.7.12"
  },
  "devDependencies": {
    "angular2": "2.0.0-beta.15",
    "chokidar-socket-emitter": "^0.3.1",
    "express": "^4.13.4",
    "open": "0.0.5",
    "rxjs": "5.0.0-beta.2",
    "spdy": "^3.2.3"
  },
  "jspm": {
    "name": "sdk",
    "directories": {
      "lib": "src"
    },
    "dependencies": {
      "angular2": "npm:angular2@2.0.0-beta.15",
      "es6-shim": "github:es-shims/es6-shim@^0.35.0",
      "json": "github:systemjs/plugin-json@^0.1.0",
      "systemjs-hot-reloader": "github:capaj/systemjs-hot-reloader@^0.5.6"
    },
    "devDependencies": {
      "os": "github:jspm/nodelibs-os@^0.2.0-alpha",
      "plugin-typescript": "github:frankwallis/plugin-typescript@^4.0.5"
    },
    "peerDependencies": {
      "assert": "github:jspm/nodelibs-assert@^0.2.0-alpha",
      "fs": "github:jspm/nodelibs-fs@^0.2.0-alpha",
      "net": "github:jspm/nodelibs-net@^0.2.0-alpha",
      "process": "github:jspm/nodelibs-process@^0.2.0-alpha",
      "reflect-metadata": "npm:reflect-metadata@0.1.2",
      "rxjs": "npm:rxjs@^5.0.0-beta.2",
      "tty": "github:jspm/nodelibs-tty@^0.2.0-alpha",
      "util": "github:jspm/nodelibs-util@^0.2.0-alpha",
      "zone.js": "npm:zone.js@^0.6.6"
    },
    "overrides": {
      "npm:angular2@2.0.0-beta.15": {
        "main": false,
        "dependencies": {
          "reflect-metadata": "npm:reflect-metadata@0.1.2",
          "rxjs": "npm:rxjs@^5.0.0-beta.2",
          "zone.js": "npm:zone.js@^0.6.6"
        },
        "peerDependencies": {
          "reflect-metadata": "npm:reflect-metadata@0.1.2",
          "rxjs": "npm:rxjs@^5.0.0-beta.2",
          "zone.js": "npm:zone.js@^0.6.6"
        },
        "jspmNodeConversion": false,
        "map": {
          "crypto": "@empty"
        },
        "meta": {
          "src/*.js": {
            "deps": [
              "reflect-metadata",
              "zone.js"
            ]
          }
        },
        "format": "detect"
      },
      "npm:debug@2.2.0": {
        "main": "browser.js",
        "jspmNodeConversion": false,
        "format": "cjs",
        "map": {
          "./browser.js": {
            "node": "./node.js"
          },
          "fs": "@node/fs",
          "net": "@node/net",
          "tty": "@node/tty",
          "util": "@node/util"
        }
      },
      "npm:ms@0.7.1": {
        "jspmNodeConversion": false,
        "format": "cjs"
      },
      "npm:reflect-metadata@0.1.2": {
        "map": {
          "crypto": "@empty"
        }
      },
      "npm:typescript@1.8.9": {
        "browser": {},
        "map": {
          "buffer": "@empty",
          "child_process": "@empty",
          "fs": "@empty",
          "path": "@empty",
          "process": "@empty",
          "readline": "@empty"
        }
      }
    }
  }
}

It seems that the problem is on the bundle-dep under scripts . What could have gone wrong?

The error is caused by a script triggered as part of the install.

This is in the package.json:

 "scripts": {
    "postinstall": ... && jspm install ..."

It looks like this package expects you to have jspm already installed globally.

If you trust this package , you can run npm install -g jspm and try again.

More documents here .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM