Skip to content

Ng new command throwing error #12924

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

Closed
tvarghesedt opened this issue Nov 10, 2018 · 4 comments
Closed

Ng new command throwing error #12924

tvarghesedt opened this issue Nov 10, 2018 · 4 comments

Comments

@tvarghesedt
Copy link

Bug Report or Feature Request (mark with an x)

- [ x] bug report -> please search issues before submitting
- [ ] feature request

Command (mark with an x)

- [x ] new
- [ ] build
- [ ] serve
- [ ] test
- [ ] e2e
- [ ] generate
- [ ] add
- [ ] update
- [ ] lint
- [ ] xi18n
- [ ] run
- [ ] config
- [ ] help
- [ ] version
- [ ] doc

Versions

node --version
v10.13.0

npm --version
6.4.1

ng --version

Angular CLI: 7.0.5
Node: 10.13.0
OS: win32 x64
Angular:
...

Package Version

@angular-devkit/architect 0.10.5
@angular-devkit/core 7.0.5
@angular-devkit/schematics 7.0.5
@schematics/angular 7.0.5
@schematics/update 0.10.5
rxjs 6.3.3
typescript 3.1.6

OS- Windows 7

Repro steps

I ran the "ng new myworkspace" command

The log given by the failure

I got the following log in command prompt terminal-

CREATE myworkspace/e2e/src/app.po.ts (208 bytes)
events.js:167
throw er; // Unhandled 'error' event
^

Error: spawn C:\Windows\system32\cmd.exe ENOENT
at Process.ChildProcess._handle.onexit (internal/child_process.js:232:19)
at onErrorNT (internal/child_process.js:407:16)
at process._tickCallback (internal/process/next_tick.js:63:19)
Emitted 'error' event at:
at Process.ChildProcess._handle.onexit (internal/child_process.js:238:12)
at onErrorNT (internal/child_process.js:407:16)
at process._tickCallback (internal/process/next_tick.js:63:19)

Desired functionality

I would like to create a new workspace/app

Mention any other details that might be useful

None in mind for now

@alan-agius4
Copy link
Collaborator

Duplicate of #12670

@alan-agius4 alan-agius4 marked this as a duplicate of #12670 Nov 10, 2018
@tvarghesedt
Copy link
Author

tvarghesedt commented Nov 12, 2018

@alan-agius4 The error got fixed but I am now getting the error of tarball being corrupted, I tried create a new app within the new sub directory of the drive. Here is the brief log

`npm WARN tarball tarball data for @ngtools/[email protected] (sha512-KARXUp1SCg6TNGH
aXOITiOfbGBJAd7gkdo0OKWF77ARqWb/pSN4rwFV4kxm0CB2kkmJ40JQCQG+TiltX+3Jnqg==) seems
to be corrupted. Trying one more time.
npm ERR! path E:\newangproject\my-app\node_modules.staging@ngtools\webpack-75a
100fc\src\transformers\export_ngfactory.js
npm ERR! code EPERM
npm ERR! errno -4048
npm ERR! syscall unlink
npm ERR! Error: EPERM: operation not permitted, unlink 'E:\newangproject\my-app
node_modules.staging@ngtools\webpack-75a100fc\src\transformers\export_ngfactor
y.js'
npm ERR! { [Error: EPERM: operation not permitted, unlink 'E:\newangproject\my-
app\node_modules.staging@ngtools\webpack-75a100fc\src\transformers\export_ngfa
ctory.js']
npm ERR! cause:
npm ERR! { Error: EPERM: operation not permitted, unlink 'E:\newangproject\my
-app\node_modules.staging@ngtools\webpack-75a100fc\src\transformers\export_ngf
actory.js'
npm ERR! errno: -4048,
npm ERR! code: 'EPERM',
npm ERR! syscall: 'unlink',
npm ERR! path:
npm ERR! 'E:\newangproject\my-app\node_modules\.staging\@ngtools\web
pack-75a100fc\src\transformers\export_ngfactory.js' },
npm ERR! stack:
npm ERR! 'Error: EPERM: operation not permitted, unlink 'E:\newangproject\
my-app\node_modules\.staging\@ngtools\webpack-75a100fc\src\transformers\e
xport_ngfactory.js'',
npm ERR! errno: -4048,
npm ERR! code: 'EPERM',
npm ERR! syscall: 'unlink',
npm ERR! path:
npm ERR! 'E:\newangproject\my-app\node_modules\.staging\@ngtools\webpac
k-75a100fc\src\transformers\export_ngfactory.js',
npm ERR! parent: 'my-app' }
npm ERR!
npm ERR! The operation was rejected by your operating system.
npm ERR! It's possible that the file was already in use (by a text editor or ant
ivirus),
npm ERR! or that you lack permissions to access it.
npm ERR!
npm ERR! If you believe this might be a permissions issue, please double-check t
he
npm ERR! permissions of the file and its containing directories, or try running
npm ERR! the command again as root/Administrator (though this is not recommended
).
npm WARN tarball tarball data for typescript@~3.1.6 (sha512-tDMYfVtvpb96msS1lDX9
MEdHrW4yOuZ4Kdc4Him9oU796XldPYF/t2+uKoX0BBa0hXXwDlqYQbXY5Rzjzc5hBA==) seems to b
e corrupted. Trying one more time.

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Thomas\AppData\Roaming\npm-cache_logs\2018-11-12T11_03_00
_731Z-debug.log
Package install failed, see above.`

Please guide me to fix this

@Jatin-8898
Copy link

Same Error as Above.
Kindly help to fix this issue.

@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 9, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants