Hi I always get the following error while creating typescript based react project, and the project gets created with .js files instead.
I have tried to reinstall the create-react-app utility but did not work.
> node-pre-gyp ERR! Tried to download(404): https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.0.17/fse-v1.0.17-node-v57-darwin-x64.tar.gz
node-pre-gyp ERR! Pre-built binaries not found for fsevents#1.0.17 and node#8.6.0 (node-v57 ABI) (falling back to source compile with node-gyp) > gyp ERR! configure error
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack at ChildProcess.onCpExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:336:16)
gyp ERR! stack at emitTwo (events.js:125:13)
gyp ERR! stack at ChildProcess.emit (events.js:213:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
gyp ERR! System Darwin 18.0.0
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "configure" "--fallback-to-build" "--module=/Users/mpant/my-app/node_modules/fsevents/lib/binding/Release/node-v57-darwin-x64/fse.node" "--module_name=fse" "--module_path=/Users/mpant/my-app/node_modules/fsevents/lib/binding/Release/node-v57-darwin-x64"
gyp ERR! cwd /Users/mpant/my-app/node_modules/fsevents
gyp ERR! node -v v8.6.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
node-pre-gyp ERR! build error
node-pre-gyp ERR! stack Error: Failed to execute '/usr/local/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js configure --fallback-to-build --module=/Users/mpant/my-app/node_modules/fsevents/lib/binding/Release/node-v57-darwin-x64/fse.node --module_name=fse --module_path=/Users/mpant/my-app/node_modules/fsevents/lib/binding/Release/node-v57-darwin-x64' (1)
node-pre-gyp ERR! stack at ChildProcess.<anonymous> (/Users/mpant/my-app/node_modules/fsevents/node_modules/node-pre-gyp/lib/util/compile.js:83:29)
node-pre-gyp ERR! stack at emitTwo (events.js:125:13)
node-pre-gyp ERR! stack at ChildProcess.emit (events.js:213:7)
node-pre-gyp ERR! stack at maybeClose (internal/child_process.js:927:16)
node-pre-gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5)
node-pre-gyp ERR! System Darwin 18.0.0
node-pre-gyp ERR! command "/usr/local/bin/node" "/Users/mpant/my-app/node_modules/fsevents/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build"
node-pre-gyp ERR! cwd /Users/mpant/my-app/node_modules/fsevents
node-pre-gyp ERR! node -v v8.6.0
node-pre-gyp ERR! node-pre-gyp -v v0.6.32
node-pre-gyp ERR! not ok
Try updating your local create-react-app version to >=2.1
npm update -g create-react-app
Then create your react app with typescript using below command.
create-react-app my-app --typescript
Note : using npx has a conflict with the global version of installed create-react-app. You can also try clearing your npm cache.
Related
I have created a new Angular project and I ran npm i.
As soon as I did that, some installs were successful until I got the following error on my Terminal.
I have already uninstalled node-gyp and re-installed.
node-pre-gyp WARN Pre-built binaries not installable for fsevents#1.2.9 and node#12.5.0 (node-v72 ABI, unknown) (falling back to source compile with node-gyp)
node-pre-gyp WARN Hit error EACCES: permission denied, mkdir '/Users/isaac/Desktop/Tutorials/Angular/ng-refresher/node_modules/fsevents/lib'
gyp ERR! configure error
gyp ERR! stack Error: EACCES: permission denied, mkdir '/Users/isaac/Desktop/Tutorials/Angular/ng-refresher/node_modules/fsevents/build'
gyp ERR! System Darwin 18.0.0
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "configure" "--fallback-to-build" "--module=/Users/isaac/Desktop/Tutorials/Angular/ng-refresher/node_modules/fsevents/lib/binding/Release/node-v72-darwin-x64/fse.node" "--module_name=fse" "--module_path=/Users/isaac/Desktop/Tutorials/Angular/ng-refresher/node_modules/fsevents/lib/binding/Release/node-v72-darwin-x64" "--napi_version=4" "--node_abi_napi=napi" "--napi_build_version=0" "--node_napi_label=node-v72"
gyp ERR! cwd /Users/isaac/Desktop/Tutorials/Angular/ng-refresher/node_modules/fsevents
gyp ERR! node -v v12.5.0
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
node-pre-gyp ERR! build error
node-pre-gyp ERR! stack Error: Failed to execute '/usr/local/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js configure --fallback-to-build --module=/Users/isaac/Desktop/Tutorials/Angular/ng-refresher/node_modules/fsevents/lib/binding/Release/node-v72-darwin-x64/fse.node --module_name=fse --module_path=/Users/isaac/Desktop/Tutorials/Angular/ng-refresher/node_modules/fsevents/lib/binding/Release/node-v72-darwin-x64 --napi_version=4 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v72' (1)
node-pre-gyp ERR! stack at ChildProcess.<anonymous> (/Users/isaac/Desktop/Tutorials/Angular/ng-refresher/node_modules/fsevents/node_modules/node-pre-gyp/lib/util/compile.js:83:29)
node-pre-gyp ERR! stack at ChildProcess.emit (events.js:200:13)
node-pre-gyp ERR! stack at maybeClose (internal/child_process.js:1021:16)
node-pre-gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:283:5)
node-pre-gyp ERR! System Darwin 18.0.0
node-pre-gyp ERR! command "/usr/local/bin/node" "/Users/isaac/Desktop/Tutorials/Angular/ng-refresher/node_modules/fsevents/node_modules/node-pre-gyp/bin/node-pre-gyp" "install" "--fallback-to-build"
node-pre-gyp ERR! cwd /Users/isaac/Desktop/Tutorials/Angular/ng-refresher/node_modules/fsevents
node-pre-gyp ERR! node -v v12.5.0
node-pre-gyp ERR! node-pre-gyp -v v0.12.0
node-pre-gyp ERR! not ok
Failed to execute '/usr/local/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js configure --fallback-to-build --module=/Users/isaac/Desktop/Tutorials/Angular/ng-refresher/node_modules/fsevents/lib/binding/Release/node-v72-darwin-x64/fse.node --module_name=fse --module_path=/Users/isaac/Desktop/Tutorials/Angular/ng-refresher/node_modules/fsevents/lib/binding/Release/node-v72-darwin-x64 --napi_version=4 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v72' (1)
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#1.2.9 (node_modules/fsevents):
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#1.2.9 install: `node install`
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: Exit status 1
I was hoping for npm i to run smoothly, but instead, I received that error.
Your project uses (probably indirectly) a native module. Since it doesn't have a pre-built module for the combination of your OS and Node version, npm attempts to build it locally. It eventually fails with this error:
gyp ERR! stack Error: EACCES: permission denied, mkdir '/Users/isaac/Desktop/Tutorials/Angular/ng-refresher/node_modules/fsevents/build'
Make sure the user you're using to run npm install has the permissions to create that directory, and rerun npm install.
I've tried my best to get Botium to work with BDD so I can see if its useful but the only BDD example I've come across is this https://github.com/codeforequity-at/botium-bdd-samples/
But I'm unable to install the dependencies with NPM install so I was wondering if its possible to get Botium to work with cucumber for java on intellij?
I've tried to install botium with the js example but I continue to get errors with NPM
gyp ERR! build error
gyp ERR! stack Error: `C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\MSBuild.exe` failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\build.js:262:23)
gyp ERR! stack at ChildProcess.emit (events.js:189:13)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:248:12)
gyp ERR! System Windows_NT 10.0.16299
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "build" "--fallback-to-build" "--library=static_library" "--module=C:\\Users\\sahmed248\\IdeaProjects\\botium-bdd-samples\\node_modules\\grpc\\src\\node\\extension_binary\\node-v64-win32-x64-unknown\\grpc_node.node" "--module_name=grpc_node" "--module_path=C:\\Users\\sahmed248\\IdeaProjects\\botium-bdd-samples\\node_modules\\grpc\\src\\node\\extension_binary\\node-v64-win32-x64-unknown"
gyp ERR! cwd C:\Users\sahmed248\IdeaProjects\botium-bdd-samples\node_modules\grpc
gyp ERR! node -v v10.15.3
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
node-pre-gyp ERR! build error
node-pre-gyp ERR! stack Error: Failed to execute 'C:\Program Files\nodejs\node.exe C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js build --fallback-to-build --library=static_library --module=C:\Users\sahmed248\IdeaProjects\botium-bdd-samples\node_modules\grpc\src\node\extension_binary\node-v64-win32-x64-unknown\grpc_node.node --module_name=grpc_node --module_path=C:\Users\sahmed248\IdeaProjects\botium-bdd-samples\node_modules\grpc\src\node\extension_binary\node-v64-win32-x64-unknown' (1)
node-pre-gyp ERR! stack at ChildProcess.<anonymous> (C:\Users\sahmed248\IdeaProjects\botium-bdd-samples\node_modules\grpc\node_modules\node-pre-gyp\lib\util\compile.js:83:29)
node-pre-gyp ERR! stack at ChildProcess.emit (events.js:189:13)
node-pre-gyp ERR! stack at maybeClose (internal/child_process.js:970:16)
node-pre-gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:259:5)
node-pre-gyp ERR! System Windows_NT 10.0.16299
node-pre-gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\sahmed248\\IdeaProjects\\botium-bdd-samples\\node_modules\\grpc\\node_modules\\node-pre-gyp\\bin\\node-pre-gyp" "install" "--fallback-to-build" "--library=static_library"
node-pre-gyp ERR! cwd C:\Users\sahmed248\IdeaProjects\botium-bdd-samples\node_modules\grpc
node-pre-gyp ERR! node -v v10.15.3
node-pre-gyp ERR! node-pre-gyp -v v0.6.39
node-pre-gyp ERR! not ok
If anyone is able to either help me solve the issue with NPM or explain how to use Botium with cucumber for Java that would be helpful.
Botium Core is a Node.js library, so using it with Java is tricky, but not impossible: Botium supports a special "Grid mode", where it runs in the background and exposes a HTTP/JSON interface - see here for more info.
For your installation problem, here some hints what you can try - obviously the node-gyp package fails:
* remove the node_modules folder and the package-lock.json file and run npm install again
* run "npm install -g node-gyp" with admin privileges
* run "npm install -g windows-build-tools" with admin privileges
(see https://github.com/nodejs/node-gyp)
I'm trying to link my firebase on my react.js app (I also use Redux).
I installed react-rebase and in my file base.js I'm trying to import Rebase from 're-base' (as in the doc https://www.npmjs.com/package/react-rebase). But, when I start my app, I have this error "Can't resolve 're-base'" and I don't understand why...
Could you help me please ?
Thanks and sorry for English mistakes
edit : when I tried to install directly re-base, I have errors and this is the debug.log
node-pre-gyp ERR! Pre-built binaries not installable for grpc#1.10.1 and node#8.9.4 (node-v57 ABI, unknown) (falling back to source compile with node-gyp)
node-pre-gyp ERR! Hit error self signed certificate in certificate chain
gyp ERR! configure error
gyp ERR! stack Error: Can't find Python executable "python", you can set the PYTHON env variable.
gyp ERR! stack at PythonFinder.failNoPython (C:\Users\username\AppData\Roaming\npm\node_modules\npm\node_modules\npm-lifecycle\node_modules\node-gyp\lib\configure.js:483:19)
gyp ERR! stack at PythonFinder.<anonymous> (C:\Users\username\AppData\Roaming\npm\node_modules\npm\node_modules\npm-lifecycle\node_modules\node-gyp\lib\configure.js:508:16)
gyp ERR! stack at C:\Users\username\AppData\Roaming\npm\node_modules\npm\node_modules\graceful-fs\polyfills.js:284:29
gyp ERR! stack at FSReqWrap.oncomplete (fs.js:152:21)
gyp ERR! System Windows_NT 10.0.16299
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\User\\username\\AppData\\Roaming\\npm\\node_modules\\npm\\node_modules\\npm-lifecycle\\node_modules\\node-gyp\\bin\\node-gyp.js" "configure" "--fallback-to-build" "--library=static_library" "--module=C:\\Users\\username\\node_modules\\grpc\\src\\node\\extension_binary\\node-v57-win32-x64-unknown\\grpc_node.node" "--module_name=grpc_node" "--module_path=C:\\Users\\username\\node_modules\\grpc\\src\\node\\extension_binary\\node-v57-win32-x64-unknown"
gyp ERR! cwd C:\Users\username\node_modules\grpc
gyp ERR! node -v v8.9.4
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
node-pre-gyp ERR! build error
node-pre-gyp ERR! stack Error: Failed to execute 'C:\Program Files\nodejs\node.exe C:\Users\username\AppData\Roaming\npm\node_modules\npm\node_modules\npm-lifecycle\node_modules\node-gyp\bin\node-gyp.js configure --fallback-to-build --library=static_library --module=C:\Users\username\node_modules\grpc\src\node\extension_binary\node-v57-win32-x64-unknown\grpc_node.node --module_name=grpc_node --module_path=C:\Users\username\node_modules\grpc\src\node\extension_binary\node-v57-win32-x64-unknown' (1)
node-pre-gyp ERR! stack at ChildProcess.<anonymous> (C:\Users\username\node_modules\grpc\node_modules\node-pre-gyp\lib\util\compile.js:83:29)
node-pre-gyp ERR! stack at emitTwo (events.js:126:13)
node-pre-gyp ERR! stack at ChildProcess.emit (events.js:214:7)
node-pre-gyp ERR! stack at maybeClose (internal/child_process.js:925:16)
node-pre-gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)
node-pre-gyp ERR! System Windows_NT 10.0.16299
node-pre-gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\username\\node_modules\\grpc\\node_modules\\node-pre-gyp\\bin\\node-pre-gyp" "install" "--fallback-to-build" "--library=static_library"
node-pre-gyp ERR! cwd C:\Users\username\node_modules\grpc
node-pre-gyp ERR! node -v v8.9.4
node-pre-gyp ERR! node-pre-gyp -v v0.7.0
node-pre-gyp ERR! not ok
Failed to execute 'C:\Program Files\nodejs\node.exe C:\Users\username\AppData\Roaming\npm\node_modules\npm\node_modules\npm-lifecycle\node_modules\node-gyp\bin\node-gyp.js configure --fallback-to-build --library=static_library --module=C:\Users\username\node_modules\grpc\src\node\extension_binary\node-v57-win32-x64-unknown\grpc_node.node --module_name=grpc_node --module_path=C:\Users\username\node_modules\grpc\src\node\extension_binary\node-v57-win32-x64-unknown' (1)
npm WARN enoent ENOENT: no such file or directory, open 'C:\Users\username\package.json'
npm WARN react-router#4.2.0 requires a peer of react#>=15 but none is installed. You must install peer dependencies yourself.
npm WARN react-router-dom#4.2.2 requires a peer of react#>=15 but none is installed. You must install peer dependencies yourself.
npm WARN #firebase/firestore#0.3.7 requires a peer of #firebase/app#^0.1.0 but none is installed. You must install peer dependencies yourself.
npm WARN #firebase/firestore#0.3.7 requires a peer of #firebase/app-types#^0.1.0 but none is installed. You must install peer dependencies yourself.
npm WARN #firebase/firestore-types#0.2.2 requires a peer of #firebase/app-types#^0.1.0 but none is installed. You must install peer dependencies yourself.
npm WARN username No description
npm WARN username No repository field.
npm WARN username No README data
npm WARN username No license field.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! grpc#1.10.1 install: `node-pre-gyp install --fallback-to-build --library=static_library`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the grpc#1.10.1 install 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! C:\Users\username\AppData\Roaming\npm-cache\_logs\2018-03-31T17_26_29_575Z-debug.log
Why is there a dependency of installing Cairo for using Canvas/ChartJS? I am using OSX / Mac. I am running into issues which installing this project for Charts. I have seen some stackoverflow threads where the resolution is to install the system level libraries of Cairo.
https://github.com/jerairrest/react-chartjs-2
> canvas#1.6.7 install /Users/rjain/code/react-chartjs-2/node_modules/canvas
> node-gyp rebuild
Package cairo was not found in the pkg-config search path.
Perhaps you should add the directory containing `cairo.pc'
to the PKG_CONFIG_PATH environment variable
No package 'cairo' found
gyp: Call to './util/has_lib.sh freetype' returned exit status 0 while in binding.gyp. while trying to load binding.gyp
gyp ERR! configure error
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack at ChildProcess.onCpExit (/Users/rjain/.config/fnm/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:336:16)
gyp ERR! stack at emitTwo (events.js:125:13)
gyp ERR! stack at ChildProcess.emit (events.js:213:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
gyp ERR! System Darwin 17.0.0
gyp ERR! command "/Users/rjain/.config/fnm/bin/node" "/Users/rjain/.config/fnm/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/rjain/code/react-chartjs-2/node_modules/canvas
gyp ERR! node -v v8.6.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm WARN react-chartjs-2#2.6.4 No license field.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! canvas#1.6.7 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the canvas#1.6.7 install 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! /Users/rjain/.npm/_logs/2017-10-11T21_53_41_819Z-debug.log
enter image description here
first i run npm install -g ts-node
then i run npm install which gives me following error...no idea what to do..
when i run it by npm start ... it gives me more errors of gulp server or something
C:\Users\Raheel\Downloads\SB-Admin-BS4-Angular-2-master\SB-Admin-BS4-Angular-2-master\node_modules\c3\node_modules\d3\node_modules\jsdom\node_modules\contextify>if not defined npm_config_node_gyp (node "C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild ) else (node "" rebuild )
gyp ERR! configure error
gyp ERR! stack Error: Python executable "C:\Users\Raheel\AppData\Local\Programs\Python\Python35-32\python.EXE" is v3.5.1, which is not supported by gyp.
gyp ERR! stack You can pass the --python switch to point to Python >= v2.5.0 & < 3.0.0.
gyp ERR! stack at failPythonVersion (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\configure.js:406:14)
gyp ERR! stack at C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\configure.js:395:9
gyp ERR! stack at ChildProcess.exithandler (child_process.js:204:7)
gyp ERR! stack at emitTwo (events.js:87:13)
gyp ERR! stack at ChildProcess.emit (events.js:172:7)
gyp ERR! stack at maybeClose (internal/child_process.js:827:16)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5)
gyp ERR! System Windows_NT 6.1.7601
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd C:\Users\Raheel\Downloads\SB-Admin-BS4-Angular-2-master\SB-Admin-BS4-Angular-2-master\node_modules\c3\node_modules\d3\node_modules\jsdom\node_modules\contextify
gyp ERR! node -v v4.4.3
gyp ERR! node-gyp -v v3.3.1
gyp ERR! not ok
npm ERR! Windows_NT 6.1.7601
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\
node_modules\\npm\\bin\\npm-cli.js" "install"
npm ERR! node v4.4.3
npm ERR! npm v2.15.1
npm ERR! code ELIFECYCLE
npm ERR! contextify#0.1.15 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the contextify#0.1.15 install script 'node-gyp rebuild'.
npm ERR! This is most likely a problem with the contextify package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs contextify
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!
npm ERR! npm owner ls contextify
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! C:\Users\Raheel\Downloads\SB-Admin-BS4-Angular-2-master\SB-Admin-BS4-Angular-2-master\npm-debug.log
C:\Users\Raheel\Downloads\SB-Admin-BS4-Angular-2-master\SB-Admin-BS4-Angular-2-m
aster>
In the first lines you can read :
Error: Python executable "C:\Users\Raheel\AppData\Local\Programs\Python\Python35-32\python.EXE" is v3.5.1, which is not supported by gyp.
Check that you have python 2.5 installed, seems like npm can't use python 3.x
If I'm not wrong, you need a python version which is 2.5 or higher but lower than 3.0.
Check npm doc for more.