Unable to start a new ionic 3 project

PS C:\Users\ASUS\desktop\ionic> ionic start newdemo blank
:heavy_check_mark: Creating directory .\newdemo - done!
[INFO] Fetching app base (https://github.com/driftyco/ionic2-app-base/archive/master.tar.gz)
:heavy_check_mark: Downloading - done!
[INFO] Fetching starter template blank (https://github.com/driftyco/ionic2-starter-blank/archive/master.tar.gz)
:heavy_check_mark: Downloading - done!
:heavy_check_mark: Updating package.json with app details - done!
:heavy_check_mark: Creating configuration file ionic.config.json - done!
[INFO] Installing dependencies may take several minutes!

npm install
:heavy_multiplication_x: Running command - failed!
[ERROR] An error occurred while running npm install (exit code 1):

    npm WARN deprecated @angular/http@5.0.0: Package no longer supported. Use @angular/common instead, see https://angular.io/guide/deprecations#angularhttp
    npm WARN deprecated sw-toolbox@3.6.0: Please migrate to Workbox: https://developers.google.com/web/tools/workbox/guides/migrations/migrate-from-sw
    npm WARN deprecated chokidar@1.7.0: Chokidar 2 will break on node v14+. Upgrade to chokidar 3 with 15x less dependencies.
    npm WARN deprecated rollup-plugin-commonjs@8.2.6: This package has been deprecated and is no longer maintained. Please use @rollup/plugin-commonjs.
    npm WARN deprecated rollup-plugin-node-resolve@3.0.0: This package has been deprecated and is no longer maintained. Please use @rollup/plugin-node-resolve.
    npm WARN deprecated browserslist@2.11.3: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools.
    npm WARN deprecated fsevents@1.2.13: fsevents 1 will break on node v14+ and could be using insecure binaries. Upgrade to fsevents 2.
    npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
    npm WARN deprecated har-validator@5.1.5: this library is no longer supported
    npm WARN deprecated chokidar@2.1.8: Chokidar 2 will break on node v14+. Upgrade to chokidar 3 with 15x less dependencies.
    npm WARN deprecated resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated
    npm WARN deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated

    > node-sass@4.5.3 install C:\Users\ASUS\desktop\ionic\newdemo\node_modules\node-sass
    > node scripts/install.js

    Downloading binary from https://github.com/sass/node-sass/releases/download/v4.5.3/win32-x64-64_binding.node
    Cannot download "https://github.com/sass/node-sass/releases/download/v4.5.3/win32-x64-64_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

    > uglifyjs-webpack-plugin@0.4.6 postinstall C:\Users\ASUS\desktop\ionic\newdemo\node_modules\uglifyjs-webpack-plugin
    > node lib/post_install.js


    > node-sass@4.5.3 postinstall C:\Users\ASUS\desktop\ionic\newdemo\node_modules\node-sass
    > node scripts/build.js

    Building: C:\Program Files\nodejs\node.exe C:\Users\ASUS\desktop\ionic\newdemo\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 [ 'C:\\Program Files\\nodejs\\node.exe',
    gyp verb cli   'C:\\Users\\ASUS\\desktop\\ionic\\newdemo\\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.8.0
    gyp info using node@10.7.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 (C:\Users\ASUS\desktop\ionic\newdemo\node_modules\which\which.js:13:12)
    gyp verb `which` failed     at F (C:\Users\ASUS\desktop\ionic\newdemo\node_modules\which\which.js:68:19)
    gyp verb `which` failed     at E (C:\Users\ASUS\desktop\ionic\newdemo\node_modules\which\which.js:80:29)
    gyp verb `which` failed     at C:\Users\ASUS\desktop\ionic\newdemo\node_modules\which\which.js:89:16
    gyp verb `which` failed     at C:\Users\ASUS\desktop\ionic\newdemo\node_modules\isexe\index.js:42:5
    gyp verb `which` failed     at C:\Users\ASUS\desktop\ionic\newdemo\node_modules\isexe\windows.js:36:5
    gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:158:21)
    gyp verb `which` failed  python2 { Error: not found: python2
    gyp verb `which` failed     at getNotFoundError (C:\Users\ASUS\desktop\ionic\newdemo\node_modules\which\which.js:13:12)
    gyp verb `which` failed     at F (C:\Users\ASUS\desktop\ionic\newdemo\node_modules\which\which.js:68:19)
    gyp verb `which` failed     at E (C:\Users\ASUS\desktop\ionic\newdemo\node_modules\which\which.js:80:29)
    gyp verb `which` failed     at C:\Users\ASUS\desktop\ionic\newdemo\node_modules\which\which.js:89:16
    gyp verb `which` failed     at C:\Users\ASUS\desktop\ionic\newdemo\node_modules\isexe\index.js:42:5
    gyp verb `which` failed     at C:\Users\ASUS\desktop\ionic\newdemo\node_modules\isexe\windows.js:36:5
    gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:158:21)
    gyp verb `which` failed   stack:
    gyp verb `which` failed    'Error: not found: python2\n    at getNotFoundError (C:\\Users\\ASUS\\desktop\\ionic\\newdemo\\node_modules\\which\\which.js:13:12)\n    at F (C:\\Users\\ASUS\\desktop\\ionic\\newdemo\\node_modules\\which\\which.js:68:19)\n    at E (C:\\Users\\ASUS\\desktop\\ionic\\newdemo\\node_modules\\which\\which.js:80:29)\n    at C:\\Users\\ASUS\\desktop\\ionic\\newdemo\\node_modules\\which\\which.js:89:16\n    at C:\\Users\\ASUS\\desktop\\ionic\\newdemo\\node_modules\\isexe\\index.js:42:5\n    at C:\\Users\\ASUS\\desktop\\ionic\\newdemo\\node_modules\\isexe\\windows.js:36:5\n    at FSReqWrap.oncomplete (fs.js:158: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 (C:\Users\ASUS\desktop\ionic\newdemo\node_modules\which\which.js:13:12)
    gyp verb `which` failed     at F (C:\Users\ASUS\desktop\ionic\newdemo\node_modules\which\which.js:68:19)
    gyp verb `which` failed     at E (C:\Users\ASUS\desktop\ionic\newdemo\node_modules\which\which.js:80:29)
    gyp verb `which` failed     at C:\Users\ASUS\desktop\ionic\newdemo\node_modules\which\which.js:89:16
    gyp verb `which` failed     at C:\Users\ASUS\desktop\ionic\newdemo\node_modules\isexe\index.js:42:5
    gyp verb `which` failed     at C:\Users\ASUS\desktop\ionic\newdemo\node_modules\isexe\windows.js:36:5
    gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:158:21)
    gyp verb `which` failed  python { Error: not found: python
    gyp verb `which` failed     at getNotFoundError (C:\Users\ASUS\desktop\ionic\newdemo\node_modules\which\which.js:13:12)
    gyp verb `which` failed     at F (C:\Users\ASUS\desktop\ionic\newdemo\node_modules\which\which.js:68:19)
    gyp verb `which` failed     at E (C:\Users\ASUS\desktop\ionic\newdemo\node_modules\which\which.js:80:29)
    gyp verb `which` failed     at C:\Users\ASUS\desktop\ionic\newdemo\node_modules\which\which.js:89:16
    gyp verb `which` failed     at C:\Users\ASUS\desktop\ionic\newdemo\node_modules\isexe\index.js:42:5
    gyp verb `which` failed     at C:\Users\ASUS\desktop\ionic\newdemo\node_modules\isexe\windows.js:36:5
    gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:158:21)
    gyp verb `which` failed   stack:
    gyp verb `which` failed    'Error: not found: python\n    at getNotFoundError (C:\\Users\\ASUS\\desktop\\ionic\\newdemo\\node_modules\\which\\which.js:13:12)\n    at F (C:\\Users\\ASUS\\desktop\\ionic\\newdemo\\node_modules\\which\\which.js:68:19)\n    at E (C:\\Users\\ASUS\\desktop\\ionic\\newdemo\\node_modules\\which\\which.js:80:29)\n    at C:\\Users\\ASUS\\desktop\\ionic\\newdemo\\node_modules\\which\\which.js:89:16\n    at C:\\Users\\ASUS\\desktop\\ionic\\newdemo\\node_modules\\isexe\\index.js:42:5\n    at C:\\Users\\ASUS\\desktop\\ionic\\newdemo\\node_modules\\isexe\\windows.js:36:5\n    at FSReqWrap.oncomplete (fs.js:158: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 (C:\Users\ASUS\desktop\ionic\newdemo\node_modules\node-gyp\lib\configure.js:484:19)
    gyp ERR! stack     at PythonFinder.<anonymous> (C:\Users\ASUS\desktop\ionic\newdemo\node_modules\node-gyp\lib\configure.js:509:16)
    gyp ERR! stack     at callback (C:\Users\ASUS\desktop\ionic\newdemo\node_modules\graceful-fs\polyfills.js:295:20)
    gyp ERR! stack     at FSReqWrap.oncomplete (fs.js:158:21)
    gyp ERR! System Windows_NT 10.0.18363
    gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\ASUS\\desktop\\ionic\\newdemo\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
    gyp ERR! cwd C:\Users\ASUS\desktop\ionic\newdemo\node_modules\node-sass
    gyp ERR! node -v v10.7.0
    gyp ERR! node-gyp -v v3.8.0
    gyp ERR! not ok
    Build failed with error code: 1
    npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@^1.0.0 (node_modules\chokidar\node_modules\fsevents):
    npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.13: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
    npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@~2.1.2 (node_modules\watchpack\node_modules\chokidar\node_modules\fsevents):
    npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@2.1.3: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})

    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\ASUS\AppData\Roaming\npm-cache\_logs\2020-08-14T05_46_27_322Z-debug.log

Upgrade your global Ionic CLI with npm i -g @ionic/cli.

1 Like

It’s seems like a node-sass problem use: npm rebuild node-sass

1 Like

I working on inoic 3 so upgrading CLI to latest can Cause issue?

There’s a difference between “working on Ionic 3” and “starting a new Ionic 3 project”. You can work on existing Ionic 3 projects with a current CLI. You still won’t be able to spawn them, because Ionic 3 is no longer supported.

ok sir can you please tell me what should I do because I have lots of projects in ionic 3 and i also need to create new projects what setup should i do for both the scenario.currently I am using Ionic:

Ionic CLI : 5.4.16

Utility:

cordova-res : 0.15.1
native-run : 1.0.0

System:

NodeJS : v10.7.0
npm : 6.1.0
OS : Windows 10
still I am unable to create new projects.

Step1. npm uninstall -g ionic
step 2. npm uninstall -g @ionic/cli
step 3. npm install -g @ionic/cli

To create ionic 3 project
step 4. ionic start myApp --type=ionic-angular

Docs: https://ionicframework.com/docs/cli/commands/start

1 Like

thanks,
It worked for me.