Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gyp verb which failed Error: not found: python2 #321

Closed
holyorb2 opened this issue Aug 26, 2018 · 4 comments
Closed

gyp verb which failed Error: not found: python2 #321

holyorb2 opened this issue Aug 26, 2018 · 4 comments

Comments

@holyorb2
Copy link

holyorb2 commented Aug 26, 2018

package.json

"devDependencies": {
    "gulp": "^3.9.1",
    "gulp-sass": "~2.3.1"
  }

Result

warning gulp-notify > [email protected]: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5
warning gulp-sass > [email protected]: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5
warning gulp-strip-css-comments > [email protected]: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5
warning gulp-watch > [email protected]: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5
4] Fetching packages...
info [email protected]: The platform "linux" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
[4/4] Building fresh packages...
info If you think this is a bug, please open a bug report with the information provided in "/var/www/html/web/themes/custom/drupaltheme/yarn-error.log".
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
error An unexpected error occurred: "/var/www/html/web/themes/custom/drupaltheme/node_modules/node-sass: Command failed.
�
Exit code: 1
Command: sh
Arguments: -c node scripts/build.js
Directory: /var/www/html/web/themes/custom/drupaltheme/node_modules/node-sass
Output:
Building: /usr/local/bin/node /var/www/html/web/themes/custom/drupaltheme/node_modules/node-gyp/bin/node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
gyp info it worked if it ends with ok
gyp verb cli [ '/usr/local/bin/node',
gyp verb cli   '/var/www/html/web/themes/custom/drupaltheme/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 [email protected]
gyp info using [email protected] | linux | 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 (/var/www/html/web/themes/custom/drupaltheme/node_modules/which/which.js:13:12)
gyp verb `which` failed     at F (/var/www/html/web/themes/custom/drupaltheme/node_modules/which/which.js:68:19)
gyp verb `which` failed     at E (/var/www/html/web/themes/custom/drupaltheme/node_modules/which/which.js:80:29)
gyp verb `which` failed     at /var/www/html/web/themes/custom/drupaltheme/node_modules/which/which.js:89:16
gyp verb `which` failed     at /var/www/html/web/themes/custom/drupaltheme/node_modules/isexe/index.js:42:5
gyp verb `which` failed     at /var/www/html/web/themes/custom/drupaltheme/node_modules/isexe/mode.js:8:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:170:21)
gyp verb `which` failed  python2 { Error: not found: python2
gyp verb `which` failed     at getNotFoundError (/var/www/html/web/themes/custom/drupaltheme/node_modules/which/which.js:13:12)
gyp verb `which` failed     at F (/var/www/html/web/themes/custom/drupaltheme/node_modules/which/which.js:68:19)
gyp verb `which` failed     at E (/var/www/html/web/themes/custom/drupaltheme/node_modules/which/which.js:80:29)
gyp verb `which` failed     at /var/www/html/web/themes/custom/drupaltheme/node_modules/which/which.js:89:16
gyp verb `which` failed     at /var/www/html/web/themes/custom/drupaltheme/node_modules/isexe/index.js:42:5
gyp verb `which` failed     at /var/www/html/web/themes/custom/drupaltheme/node_modules/isexe/mode.js:8:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:170:21)
gyp verb `which` failed   stack: 'Error: not found: python2\
    at getNotFoundError (/var/www/html/web/themes/custom/drupaltheme/node_modules/which/which.js:13:12)\
    at F (/var/www/html/web/themes/custom/drupaltheme/node_modules/which/which.js:68:19)\
    at E (/var/www/html/web/themes/custom/drupaltheme/node_modules/which/which.js:80:29)\
    at /var/www/html/web/themes/custom/drupaltheme/node_modules/which/which.js:89:16\
    at /var/www/html/web/themes/custom/drupaltheme/node_modules/isexe/index.js:42:5\
    at /var/www/html/web/themes/custom/drupaltheme/node_modules/isexe/mode.js:8:5\
    at FSReqWrap.oncomplete (fs.js:170: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
@csandanov
Copy link
Member

node-sass package (the dependency of gulp-sass) supports alpine linux since 4.1.0 (sass/node-sass#1589), installing a newer version of gulp-sass will fix that

@holyorb2
Copy link
Author

holyorb2 commented Sep 4, 2018

"gulp-sass": "^3.1.0" - installed ok

Thanx

@holyorb2 holyorb2 closed this as completed Sep 4, 2018
@petertogara
Copy link

Simply format your machine and start again

@StJohn3D
Copy link

Upgrading "node-sass": "4.11.0" -> "node-sass": "4.12.0" worked for me

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants