Anything related to Zurb Foundation in Node JS throws the same error - npm

I am trying to access the template from this repository: https://github.com/zurb/foundation-sites-template
I successfully cloned the repository, but apparently, in order to get the actual sass, I need to install npm dependencies. So I ran npm install, only to get this error:
events.js:160░░░░░░⸩ ⠼ extract:interpret: sill extract interpret#1.0.4
throw er; // Unhandled 'error' event
^
Error: write after end
at writeAfterEnd (_stream_writable.js:193:12)
at PassThrough.Writable.write (_stream_writable.js:240:5)
at PassThrough.Writable.end (_stream_writable.js:477:10)
at ReadEntry.entry.on (/usr/local/lib/node_modules/npm/node_modules/pacote/lib/extract-stream.js:19:41)
at emitOne (events.js:101:20)
at ReadEntry.emit (events.js:188:7)
at ReadEntry.emit (/usr/local/lib/node_modules/npm/node_modules/tar/node_modules/minipass/index.js:296:25)
at ReadEntry.[maybeEmitEnd] (/usr/local/lib/node_modules/npm/node_modules/tar/node_modules/minipass/index.js:249:12)
at ReadEntry.end (/usr/local/lib/node_modules/npm/node_modules/tar/node_modules/minipass/index.js:162:27)
at Unpack.[consumeBody] (/usr/local/lib/node_modules/npm/node_modules/tar/lib/parse.js:210:13)
at Unpack.[consumeChunkSub] (/usr/local/lib/node_modules/npm/node_modules/tar/lib/parse.js:391:40)
at Unpack.[consumeChunk] (/usr/local/lib/node_modules/npm/node_modules/tar/lib/parse.js:362:30)
at Unzip.(anonymous function).on.chunk (/usr/local/lib/node_modules/npm/node_modules/tar/lib/parse.js:291:59)
at emitOne (events.js:96:13)
at Unzip.emit (events.js:188:7)
at Unzip.emit (/usr/local/lib/node_modules/npm/node_modules/tar/node_modules/minipass/index.js:296:25)
I am using npm version 6.0.0 and node v6.11.2. Running on a mac.
After this I tried installing the foundation cli with npm install foundation-cli --global, but got the exact same error. As far as I know, I meet all the requirements as listed on the github repository, not sure what could be the problem.

Well, turns out it was either my npm or node version. I updated both to the most recent (npm 6.4.1, node v10.8.0) versions, and npm install ran fine. I suppose what can be learned here is that when dealing with zurb foundation, just try to use the latest software.

Related

Getting error when installing Bugsnag 'Error: spawn npm ENOENT'

this is the first time I post here so apologies if I don't follow some rules or incorrect formatting.
I'm making an app using React Native and Expo and when I try to install bugsnag I get this error.
$ npx bugsnag-expo-cli init
√ #bugsnag/expo does not appear to be installed, do you want to install it? ... yes
√ If you want the latest version of #bugsnag/expo hit enter, otherwise type the version you want ... latest
√ Using yarn or npm? » npm
> Installing #bugsnag/expo with npm. This could take a while!
Error: spawn npm ENOENT
at Process.ChildProcess._handle.onexit (internal/child_process.js:269:19)
at onErrorNT (internal/child_process.js:465:16)
at processTicksAndRejections (internal/process/task_queues.js:80:21)
Are you attempting to run the bugsnag-expo-cli on Windows? The Expo CLI currently only supports MacOS and Linux:
https://docs.bugsnag.com/platforms/react-native/expo/#installation-and-configuration
As an alternative to the CLI, you can follow the manual integration guide:
https://docs.bugsnag.com/platforms/react-native/expo/manual-setup/

Unable to install 'node-red-contrib-tf-model' using NPM on windows10x64

I followed the tutorials below for the installation of the tensorflow model:
https://flows.nodered.org/node/node-red-contrib-tf-model
https://github.com/tensorflow/tfjs/blob/master/tfjs-node/WINDOWS_TROUBLESHOOTING.md
Steps taken:
I first installed the #tensorflow/tfjs-node inside Node-RED directly by running the following code:
C:\Users\username\.node-red\node_modules> npm install #tensorflow/tfjs-node#1.4.0
Ran npm install under C:\Users\username\.node-red\node_modules\#tensorflow\tfjs-node:
C:\Users\username\.node-red\node_modules\#tensorflow\tfjs-node> npm install
Finally ran npm install node-red-contrib-tf-model in the same directory:
C:\Users\username\.node-red\node_modules\#tensorflow\tfjs-node> npm install node-red-contrib-tf-model
Error that occured:
npm WARN node-red-contrib-tf-model#0.1.11 requires a peer of #tensorflow/tfjs-node#^1.4.0 but none is installed. You must install peer dependencies yourself.
npm WARN #tensorflow/tfjs-node#1.4.0 No license field.
I have installed the correct tfjs-node version, and so why does this error occur?
Edit: Tried installing the module straight from Node-RED itself and got the following
ERROR:The specified module could not be found.
C:\Users\username\.node-red\node_modules\#tensorflow\tfjs-node\lib\napi-v6\tfjs_binding.node
When I checked the above directory it turns out that I do have the 'tfjs_binding.node'.
What am I doing wrong here? Can someone please help me out.

Upgrading jhipster from v5.0.1 to the latest

I am running linux 18.04, installed java 8. I am struggling with upgrading the current version of jhipster (v5.0.1)to the latest. I have used, yo, yarn and npm but there is no success.
With npm I get an error below, with yo i get the [subsequent] error:
Using JHipster version installed globally Executing jhipster:upgradeOptions:
Welcome to the JHipster Upgrade Sub-Generator
This will upgrade your current application codebase to the latest JHipster version
events.js:174
throw er; // Unhandled 'error' event
^
Error: ERROR! Current directory does not contain a JHipster project.
at Environment.error (/usr/lib/node_modules/generator-jhipster/node_modules/yeoman-environment/lib/environment.js:157:40)
at module.exports.error (/usr/lib/node_modules/generator-jhipster/generators/generator-base.js:1981:18)
at module.exports.assertJHipsterProject (/usr/lib/node_modules/generator-jhipster/generators/upgrade/index.js:144:26)
at Object.<anonymous> (/usr/lib/node_modules/generator-jhipster/node_modules/yeoman-generator/lib/index.js:399:25)
at /usr/lib/node_modules/generator-jhipster/node_modules/run-async/index.js:25:25
at new Promise (<anonymous>)
at /usr/lib/node_modules/generator-jhipster/node_modules/run-async/index.js:24:19
at self.env.runLoop.add.completed (/usr/lib/node_modules/generator-jhipster/node_modules/yeoman-generator/lib/index.js:400:11)
at runCallback (timers.js:705:18)
at tryOnImmediate (timers.js:676:5)
Emitted 'error' event at:
at Immediate.setImmediate (/usr/lib/node_modules/generator-jhipster/node_modules/yeoman-generator/lib/index.js:406:18)
at runCallback (timers.js:705:18)
at tryOnImmediate (timers.js:676:5)
at processImmediate (timers.js:658:5)
[subsequent]
? Generators to update (Press <space> to select, <a> to toggle all, <i> to invert selection)generator-jhipster
Unhandled rejection Error: EACCES: permission denied, open '/home/lelo/.npm/_cacache/index-v5/ad/54/831265f841b3fd278d23c4c96b06a32656a62c88fddaa7739f419602a04d'
npm ERR! cb() never called!
npm ERR! This is an error with npm itself. Please report this error at:
npm ERR! <https://npm.community>
npm ERR! A complete log of this run can be found in:
npm ERR! /home/lelo/.npm/_logs/2019-08-25T22_22_40_369Z-debug.log```
Despite any user type, I am not getting the expected output which is the upgraded version of jhipster. What could I be doing wrong?
Make sure you are in your application directory and have git installed.
Then execute jhipster upgrade.
You will probably have to solve some problems of the resulting merge arising during the update.
More info: https://www.jhipster.tech/upgrading-an-application/

Bower 1.8.3 cannot find module 'q'

I recently updated bower via npm i -g bower and it pulled latest version of 1.8.3.
Now running bower i immediately fails with:
module.js:538
throw err;
^
Error: Cannot find module 'q'
FYI: Workaround is explicitly install 1.8.2 via npm i -g bower#1.8.2
Not that this solves the exact problem, but if you look on the Bower package:
This package has been deprecated Author message:
...psst! Your project can stop working at any moment because its
dependencies can change. Prevent this by migrating to Yarn:
https://bower.io/blog/2017/how-to-migrate-away-from-bower/
They recommend you use a package called Yarn

npm generator-ionic Install Requires yo#>=1.0.0

I'm trying to install generator-ionic, and I get the following fatal error:
EPEERINVALID generator-ionic#0.7.3 requires a peer of yo#>=1.0.0 but none was installed
I'm using node 0.12.17, npm 3.3.6, and yo 1.4.7, so I do not understand what isn't satisfied.
#chrysanhy I think I found the issue. I just downgraded my npm version to 2.7.4 and when I ran the command npm install generator-ionic-g the following message appeared:
npm WARN peerDependencies The peer dependency yo#>=1.0.0 included from generator-ionic will no longer be automatically installed to fulfill the peerDependency in npm 3+. Your application will need to depend on it explicitly.
Now the ionic-generator is working fine on my machine. Hope this helps you and everyone who is facing the same problem.