ecerroni / apollo-connector-kit

https://blog.mvp-space.com/authentication-and-authorization-boilerplate-with-apollo-2-0-b77042aba3f6
MIT License
113 stars 24 forks source link

yarn install-all not working #8

Closed Aervue closed 4 years ago

Aervue commented 5 years ago

Hi,

I am intrigued by your boilerplate and would like to customize it but I am running into the following errors during 'yarn install-all' step.

Win10 x64 VSCode GitBash node 10.15.3 yarn 1.16 npm 6.4.1

~/Desktop/apollo-boilerplate-test/apollo-connector-kit (master) yarn install-all
yarn run v1.16.0
$ yarn install && concurrently 'yarn:install-dev-*'
info No lockfile found.
[1/4] Resolving packages...
[2/4] Fetching packages...
[3/4] Linking dependencies...
[4/4] Building fresh packages...

success Saved lockfile.
$ cd backend && yarn install
$ cd frontend-vue && yarn install
$ cd frontend-react && yarn install
warning package.json: No license field
[1/4] Resolving packages...
[1/4] Resolving packages...
warning frontend-react@0.1.0: No license field
[1/4] Resolving packages...
[2/4] Fetching packages...
[2/4] Fetching packages...
info fsevents@1.2.8: The platform "win32" is incompatible with this module.
info "fsevents@1.2.8" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
warning " > apollo-server-module-operation-store@1.3.5" has incorrect peer dependency "graphql@^0.9.0 || ^0.10.1 || ^0.11.0 || ^0.12.0 || ^0.13.0".      
info fsevents@1.2.4: The platform "win32" is incompatible with this module.
info "fsevents@1.2.4" is an optional dependency and failed compatibility check. Excluding it from installation.
info fsevents@1.2.8: The platform "win32" is incompatible with this module.
info "fsevents@1.2.8" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
warning " > graphql-tag@2.8.0" has incorrect peer dependency "graphql@^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0".
warning " > eslint-plugin-react@7.12.4" has unmet peer dependency "eslint@^3.0.0 || ^4.0.0 || ^5.0.0".
warning " > eslint-config-airbnb@16.1.0" has unmet peer dependency "eslint@^4.9.0".
warning "eslint-config-airbnb > eslint-config-airbnb-base@12.1.0" has unmet peer dependency "eslint@^4.9.0".
warning " > eslint-config-prettier@2.10.0" has unmet peer dependency "eslint@>=3.14.1".
warning " > eslint-config-react-app@2.1.0" has unmet peer dependency "babel-eslint@^7.2.3".
warning " > eslint-config-react-app@2.1.0" has unmet peer dependency "eslint@^4.1.1".
warning " > eslint-config-react-app@2.1.0" has incorrect peer dependency "eslint-plugin-jsx-a11y@^5.1.1".
warning " > eslint-plugin-flowtype@2.50.3" has unmet peer dependency "eslint@>=2.0.0".
warning " > eslint-plugin-import@2.17.2" has unmet peer dependency "eslint@2.x - 5.x".
warning " > eslint-plugin-jsx-a11y@6.2.1" has unmet peer dependency "eslint@^3 || ^4 || ^5".
warning postcss-preset-env > postcss-color-functional-notation > postcss-values-parser > flatten@1.0.2: I wrote this module a very long time ago; you sho
uld use something else.
[2/4] Fetching packages...
info fsevents@1.2.8: The platform "win32" is incompatible with this module.
info "fsevents@1.2.8" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
[4/4] Building fresh packages...
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
error C:\Users\Aervue\Desktop\apollo-boilerplate-test\apollo-connector-kit\backend\node_modules\bcrypt: Command failed.
[install-dev-apollo] Exit code: 1
[install-dev-apollo] Command: node-pre-gyp install --fallback-to-build
[install-dev-apollo] Arguments:
[install-dev-apollo] Directory: C:\Users\Aervue\Desktop\apollo-boilerplate-test\apollo-connector-kit\backend\node_modules\bcrypt
[install-dev-apollo] Output:
[install-dev-apollo] node-pre-gyp info it worked if it ends with ok
[install-dev-apollo] node-pre-gyp info using node-pre-gyp@0.12.0
[install-dev-apollo] node-pre-gyp info using node@10.15.3 | win32 | x64
[install-dev-apollo] node-pre-gyp WARN Using request for node-pre-gyp https download
[install-dev-apollo] node-pre-gyp info check checked for "C:\Users\Aervue\Desktop\apollo-boilerplate-test\apollo-connector-kit\backend\node_modules\bcryp
t\lib\binding\bcrypt_lib.node" (not found)
[install-dev-apollo] node-pre-gyp http GET https://github.com/kelektiv/node.bcrypt.js/releases/download/v3.0.3/bcrypt_lib-v3.0.3-node-v64-win32-x64-unkno
wn.tar.gz
[install-dev-apollo] node-pre-gyp http 404 https://github.com/kelektiv/node.bcrypt.js/releases/download/v3.0.3/bcrypt_lib-v3.0.3-node-v64-win32-x64-unkno
wn.tar.gz
[install-dev-apollo] node-pre-gyp WARN Tried to download(404): https://github.com/kelektiv/node.bcrypt.js/releases/download/v3.0.3/bcrypt_lib-v3.0.3-node
-v64-win32-x64-unknown.tar.gz
[install-dev-apollo] node-pre-gyp WARN Pre-built binaries not found for bcrypt@3.0.3 and node@10.15.3 (node-v64 ABI, unknown) (falling back to source com
pile with node-gyp)
[install-dev-apollo] node-pre-gyp http 404 status code downloading tarball https://github.com/kelektiv/node.bcrypt.js/releases/download/v3.0.3/bcrypt_lib
-v3.0.3-node-v64-win32-x64-unknown.tar.gz
[install-dev-apollo]
[install-dev-apollo] C:\Users\Aervue\Desktop\apollo-boilerplate-test\apollo-connector-kit\backend\node_modules\bcrypt>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" clean )  else (node "" clean )
[install-dev-apollo] gyp info it worked if it ends with ok
[install-dev-apollo] gyp info using node-gyp@3.8.0
[install-dev-apollo] gyp info using node@10.15.3 | win32 | x64
[install-dev-apollo] gyp info ok
[install-dev-apollo]
[install-dev-apollo] C:\Users\Aervue\Desktop\apollo-boilerplate-test\apollo-connector-kit\backend\node_modules\bcrypt>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" configure --fallback-to-build --module=C:\
Users\Aervue\Desktop\apollo-boilerplate-test\apollo-connector-kit\backend\node_modules\bcrypt\lib\binding\bcrypt_lib.node --module_name=bcrypt_lib --modu
le_path=C:\Users\Aervue\Desktop\apollo-boilerplate-test\apollo-connector-kit\backend\node_modules\bcrypt\lib\binding --napi_version=3 --node_abi_napi=nap
i --napi_build_version=0 --node_napi_label=node-v64 )  else (node "" configure --fallback-to-build --module=C:\Users\Aervue\Desktop\apollo-boilerplate-te
st\apollo-connector-kit\backend\node_modules\bcrypt\lib\binding\bcrypt_lib.node --module_name=bcrypt_lib --module_path=C:\Users\Aervue\Desktop\apollo-boi
lerplate-test\apollo-connector-kit\backend\node_modules\bcrypt\lib\binding --napi_version=3 --node_abi_napi=napi --napi_build_version=0 --node_napi_label
=node-v64 )
[install-dev-apollo] gyp info it worked if it ends with ok
[install-dev-apollo] gyp info using node-gyp@3.8.0
[install-dev-apollo] gyp info using node@10.15.3 | win32 | x64
[install-dev-apollo] gyp ERR! configure error
[install-dev-apollo] gyp ERR! stack Error: Can't find Python executable "python", you can set the PYTHON env variable.
[install-dev-apollo] gyp ERR! stack     at PythonFinder.failNoPython (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\configure.js:484
:19)
[install-dev-apollo] gyp ERR! stack     at PythonFinder.<anonymous> (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\configure.js:509:
16)
[install-dev-apollo] gyp ERR! stack     at C:\Program Files\nodejs\node_modules\npm\node_modules\graceful-fs\polyfills.js:284:29
[install-dev-apollo] gyp ERR! stack     at FSReqWrap.oncomplete (fs.js:153:21)
[install-dev-apollo] gyp ERR! System Windows_NT 10.0.18362
[install-dev-apollo] gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\bin\\n
ode-gyp.js" "configure" "--fallback-to-build" "--module=C:\\Users\\Aervue\\Desktop\\apollo-boilerplate-test\\apollo-connector-kit\\backend\\node_modules\
\bcrypt\\lib\\binding\\bcrypt_lib.node" "--module_name=bcrypt_lib" "--module_path=C:\\Users\\Aervue\\Desktop\\apollo-boilerplate-test\\apollo-connector-k
it\\backend\\node_modules\\bcrypt\\lib\\binding" "--napi_version=3" "--node_abi_napi=napi" "--napi_build_version=0" "--node_napi_label=node-v64"
[install-dev-apollo] gyp ERR! cwd C:\Users\Aervue\Desktop\apollo-boilerplate-test\apollo-connector-kit\backend\node_modules\bcrypt
[install-dev-apollo] gyp ERR! node -v v10.15.3
[install-dev-apollo] gyp ERR! node-gyp -v v3.8.0
[install-dev-apollo] gyp ERR! not ok
[install-dev-apollo] node-pre-gyp ERR! build error
[install-dev-apollo] node-pre-gyp ERR! stack Error: Failed to execute 'node-gyp.cmd configure --fallback-to-build --module=C:\Users\Aervue\Desktop\apollo
-boilerplate-test\apollo-connector-kit\backend\node_modules\bcrypt\lib\binding\bcrypt_lib.node --module_name=bcrypt_lib --module_path=C:\Users\Aervue\Des
ktop\apollo-boilerplate-test\apollo-connector-kit\backend\node_modules\bcrypt\lib\binding --napi_version=3 --node_abi_napi=napi --napi_build_version=0 --
node_napi_label=node-v64' (1)
[install-dev-apollo] node-pre-gyp ERR! stack     at ChildProcess.<anonymous> (C:\Users\Aervue\Desktop\apollo-boilerplate-test\apollo-connector-kit\backen
d\node_modules\node-pre-gyp\lib\util\compile.js:83:29)
[install-dev-apollo] node-pre-gyp ERR! stack     at ChildProcess.emit (events.js:189:13)
[install-dev-apollo] node-pre-gyp ERR! stack     at maybeClose (internal/child_process.js:970:16)
[install-dev-apollo] node-pre-gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:259:5)
[install-dev-apollo] node-pre-gyp ERR! System Windows_NT 10.0.18362
[install-dev-apollo] node-pre-gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\Aervue\\Desktop\\apollo-boilerplate-test\\apollo-connect
or-kit\\backend\\node_modules\\node-pre-gyp\\bin\\node-pre-gyp" "install" "--fallback-to-build"
[install-dev-apollo] node-pre-gyp ERR! cwd C:\Users\Aervue\Desktop\apollo-boilerplate-test\apollo-connector-kit\backend\node_modules\bcrypt
[install-dev-apollo] node-pre-gyp ERR! node -v v10.15.3
[install-dev-apollo] node-pre-gyp ERR! node-pre-gyp -v v0.12.0
[install-dev-apollo] node-pre-gyp ERR! not ok
[install-dev-apollo] Failed to execute 'node-gyp.cmd configure --fallback-to-build --module=C:\Users\Aervue\Desktop\apollo-boilerplate-test\apollo-connec
tor-kit\backend\node_modules\bcrypt\lib\binding\bcrypt_lib.node --module_name=bcrypt_lib --module_path=C:\Users\Aervue\Desktop\apollo-boilerplate-test\ap
ollo-connector-kit\backend\node_modules\bcrypt\lib\binding --napi_version=3 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v64' (1)  
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
error Command failed with exit code 1.
[install-dev-apollo] yarn run install-dev-apollo exited with code 1
[4/4] Building fresh packages...
[4/4] Building fresh packages...
success Saved lockfile.
[install-dev-vue] yarn run install-dev-vue exited with code 0
$ ln -sfn $(dirname $(pwd))/settings './src/settings'
[install-dev-react] ln: target './src/settings' is not a directory
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
[install-dev-react] error Command failed with exit code 1.
[install-dev-react] yarn run install-dev-react exited with code 1
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
ecerroni commented 5 years ago

It seems an issue related to the Windows platform. We do not use Windows in our team so I cannot help here.

It is about bcrypt@3.0.3 on Windows. I google it and these 2 links are related to your issue and might be of help: https://stackoverflow.com/questions/54201658/how-to-install-bcrypt-on-windows-10 https://superuser.com/questions/1389053/bcrypt3-0-3-install-node-pre-gyp-install-fallback-to-build-bcrypt-3-0-3

I'd also suggest trying to pin down the bycypt to 3.0.0 version in the backend's package.json. Then remove yarn.lock and node_modules from 1backendfolder and runyarn install-all` from project root again.

ecerroni commented 4 years ago

Closing due to inactivity. Feel free to reopen if you're still looking for a solution.