Skip to content

"phantomjs-prebuilt" fails to install on complex package.json #168

Description

@kirbysayshi

Hello! I was trying out pnpm, and encountered a package that wouldn't install due to a missing dependency error.

$ pnpm install

....


phantomjs-prebuilt@2.1.7! $ node install.js
  sha.js 2.1.6                                          downloading 2.1.6 ↓
  assert-plus >=0.2.0 <0.3.0                                        0.2.0 ✓
  asn1 >=0.2.3 <0.3.0                                   downloading 0.2.3 ↓
  dashdash >=1.10.1 <2.0.0                                  queued 1.13.0 ↓
  minimatch ^2.0.10                                                2.0.10 ✓
  spawn-sync@1.0.13! $ node postinstall
  iconv-lite 0.4.13                                               finding ·
  phantomjs-prebuilt@2.1.7! module.js:338
  phantomjs-prebuilt@2.1.7!     throw err;
  phantomjs-prebuilt@2.1.7!           ^
  phantomjs-prebuilt@2.1.7! Error: Cannot find module 'boom'
  phantomjs-prebuilt@2.1.7!     at Function.Module._resolveFilename (module.js:336:15)
  phantomjs-prebuilt@2.1.7!     at Function.Module._load (module.js:278:25)
  phantomjs-prebuilt@2.1.7!     at Module.require (module.js:365:17)
  phantomjs-prebuilt@2.1.7!     at require (module.js:384:17)
  phantomjs-prebuilt@2.1.7!     at Object.<anonymous> (/private/tmp/node_modules/.tmp/84e00dfc-293c-4130-b662-89312ee41d44/_/lib/index.js:3:33)
  phantomjs-prebuilt@2.1.7!     at Module._compile (module.js:460:26)
  phantomjs-prebuilt@2.1.7!     at Object.Module._extensions..js (module.js:478:10)
  phantomjs-prebuilt@2.1.7!     at Module.load (module.js:355:32)
  phantomjs-prebuilt@2.1.7!     at Function.Module._load (module.js:310:12)
  phantomjs-prebuilt@2.1.7!     at Module.require (module.js:365:17)

node v0.12.7
npm v2.14.8

Using npm after a successful install, I can see this tree:

$ npm ls boom
├─┬ phantomjs-prebuilt@2.1.7
│ └─┬ request@2.67.0
│   └─┬ hawk@3.1.3
│     └── boom@2.10.1
├─┬ request@2.69.0
│ └─┬ hawk@3.1.3
│   └── boom@2.10.1
├─┬ watchify@3.7.0
│ └─┬ chokidar@1.4.3
│   └─┬ fsevents@1.0.9
│     └── boom@2.10.1
└─┬ webhdfs@0.1.12
  └─┬ request@2.33.0
    └─┬ hawk@1.0.0
      └── boom@0.4.2

I'm guessing phantomjs-prebuilt's install script is the cause here. Removing it from this package.json allows pnpm to complete successfully. Strangely, just calling pnpm install phantomjs-prebuilt succeeds. Following that with a full pnpm install also succeeds.

If you'd like me to post the DEBUG log, just let me know! Thanks for a promising tool!

Metadata

Metadata

Assignees

Labels

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions