Unable to install xlsx #571

Closed
opened 2017-02-24 08:03:55 +00:00 by FredrikL · 13 comments
FredrikL commented 2017-02-24 08:03:55 +00:00 (Migrated from github.com)

Since 1 day back I'm unable to install xlsx, the error i get is

npm install xlsx                                                                                                                                                                                                               
npm WARN prefer global voc@0.5.0 should be installed with -g
connectmeto@0.0.0 /Volumes/work/connectmeto
├── adler-32@1.0.0  extraneous
├── codepage@1.6.0  extraneous
├── crc-32@1.0.1  extraneous
└── ssf@0.8.2  extraneous

npm WARN connectmeto@0.0.0 license should be a valid SPDX license expression
npm ERR! Darwin 16.4.0
npm ERR! argv "/Users/fredrik/.nvm/versions/node/v6.9.4/bin/node" "/Users/fredrik/.nvm/versions/node/v6.9.4/bin/npm" "install" "xlsx"
npm ERR! node v6.9.4
npm ERR! npm  v3.10.10
npm ERR! path /Volumes/work/connectmeto/node_modules/cfb/bin/cfb
npm ERR! code ENOENT
npm ERR! errno -2
npm ERR! syscall chmod

npm ERR! enoent ENOENT: no such file or directory, chmod '/Volumes/work/connectmeto/node_modules/cfb/bin/cfb'
npm ERR! enoent ENOENT: no such file or directory, chmod '/Volumes/work/connectmeto/node_modules/cfb/bin/cfb'
npm ERR! enoent This is most likely not a problem with npm itself
npm ERR! enoent and is related to npm not being able to find a file.
npm ERR! enoent

npm ERR! Please include the following file with any support request:

It seems that the cfb module doesn't have the correct semver (or something) on npm causing npm install to fail.

Since 1 day back I'm unable to install xlsx, the error i get is ``` npm install xlsx npm WARN prefer global voc@0.5.0 should be installed with -g connectmeto@0.0.0 /Volumes/work/connectmeto ├── adler-32@1.0.0 extraneous ├── codepage@1.6.0 extraneous ├── crc-32@1.0.1 extraneous └── ssf@0.8.2 extraneous npm WARN connectmeto@0.0.0 license should be a valid SPDX license expression npm ERR! Darwin 16.4.0 npm ERR! argv "/Users/fredrik/.nvm/versions/node/v6.9.4/bin/node" "/Users/fredrik/.nvm/versions/node/v6.9.4/bin/npm" "install" "xlsx" npm ERR! node v6.9.4 npm ERR! npm v3.10.10 npm ERR! path /Volumes/work/connectmeto/node_modules/cfb/bin/cfb npm ERR! code ENOENT npm ERR! errno -2 npm ERR! syscall chmod npm ERR! enoent ENOENT: no such file or directory, chmod '/Volumes/work/connectmeto/node_modules/cfb/bin/cfb' npm ERR! enoent ENOENT: no such file or directory, chmod '/Volumes/work/connectmeto/node_modules/cfb/bin/cfb' npm ERR! enoent This is most likely not a problem with npm itself npm ERR! enoent and is related to npm not being able to find a file. npm ERR! enoent npm ERR! Please include the following file with any support request: ``` It seems that the cfb module doesn't have the correct semver (or something) on npm causing npm install to fail.
SheetJSDev commented 2017-02-24 08:06:36 +00:00 (Migrated from github.com)

Which version of node/npm are you using?

Which version of node/npm are you using?
FredrikL commented 2017-02-24 08:08:46 +00:00 (Migrated from github.com)

Node v6.9.4
Npm 3.10.10

Node v6.9.4 Npm 3.10.10
SheetJSDev commented 2017-02-24 08:16:15 +00:00 (Migrated from github.com)

@FredrikL ok I can confirm with that particular combination trying to install with a >= version spec is causing issues, not entirely sure why. I'm going to push a 0.11.0 version of cfb and then a 0.8.6 xlsx with the package.json with a version spec like "~0.11". Stay tuned

@FredrikL ok I can confirm with that particular combination trying to install with a `>=` version spec is causing issues, not entirely sure why. I'm going to push a 0.11.0 version of cfb and then a 0.8.6 xlsx with the package.json with a version spec like "~0.11". Stay tuned
mooyoul commented 2017-02-24 08:18:27 +00:00 (Migrated from github.com)

Yeah We having this issue too, deploys are failing now 😢

Yeah We having this issue too, deploys are failing now 😢
SheetJSDev commented 2017-02-24 08:20:30 +00:00 (Migrated from github.com)

@FredrikL @mooyoul I just pushed the same cfb code to version 0.11.0, can you test again and see if the install works?

@FredrikL @mooyoul I just pushed the same cfb code to version 0.11.0, can you test again and see if the install works?
FredrikL commented 2017-02-24 08:22:04 +00:00 (Migrated from github.com)

yes, works now, thanks!

yes, works now, thanks!
mooyoul commented 2017-02-24 08:22:21 +00:00 (Migrated from github.com)

Sure, re-deploying to staging/production server now... stay tuned :)

Sure, re-deploying to staging/production server now... stay tuned :)
mooyoul commented 2017-02-24 08:30:17 +00:00 (Migrated from github.com)

@SheetJSDev Okay, Deploys were successfully ended without having any issues.
Issue seems resolved now. Thanks for quick response and fix 👍 🍻

@SheetJSDev Okay, Deploys were successfully ended without having any issues. Issue seems resolved now. Thanks for quick response and fix 👍 🍻
mooyoul commented 2017-02-24 08:38:50 +00:00 (Migrated from github.com)

@SheetJSDev FYI, this is full npm verbose log.
In my case, npm couldn't find cfb/bin/cfb file, so chown command was failed.

[/tmp]$ npm i cfb@0.10.2 --verbose
npm info it worked if it ends with ok
npm verb cli [ '/usr/bin/nodejs',
npm verb cli   '/usr/bin/npm',
npm verb cli   'i',
npm verb cli   'cfb@0.10.2',
npm verb cli   '--verbose' ]
npm info using npm@3.10.9
npm info using node@v5.12.0
npm verb get https://registry.npmjs.org/cfb not expired, no request
npm verb cache add spec cfb@0.10.2
npm verb addNamed "0.10.2" is a plain semver version for cfb
npm verb addNameVersion registry:https://registry.npmjs.org/cfb not in flight; fetching
npm verb get https://registry.npmjs.org/cfb not expired, no request
npm verb afterAdd /home/web/.npm/cfb/0.10.2/package/package.json not in flight; writing
npm verb correctMkdir /home/web/.npm correctMkdir not in flight; initializing
npm verb afterAdd /home/web/.npm/cfb/0.10.2/package/package.json written
npm verb get https://registry.npmjs.org/commander not expired, no request
npm verb cache add spec commander@
npm verb addNamed "latest" is being treated as a dist-tag for commander
npm info addNameTag [ 'commander', 'latest' ]
npm verb addNameTag registry:https://registry.npmjs.org/commander not in flight; fetching
npm verb get https://registry.npmjs.org/commander not expired, no request
npm verb addNamed "2.9.0" is a plain semver version for commander
npm verb afterAdd /home/web/.npm/commander/2.9.0/package/package.json not in flight; writing
npm verb correctMkdir /home/web/.npm correctMkdir not in flight; initializing
npm verb afterAdd /home/web/.npm/commander/2.9.0/package/package.json written
npm verb get https://registry.npmjs.org/graceful-readlink not expired, no request
npm verb cache add spec graceful-readlink@>= 1.0.0
npm verb addNamed ">=1.0.0" is a valid semver range for graceful-readlink
npm verb addNameRange registry:https://registry.npmjs.org/graceful-readlink not in flight; fetching
npm verb get https://registry.npmjs.org/graceful-readlink not expired, no request
npm verb addNamed "1.0.1" is a plain semver version for graceful-readlink
npm verb afterAdd /home/web/.npm/graceful-readlink/1.0.1/package/package.json not in flight; writing
npm verb correctMkdir /home/web/.npm correctMkdir not in flight; initializing
npm verb afterAdd /home/web/.npm/graceful-readlink/1.0.1/package/package.json written
npm verb correctMkdir /home/web/.npm/_locks correctMkdir not in flight; initializing
npm verb lock using /home/web/.npm/_locks/staging-08463ceb8fd2d012.lock for /tmp/node_modules/.staging
npm verb unbuild node_modules/.staging/graceful-readlink-2f47043c
npm verb unbuild node_modules/.staging/commander-a57aee7a
npm verb unbuild node_modules/.staging/cfb-2869d483
npm verb gentlyRm don't care about contents; nuking /tmp/node_modules/.staging/graceful-readlink-2f47043c
npm verb gentlyRm don't care about contents; nuking /tmp/node_modules/.staging/commander-a57aee7a
npm verb tar unpack /home/web/.npm/graceful-readlink/1.0.1/package.tgz
npm verb tar unpacking to /tmp/node_modules/.staging/graceful-readlink-2f47043c
npm verb gentlyRm don't care about contents; nuking /tmp/node_modules/.staging/graceful-readlink-2f47043c
npm verb tar unpack /home/web/.npm/commander/2.9.0/package.tgz
npm verb tar unpacking to /tmp/node_modules/.staging/commander-a57aee7a
npm verb gentlyRm don't care about contents; nuking /tmp/node_modules/.staging/commander-a57aee7a
npm verb gentlyRm don't care about contents; nuking /tmp/node_modules/.staging/cfb-2869d483
npm verb tar unpack /home/web/.npm/cfb/0.10.2/package.tgz
npm verb tar unpacking to /tmp/node_modules/.staging/cfb-2869d483
npm verb gentlyRm don't care about contents; nuking /tmp/node_modules/.staging/cfb-2869d483
npm verb gentlyRm don't care about contents; nuking /tmp/node_modules/.staging/commander-a57aee7a/node_modules
npm verb gentlyRm don't care about contents; nuking /tmp/node_modules/.staging/graceful-readlink-2f47043c/node_modules
npm verb gentlyRm don't care about contents; nuking /tmp/node_modules/.staging/cfb-2869d483/node_modules
npm info lifecycle graceful-readlink@1.0.1~preinstall: graceful-readlink@1.0.1
npm info lifecycle commander@2.9.0~preinstall: commander@2.9.0
npm info lifecycle cfb@0.10.2~preinstall: cfb@0.10.2
npm info linkStuff graceful-readlink@1.0.1
npm verb linkBins graceful-readlink@1.0.1
npm verb linkMans graceful-readlink@1.0.1
npm info linkStuff commander@2.9.0
npm verb linkBins commander@2.9.0
npm verb linkMans commander@2.9.0
npm info linkStuff cfb@0.10.2
npm verb linkBins cfb@0.10.2
npm verb link bins [ { cfb: './bin/cfb' }, '/tmp/node_modules/.bin', false ]
npm verb linkMans cfb@0.10.2
npm verb unlock done using /home/web/.npm/_locks/staging-08463ceb8fd2d012.lock for /tmp/node_modules/.staging
npm WARN enoent ENOENT: no such file or directory, open '/tmp/package.json'
npm verb enoent ENOENT: no such file or directory, open '/tmp/package.json'
npm verb enoent This is most likely not a problem with npm itself
npm verb enoent and is related to npm not being able to find a file.
npm verb enoent
npm WARN tmp No description
npm verb
npm verb If you need help, you may report this error at:
npm verb     <https://github.com/npm/npm/issues>
npm WARN tmp No repository field.
npm verb
npm verb If you need help, you may report this error at:
npm verb     <https://github.com/npm/npm/issues>
npm WARN tmp No README data
npm verb
npm verb If you need help, you may report this error at:
npm verb     <https://github.com/npm/npm/issues>
npm WARN tmp No license field.
npm verb
npm verb If you need help, you may report this error at:
npm verb     <https://github.com/npm/npm/issues>
npm verb stack Error: ENOENT: no such file or directory, chmod '/tmp/node_modules/cfb/bin/cfb'
npm verb stack     at Error (native)
npm verb cwd /tmp
npm ERR! Linux 3.2.0-32-virtual
npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "i" "cfb@0.10.2" "--verbose"
npm ERR! node v5.12.0
npm ERR! npm  v3.10.9
npm ERR! path /tmp/node_modules/cfb/bin/cfb
npm ERR! code ENOENT
npm ERR! errno -2
npm ERR! syscall chmod

npm ERR! enoent ENOENT: no such file or directory, chmod '/tmp/node_modules/cfb/bin/cfb'
npm ERR! enoent ENOENT: no such file or directory, chmod '/tmp/node_modules/cfb/bin/cfb'
npm ERR! enoent This is most likely not a problem with npm itself
npm ERR! enoent and is related to npm not being able to find a file.
npm ERR! enoent
npm verb exit [ -2, true ]

npm ERR! Please include the following file with any support request:
npm ERR!     /tmp/npm-debug.log
@SheetJSDev FYI, this is full npm verbose log. In my case, npm couldn't find `cfb/bin/cfb` file, so chown command was failed. ``` [/tmp]$ npm i cfb@0.10.2 --verbose npm info it worked if it ends with ok npm verb cli [ '/usr/bin/nodejs', npm verb cli '/usr/bin/npm', npm verb cli 'i', npm verb cli 'cfb@0.10.2', npm verb cli '--verbose' ] npm info using npm@3.10.9 npm info using node@v5.12.0 npm verb get https://registry.npmjs.org/cfb not expired, no request npm verb cache add spec cfb@0.10.2 npm verb addNamed "0.10.2" is a plain semver version for cfb npm verb addNameVersion registry:https://registry.npmjs.org/cfb not in flight; fetching npm verb get https://registry.npmjs.org/cfb not expired, no request npm verb afterAdd /home/web/.npm/cfb/0.10.2/package/package.json not in flight; writing npm verb correctMkdir /home/web/.npm correctMkdir not in flight; initializing npm verb afterAdd /home/web/.npm/cfb/0.10.2/package/package.json written npm verb get https://registry.npmjs.org/commander not expired, no request npm verb cache add spec commander@ npm verb addNamed "latest" is being treated as a dist-tag for commander npm info addNameTag [ 'commander', 'latest' ] npm verb addNameTag registry:https://registry.npmjs.org/commander not in flight; fetching npm verb get https://registry.npmjs.org/commander not expired, no request npm verb addNamed "2.9.0" is a plain semver version for commander npm verb afterAdd /home/web/.npm/commander/2.9.0/package/package.json not in flight; writing npm verb correctMkdir /home/web/.npm correctMkdir not in flight; initializing npm verb afterAdd /home/web/.npm/commander/2.9.0/package/package.json written npm verb get https://registry.npmjs.org/graceful-readlink not expired, no request npm verb cache add spec graceful-readlink@>= 1.0.0 npm verb addNamed ">=1.0.0" is a valid semver range for graceful-readlink npm verb addNameRange registry:https://registry.npmjs.org/graceful-readlink not in flight; fetching npm verb get https://registry.npmjs.org/graceful-readlink not expired, no request npm verb addNamed "1.0.1" is a plain semver version for graceful-readlink npm verb afterAdd /home/web/.npm/graceful-readlink/1.0.1/package/package.json not in flight; writing npm verb correctMkdir /home/web/.npm correctMkdir not in flight; initializing npm verb afterAdd /home/web/.npm/graceful-readlink/1.0.1/package/package.json written npm verb correctMkdir /home/web/.npm/_locks correctMkdir not in flight; initializing npm verb lock using /home/web/.npm/_locks/staging-08463ceb8fd2d012.lock for /tmp/node_modules/.staging npm verb unbuild node_modules/.staging/graceful-readlink-2f47043c npm verb unbuild node_modules/.staging/commander-a57aee7a npm verb unbuild node_modules/.staging/cfb-2869d483 npm verb gentlyRm don't care about contents; nuking /tmp/node_modules/.staging/graceful-readlink-2f47043c npm verb gentlyRm don't care about contents; nuking /tmp/node_modules/.staging/commander-a57aee7a npm verb tar unpack /home/web/.npm/graceful-readlink/1.0.1/package.tgz npm verb tar unpacking to /tmp/node_modules/.staging/graceful-readlink-2f47043c npm verb gentlyRm don't care about contents; nuking /tmp/node_modules/.staging/graceful-readlink-2f47043c npm verb tar unpack /home/web/.npm/commander/2.9.0/package.tgz npm verb tar unpacking to /tmp/node_modules/.staging/commander-a57aee7a npm verb gentlyRm don't care about contents; nuking /tmp/node_modules/.staging/commander-a57aee7a npm verb gentlyRm don't care about contents; nuking /tmp/node_modules/.staging/cfb-2869d483 npm verb tar unpack /home/web/.npm/cfb/0.10.2/package.tgz npm verb tar unpacking to /tmp/node_modules/.staging/cfb-2869d483 npm verb gentlyRm don't care about contents; nuking /tmp/node_modules/.staging/cfb-2869d483 npm verb gentlyRm don't care about contents; nuking /tmp/node_modules/.staging/commander-a57aee7a/node_modules npm verb gentlyRm don't care about contents; nuking /tmp/node_modules/.staging/graceful-readlink-2f47043c/node_modules npm verb gentlyRm don't care about contents; nuking /tmp/node_modules/.staging/cfb-2869d483/node_modules npm info lifecycle graceful-readlink@1.0.1~preinstall: graceful-readlink@1.0.1 npm info lifecycle commander@2.9.0~preinstall: commander@2.9.0 npm info lifecycle cfb@0.10.2~preinstall: cfb@0.10.2 npm info linkStuff graceful-readlink@1.0.1 npm verb linkBins graceful-readlink@1.0.1 npm verb linkMans graceful-readlink@1.0.1 npm info linkStuff commander@2.9.0 npm verb linkBins commander@2.9.0 npm verb linkMans commander@2.9.0 npm info linkStuff cfb@0.10.2 npm verb linkBins cfb@0.10.2 npm verb link bins [ { cfb: './bin/cfb' }, '/tmp/node_modules/.bin', false ] npm verb linkMans cfb@0.10.2 npm verb unlock done using /home/web/.npm/_locks/staging-08463ceb8fd2d012.lock for /tmp/node_modules/.staging npm WARN enoent ENOENT: no such file or directory, open '/tmp/package.json' npm verb enoent ENOENT: no such file or directory, open '/tmp/package.json' npm verb enoent This is most likely not a problem with npm itself npm verb enoent and is related to npm not being able to find a file. npm verb enoent npm WARN tmp No description npm verb npm verb If you need help, you may report this error at: npm verb <https://github.com/npm/npm/issues> npm WARN tmp No repository field. npm verb npm verb If you need help, you may report this error at: npm verb <https://github.com/npm/npm/issues> npm WARN tmp No README data npm verb npm verb If you need help, you may report this error at: npm verb <https://github.com/npm/npm/issues> npm WARN tmp No license field. npm verb npm verb If you need help, you may report this error at: npm verb <https://github.com/npm/npm/issues> npm verb stack Error: ENOENT: no such file or directory, chmod '/tmp/node_modules/cfb/bin/cfb' npm verb stack at Error (native) npm verb cwd /tmp npm ERR! Linux 3.2.0-32-virtual npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "i" "cfb@0.10.2" "--verbose" npm ERR! node v5.12.0 npm ERR! npm v3.10.9 npm ERR! path /tmp/node_modules/cfb/bin/cfb npm ERR! code ENOENT npm ERR! errno -2 npm ERR! syscall chmod npm ERR! enoent ENOENT: no such file or directory, chmod '/tmp/node_modules/cfb/bin/cfb' npm ERR! enoent ENOENT: no such file or directory, chmod '/tmp/node_modules/cfb/bin/cfb' npm ERR! enoent This is most likely not a problem with npm itself npm ERR! enoent and is related to npm not being able to find a file. npm ERR! enoent npm verb exit [ -2, true ] npm ERR! Please include the following file with any support request: npm ERR! /tmp/npm-debug.log ```
mooyoul commented 2017-02-24 08:50:44 +00:00 (Migrated from github.com)

@SheetJSDev Note that npm uses node-semver package,
and that node-semver treats 0.10.3-a version as prerelease version!

so, if there are 0.10.3 version and 0.10.3-a version, 0.10.3 version will be treated as latest version since 0.10.3-a version was treated as prerelease version.

Please see below screenshot:
2017-02-24 5 50 01

@SheetJSDev Note that npm uses [node-semver](https://github.com/npm/node-semver) package, and that **`node-semver` treats `0.10.3-a` version as `prerelease` version!** so, if there are `0.10.3` version and `0.10.3-a` version, `0.10.3` version will be treated as latest version since `0.10.3-a` version was treated as `prerelease` version. Please see below screenshot: <img width="345" alt="2017-02-24 5 50 01" src="https://cloud.githubusercontent.com/assets/2101743/23296717/b283e934-fab9-11e6-935f-56218811d1d4.png">
SheetJSDev commented 2017-02-24 09:00:00 +00:00 (Migrated from github.com)

@mooyoul thanks for investigating further, my sincerest apologies for pushing a pre-release semver :( I'm still confused by why the entire install would bomb out. Shouldn't the spec ">=0.10.0" pick the 0.10.3 version (which would have been the latest version before yesterday)?

@mooyoul thanks for investigating further, my sincerest apologies for pushing a pre-release semver :( I'm still confused by why the entire install would bomb out. Shouldn't the spec ">=0.10.0" pick the 0.10.3 version (which would have been the latest version before yesterday)?
mooyoul commented 2017-02-25 20:32:53 +00:00 (Migrated from github.com)

@SheetJSDev hmm i was digging about this issue a little more,

I found interesting part from deploy log
(here is full npm-debug.log gist)

Interesting part was:
actually npm resolved both cfb@0.10.2 and cfb@0.10.3 from xlsx dependency, downloaded cfb@0.10.3, but tried to extract cfb@0.10.2 tarball. and it was failed.

I don't know why it was caused by something exactly, but guessing some cache stuff caused that weird behavior.

Hope this helps.

@SheetJSDev hmm i was digging about this issue a little more, I found interesting part from deploy log ([here is full npm-debug.log gist](https://gist.github.com/mooyoul/32a18d419123f9cc823d90bf9c205572)) Interesting part was: actually npm resolved *both* cfb@0.10.2 and cfb@0.10.3 from xlsx dependency, downloaded cfb@0.10.3, but tried to extract cfb@0.10.2 tarball. and it was failed. I don't know why it was caused by something exactly, but guessing some cache stuff caused that weird behavior. Hope this helps.
SheetJSDev commented 2017-02-25 21:36:53 +00:00 (Migrated from github.com)

@mooyoul Thanks for looking into this further! This is an NPM bug and I can reproduce it, will make an npm issue shortly. The short term problem was resolved and I will refrain from pushing anything remotely resembling a pre-release or post-release in the future.

@mooyoul Thanks for looking into this further! This is an NPM bug and I can reproduce it, will make an npm issue shortly. The short term problem was resolved and I will refrain from pushing anything remotely resembling a pre-release or post-release in the future.
Sign in to join this conversation.
No Milestone
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: sheetjs/sheetjs#571
No description provided.