Yarn: Transient error when running kpm install

Created on 29 Jun 2016  ·  2Comments  ·  Source: yarnpkg/yarn

KPM 0.4.0 produced this error, a subsequent run didn't have this issue. Both reported no lockfile found. There was no lockfile at the time.

$ node nodeModules.js install
fbkpm install v0.4.0
info No lockfile found.
[1/4] 🚚  Resolving and fetching packages...
⠄ is-number@^2.0.2TypeError: Cannot use 'in' operator to search for '^1.3.1' in undefined
    at /opt/facebook/fb-kpm/lib/resolvers/registries/npm.js:31:24
    at next (native)
    at step (/opt/facebook/fb-kpm/node_modules/babel-runtime/helpers/asyncToGenerator.js:17:30)
    at /opt/facebook/fb-kpm/node_modules/babel-runtime/helpers/asyncToGenerator.js:35:14
    at new Promise (/opt/facebook/fb-kpm/node_modules/core-js/library/modules/es6.promise.js:193:7)
    at /opt/facebook/fb-kpm/node_modules/babel-runtime/helpers/asyncToGenerator.js:14:12
    at NpmResolver.findVersionInRegistryResponse (/opt/facebook/fb-kpm/lib/resolvers/registries/npm.js:41:7)
    at /opt/facebook/fb-kpm/lib/resolvers/registries/npm.js:72:29
    at next (native)
    at step (/opt/facebook/fb-kpm/node_modules/babel-runtime/helpers/asyncToGenerator.js:17:30)
/Users/sweeney/fbsource/fbobjc/Libraries/FBReactKit/js/nodeModules.js:400
      throw err;
      ^

Error: Command failed: /opt/homebrew/bin/node /opt/facebook/bin/kpm install
    at checkExecSyncError (child_process.js:469:13)
    at Object.execSync (child_process.js:509:13)
    at execPipe (/Users/sweeney/fbsource/fbobjc/Libraries/FBReactKit/js/nodeModules.js:180:24)
    at exec (/Users/sweeney/fbsource/fbobjc/Libraries/FBReactKit/js/nodeModules.js:194:10)
    at kpmInstall (/Users/sweeney/fbsource/fbobjc/Libraries/FBReactKit/js/nodeModules.js:756:3)
    at Object.<anonymous> (/Users/sweeney/fbsource/fbobjc/Libraries/FBReactKit/js/nodeModules.js:616:7)
    at /Users/sweeney/fbsource/fbobjc/Libraries/FBReactKit/js/nodeModules.js:389:20
    at /Users/sweeney/fbsource/fbobjc/Libraries/FBReactKit/js/nodeModules.js:408:18
    at cliMain (/Users/sweeney/fbsource/fbobjc/Libraries/FBReactKit/js/nodeModules.js:792:12)
    at Object.<anonymous> (/Users/sweeney/fbsource/fbobjc/Libraries/FBReactKit/js/nodeModules.js:803:12)
cat-bug

Most helpful comment

I see this sort of problem consistently with yarn:

> yarn
yarn install v0.15.1
info No lockfile found.
[1/4] 🔍  Resolving packages...
error TypeError: Cannot use 'in' operator to search for '^0.5.1' in undefined
...

All 2 comments

Closing this as it appears to be resolved? Let me know if this is still a transient issues and I'll try and look into it. It's not entirely clear how I'd attempt to reproduce this.

I see this sort of problem consistently with yarn:

> yarn
yarn install v0.15.1
info No lockfile found.
[1/4] 🔍  Resolving packages...
error TypeError: Cannot use 'in' operator to search for '^0.5.1' in undefined
...
Was this page helpful?
0 / 5 - 0 ratings