Closed mutech closed 6 years ago
I can confirm I encountered the same issue. Downgrading to the LTS (8.x) version of node fixes this.
I have a similar issue with node 9.6.1
and @stencil/core@0.6.1
on macOS 10.13.3
. I installed npm install -g nan
, which succeeded but I still get errors trying to install fsevents@1.1.2
:
+ nan@2.9.2
added 1 package in 3.181s
I get a strange 404 error which fails my npm install
command every time. Here's what I'm seeing:
$ npm install
> fsevents@1.1.2 install /Volumes/Storage/Code/stencil-app-starter/node_modules/fsevents
> node install
node-pre-gyp ERR! Tried to download(404): https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.2/fse-v1.1.2-node-v59-darwin-x64.tar.gz
node-pre-gyp ERR! Pre-built binaries not found for fsevents@1.1.2 and node@9.6.1 (node-v59 ABI) (falling back to source compile with node-gyp)
module.js:559
throw err;
^
Error: Cannot find module 'nan'
at Function.Module._resolveFilename (module.js:557:15)
at Function.Module._load (module.js:484:25)
at Module.require (module.js:606:17)
at require (internal/module.js:11:18)
at [eval]:1:1
at Script.runInThisContext (vm.js:65:33)
at Object.runInThisContext (vm.js:199:38)
at Object.<anonymous> ([eval]-wrapper:6:22)
at Module._compile (module.js:662:30)
at evalScript (bootstrap_node.js:522:27)
gyp: Call to 'node -e "require('nan')"' returned exit status 1 while in binding.gyp. while trying to load binding.gyp
I can confirm the download location for fsevents
returns a 404 error.
<?xml version="1.0" encoding="UTF-8"?>
<Error>
<Code>NoSuchKey</Code>
<Message>The specified key does not exist.</Message>
<Key>v1.1.2/fse-v1.1.2-node-v59-darwin-x64.tar.gz</Key>
<RequestId>31BC3AE57EE42EAA</RequestId>
<HostId>
Vd6yEcRcDMJTrsHCdrUrfpUGwrGaGBRbkd7GGuyn7MyB53Bx9iB4QS5EHHlHmOISw0YubaHFYAc=
</HostId>
</Error>
I don't know if my error is the same as @mutech and @ErikSchierboom as I'm getting an error that the nan
module cannot be found by node as well as a 404 error for the fsevents
file but either way it's not working for me.
@justinhartman Yes this is the same error I got. Sorry, I should have posted the details myself. The only way I found to fix the issue was to go back to node 9.3, which however was no problem for me.
Hello all! We recommend using the LTS version of Node. It looks like fsevents is not fully updated yet to be stable with all versions of Node 9. Thanks for using Stencil!
Also as a note, i added this to our docs site and pushed that live this morning.
Resources: Before submitting an issue, please consult our docs.
Stencil version: (run
npm list @stencil/core
from a terminal/cmd prompt and paste output below):I'm submitting a ... (check one with "x") [ x ] bug report [ ] feature request [ ] support request => Please do not submit support requests here, use one of these channels: https://forum.ionicframework.com/ or https://stencil-worldwide.slack.com
Current behavior: Running
npm install
after cloning this starter project fails on Node 9.3.0 and 9.4.0 on MacOS unless the packagenan
is installed globally (this in turn is needed to build fs-events).After calling 'npm install -g nan', npm install works on Node 9.3.0 but not on 9.4.0. On 9.4.0 installing 'nan' globally has no effect.
Expected behavior: npm install should succeed without requiring the installation of global NPM packages unless noted in the "Get Started" section.
Steps to reproduce: On macOS High Sierra with node 9.3.0 installed (I use nodenv to select different node versions), follow the steps from your "Get Started" documentation (clone the repo, cd into it, run npm install).
Related code:
Other information: