Can't create first app ... node-sass error


#1

Hi there,

I started with NativeScript today by setting up all that is needed incl. Sidekick. When I select to create an app via sidekick I keep receiving the following error message:

[17-11-27 20:19:19.728] (Error) Command npm.cmd install failed with exit code 1 Error output: 
 Cannot download "https://github.com/sass/node-sass/releases/download/v4.5.3/win32-x64-59_binding.node": 

HTTP error 404 Not Found

Hint: If github.com is not accessible in your location
      try setting a proxy via HTTP_PROXY, e.g. 

      export HTTP_PROXY=http://example.com:1234

or configure npm proxy via

      npm config set proxy http://example.com:8080
gyp info it worked if it ends with ok
gyp verb cli [ 'C:\\Program Files\\nodejs\\node.exe',
gyp verb cli   'W:\\Ben\\App Entwicklung\\NativeScript\\Kommitaree\\node_modules\\node-gyp\\bin\\node-gyp.js',
gyp verb cli   'rebuild',
gyp verb cli   '--verbose',
gyp verb cli   '--libsass_ext=',
gyp verb cli   '--libsass_cflags=',
gyp verb cli   '--libsass_ldflags=',
gyp verb cli   '--libsass_library=' ]
gyp info using node-gyp@3.6.2
gyp info using node@9.2.0 | win32 | x64
gyp verb command rebuild []
gyp verb command clean []
gyp verb clean removing "build" directory
gyp verb command configure []
gyp verb check python checking for Python executable "python2" in the PATH
gyp verb `which` failed Error: not found: python2
gyp verb `which` failed     at getNotFoundError (W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\which\which.js:13:12)
gyp verb `which` failed     at F (W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\which\which.js:68:19)
gyp verb `which` failed     at E (W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\which\which.js:80:29)
gyp verb `which` failed     at W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\which\which.js:89:16
gyp verb `which` failed     at W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\isexe\index.js:42:5
gyp verb `which` failed     at W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\isexe\windows.js:36:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:166:21)
gyp verb `which` failed  python2 { Error: not found: python2
gyp verb `which` failed     at getNotFoundError (W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\which\which.js:13:12)
gyp verb `which` failed     at F (W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\which\which.js:68:19)
gyp verb `which` failed     at E (W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\which\which.js:80:29)
gyp verb `which` failed     at W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\which\which.js:89:16
gyp verb `which` failed     at W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\isexe\index.js:42:5
gyp verb `which` failed     at W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\isexe\windows.js:36:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:166:21)
gyp verb `which` failed   stack: 'Error: not found: python2\n    at getNotFoundError (W:\\Ben\\App Entwicklung\\NativeScript\\Kommitaree\\node_modules\\which\\which.js:13:12)\n    at F (W:\\Ben\\App Entwicklung\\NativeScript\\Kommitaree\\node_modules\\which\\which.js:68:19)\n    at E (W:\\Ben\\App Entwicklung\\NativeScript\\Kommitaree\\node_modules\\which\\which.js:80:29)\n    at W:\\Ben\\App Entwicklung\\NativeScript\\Kommitaree\\node_modules\\which\\which.js:89:16\n    at W:\\Ben\\App Entwicklung\\NativeScript\\Kommitaree\\node_modules\\isexe\\index.js:42:5\n    at W:\\Ben\\App Entwicklung\\NativeScript\\Kommitaree\\node_modules\\isexe\\windows.js:36:5\n    at FSReqWrap.oncomplete (fs.js:166:21)',
gyp verb `which` failed   code: 'ENOENT' }
gyp verb check python checking for Python executable "python" in the PATH
gyp verb `which` failed Error: not found: python
gyp verb `which` failed     at getNotFoundError (W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\which\which.js:13:12)
gyp verb `which` failed     at F (W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\which\which.js:68:19)
gyp verb `which` failed     at E (W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\which\which.js:80:29)
gyp verb `which` failed     at W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\which\which.js:89:16
gyp verb `which` failed     at W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\isexe\index.js:42:5
gyp verb `which` failed     at W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\isexe\windows.js:36:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:166:21)
gyp verb `which` failed  python { Error: not found: python
gyp verb `which` failed     at getNotFoundError (W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\which\which.js:13:12)
gyp verb `which` failed     at F (W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\which\which.js:68:19)
gyp verb `which` failed     at E (W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\which\which.js:80:29)
gyp verb `which` failed     at W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\which\which.js:89:16
gyp verb `which` failed     at W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\isexe\index.js:42:5
gyp verb `which` failed     at W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\isexe\windows.js:36:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:166:21)
gyp verb `which` failed   stack: 'Error: not found: python\n    at getNotFoundError (W:\\Ben\\App Entwicklung\\NativeScript\\Kommitaree\\node_modules\\which\\which.js:13:12)\n    at F (W:\\Ben\\App Entwicklung\\NativeScript\\Kommitaree\\node_modules\\which\\which.js:68:19)\n    at E (W:\\Ben\\App Entwicklung\\NativeScript\\Kommitaree\\node_modules\\which\\which.js:80:29)\n    at W:\\Ben\\App Entwicklung\\NativeScript\\Kommitaree\\node_modules\\which\\which.js:89:16\n    at W:\\Ben\\App Entwicklung\\NativeScript\\Kommitaree\\node_modules\\isexe\\index.js:42:5\n    at W:\\Ben\\App Entwicklung\\NativeScript\\Kommitaree\\node_modules\\isexe\\windows.js:36:5\n    at FSReqWrap.oncomplete (fs.js:166:21)',
gyp verb `which` failed   code: 'ENOENT' }
gyp verb could not find "python". checking python launcher 
gyp verb could not find "python". guessing location 
gyp verb ensuring that file exists: C:\Python27\python.exe
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 (W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\node-gyp\lib\configure.js:483:19)
gyp ERR! stack     at PythonFinder.<anonymous> (W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\node-gyp\lib\configure.js:508:16)
gyp ERR! stack     at W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\graceful-fs\polyfills.js:284:29
gyp ERR! stack     at FSReqWrap.oncomplete (fs.js:166:21)
gyp ERR! System Windows_NT 6.1.7601
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "W:\\Ben\\App Entwicklung\\NativeScript\\Kommitaree\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
gyp ERR! cwd W:\Ben\App Entwicklung\NativeScript\Kommitaree\node_modules\node-sass
gyp ERR! node -v v9.2.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok 
Build failed with error code: 1
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! node-sass@4.5.3 postinstall: `node scripts/build.js`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the node-sass@4.5.3 postinstall 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\Schmidts\AppData\Roaming\npm-cache\_logs\2017-11-27T19_11_15_324Z-debug.log
, Error: Command npm.cmd install failed with exit code 1 Error output:

I have seen this post and I also tried the following:

  1. download the file manually and copy to npm-cache - did not work
  2. download the file manually and install manually via npm npm install node-sas --sass-binary-path="c:\Temp\win32-x64-48_binding.node" - did not work

So … I have absolutely no clue what to do next to eventually start developing with NS : (

Thanks for your help in advance
BEN


#2

Can you try cleaning your cache (npm cache clean) and re-trying the install?


#3

Hi,
Thanks for your reply!

yes, I will clean the cache but what exactly do you mean by “re-trying the install”?
Shall I do what I mentioned under item 2) above?
–> download the file manually and install manually via npm npm install node-sas --sass-binary-path="c:\Temp\win32-x64-48_binding.node"

Greetings,
BEN


#4

This is driving me crazy!

Here is what I did and what happened…

npm cache clean --force

and then

npm install node-sas --sass-binary-path="c:\Temp\win32-x64-48_binding.node"

got an error referring to missing python and resolved that error by installing python and then
got an error on missing package.json and resolved that error by running

npm init

and then got another error saying

the build tools for visual studio 2010 (Platform Toolset = 'v100') cannot be found

which I tried to resolve with using

npm update --msvs_version=2013

but it did not work out and I received the error again. Found out that --msvs_version should be 2015 and then I tried

npm install node-sass --msvs_version=2015 --sass-binary-path="c:\Temp\win32-x64-48_binding.node"

This did the trick and the command ran successfully.

BUT then again I tried to create my first(!!!) app via Sidekick and again ran into the error:

Cannot download "https://github.com/sass/node-sass/releases/download/v4.5.3/win32-x64-59_binding.node": 

What the hell? Can you help me, please
?


#5

Looks like permissions issue.
Did you try installing it using command prompt running in administrator mode?
Also is your internet having any restrictions? Do you use a proxy?


#6

Hi,

yes, command prompt runs in admin mode … no, there are no issues with my internet … and no, there is no proxy

It appears as if I’d have to start from scratch, right?
Does anyone have an idea what I’d need to do in order to start “as clean as possible”? What would I have to deinstall?

Thanks for help guys! I highly appreciate!


#7

Also … I don’t understand why the “create” procedure insists on downloading win32-x64-59_binding.node … I managed to install it already (with blood, sweat and tears … as the above story shows) and there is no need to do that

Is there a way to circumvent the call to download / install win32-x64-59_binding.node again?


#8

I would recommend installing
Nvm for windows.
Please do google about it once.


#9

I installed nvm and did nvm install latest where I was told to already have the latest version (9.2.0).
Next I tried the create process with Sidekick again and then I was told that I need to downgrade to version 8 or lower. So I uninstalled version 9.2.0 and instead installed 8.8.1. But then the create process in Sidekick ended with an error again. A different one this time :persevere: “Communication with ChildProcess ended” (or similar)

I am going nuts!

Last thing I will try is to rollback and try to clean as far as possible and then start all over again.:roll_eyes:


#10

uninstall your regular installation of node before you install nvm.
also don’t use nvm install latest {N} is not ready for node 9 yet,
use nvm install 8 to install latest version of node 8


#11

Hi there,

my story continues :roll_eyes:
After a complete reinstall following each step from this list. Successfully! Yeah! :smiley: No error messages on the way and finally tns doctor reported “no issues”.

But wait … I (re-installed) Sidekick, clicked on “Create” and … got an error :persevere:

(Error) Communication with the child process was ended.

What the hell?!?!


#12

You can visit


Click on templates tab, choose a starter template
And copy the command to create that project via cli.

Once you do that, you can open up that project via side kick and still use the other features of side kick.

Btw. Did you try running side kick in administrator mode?