core-js: Cannot find module in core-js when running from NPX

Before the latest change, all was fine, but now if I try to run npx bolt --version on CircleCI I get this error pointing at your package.

I know you had a recent change around postinstall and I know this isn’t a bolt issue because it happens with other packages that have core-js as a dependency too.

internal/modules/cjs/loader.js:583
    throw err;
    ^

Error: Cannot find module '/root/.npm/_npx/51/lib/node_modules/bolt/node_modules/core-js/scripts/postinstall'
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:581:15)
    at Function.Module._load (internal/modules/cjs/loader.js:507:25)
    at Function.Module.runMain (internal/modules/cjs/loader.js:742:12)
    at startup (internal/bootstrap/node.js:266:19)
    at bootstrapNodeJSCore (internal/bootstrap/node.js:596:3)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! core-js@2.6.6 postinstall: `node scripts/postinstall`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the core-js@2.6.6 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2019-05-20T09_53_15_750Z-debug.log
Install for bolt@0.22.5 failed with code 1
Exited with code 1

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Reactions: 8
  • Comments: 18 (6 by maintainers)

Commits related to this issue

Most upvoted comments

It’s already released in core-js@3.1.2 and core-js@2.6.8.

@nicolo-ribaudo something like that makes sense 👍