Skip to content

can't be installed on latest windows 10 and can't initiale a new project #5840

@mrhili

Description

@mrhili

Version

4.5.4

Reproduction link

http://no-url.com/link-not/ok?

Environment info

windows 10 home
version : 1903
build :1832.1016

Steps to reproduce

http://no-url.com/link-not/ok?

What is expected?

http://no-url.com/link-not/ok?

What is actually happening?

i cannot install vue cli in windows 10


npm i -g @vue/cli @vue/cli-service-global
npm WARN deprecated @hapi/joi@15.1.1: joi is leaving the @Hapi organization and moving back to 'joi' (hapijs/joi#2411)
npm WARN deprecated request@2.88.2: request has been deprecated, see request/request#3142
npm WARN deprecated @hapi/address@2.1.4: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated @hapi/hoek@8.5.1: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated @hapi/topo@3.1.6: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated @hapi/bourne@1.3.2: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated har-validator@5.1.5: this library is no longer supported
npm ERR! Unexpected end of JSON input while parsing near '...^1.16.31","@types/web'

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\HP\AppData\Roaming\npm-cache_logs\2020-09-01T15_33_15_167Z-debug.log


if i install vue like : npm i -g vue
installed succefully but
cant initiat a new a project

Activity

haoqunjiang

haoqunjiang commented on Sep 1, 2020

@haoqunjiang
Member

Looks like a network issue related to the npm registry. Please check your network and try again.

mrhili

mrhili commented on Sep 1, 2020

@mrhili
Author

Checked many times

24 houre of trying

mrhili

mrhili commented on Sep 1, 2020

@mrhili
Author

maybe antivirus ?
i will see

mrhili

mrhili commented on Sep 1, 2020

@mrhili
Author

Vue CLI v3.8.4
✨ Creating project in C:\laragon\www\learning-projects\crashcourse.
� Initializing git repository...
⚙ Installing CLI plugins. This might take a while...

npm ERR! Unexpected end of JSON input while parsing near '...ed-require":"0.2.x","'

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\HP\AppData\Roaming\npm-cache_logs\2020-09-01T19_50_58_244Z-debug.log
ERROR command failed: npm install --loglevel error --registry=https://registry.npm.taobao.org --disturl=https://npm.taobao.org/dist

haoqunjiang

haoqunjiang commented on Sep 2, 2020

@haoqunjiang
Member

For the second error, run

vue config --set useTaobaoRegistry false

and try again.

BTW you are using a very old version of @vue/cli, it's recommended to upgrade to the latest v4.5

mrhili

mrhili commented on Sep 4, 2020

@mrhili
Author

Not working even with this configuration

haoqunjiang

haoqunjiang commented on Sep 4, 2020

@haoqunjiang
Member

If the error message still says "npm ERR! Unexpected end of JSON input while parsing near" then it's clearly a network/npm issue. In that case, there's nothing more I can help you with.

geni94

geni94 commented on Sep 4, 2020

@geni94

I'm having this issue as well.

Specs:
Windows 10
Node 14.8.0
Yarn 1.22.5

Running vue init [params] throws the following error:

Command vue init requires a global addon to be installed.
Please run yarn global add @vue/cli-init and try again.

Installing @vue/cli-init separately didn't solve the issue. Any clue?

haoqunjiang

haoqunjiang commented on Sep 5, 2020

@haoqunjiang
Member

@geni94 Maybe npm install -g @vue/cli-init?

geni94

geni94 commented on Sep 5, 2020

@geni94

@geni94 Maybe npm install -g @vue/cli-init?

That didn't help either: it kept throwing the error.

Apparently using yarn was causing the issue, although I'm still not sure why. Uninstalling everything and then installing again with npm fixed the issue for me, although I wanted to use yarn and not npm.

mrhili

mrhili commented on Sep 5, 2020

@mrhili
Author

I will try and give you afeedback

mrhili

mrhili commented on Sep 5, 2020

@mrhili
Author

PS C:\Users\HP> npm install -g vue

vue@2.6.12
added 1 package from 1 contributor in 33.477s

smilingkite

smilingkite commented on Sep 9, 2020

@smilingkite

For what it's worth: I was unable to use gitBash (even with administrator-rights) to start a vue-cli project, but the command prompt worked like a charm.

felix-cao

felix-cao commented on Nov 18, 2020

@felix-cao

yarn cache clean
yarn global add @vue-cli

More

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @haoqunjiang@felix-cao@geni94@smilingkite@mrhili

        Issue actions

          can't be installed on latest windows 10 and can't initiale a new project · Issue #5840 · vuejs/vue-cli