-
-
Notifications
You must be signed in to change notification settings - Fork 6.3k
Unable to start vue due to issue with npm run serve #4366
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
Comments
Command line specifically will say: gpierce$ npm run serve
INFO Starting development server... Error: listen EADDRNOTAVAIL: address not available 23.202.231.169:8080 |
This will resolve on MacOS -only- if you force the host to be 0.0.0.0. Otherwise, it will try to use the IP address it believes this should resolve to and fail. |
Do you have a |
gpierce$ echo $HOST |
What about If none of these results in |
Here's how we get the public IP address: vue-cli/packages/@vue/cli-service/lib/util/prepareURLs.js Lines 37 to 38 in 76eb714
I believe the logic on the Vue CLI side is bug-free. |
gpierce$ node -e 'console.log(process.env.HOST)' gpierce$ ping $HOST |
So that's the problem. It is because |
Never done that manually on any MacOS machine before and I've been
developing on vuejs for a while now. Deployed projects and everything.
Something somewhere has changed to require that.
…On Sun, Jul 28, 2019, 1:24 AM Haoqun Jiang ***@***.***> wrote:
Closed #4366 <#4366>.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#4366?email_source=notifications&email_token=AAAXNUW4EAPJAEOJXTVKUMLQBUUPRA5CNFSM4IHCEZK2YY3PNVWWK3TUL52HS4DFWZEXG43VMVCXMZLOORHG65DJMZUWGYLUNFXW5KTDN5WW2ZLOORPWSZGOSXQO4AY#event-2514546179>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAAXNURRLSBRPMVLLRWBVTDQBUUPRANCNFSM4IHCEZKQ>
.
|
I'm also quite curious about this issue. It's not the first time I've seen this. Did you just installed anaconda? |
Hi, I'm getting a similar error:
I tried echoing my Could someone give me a tip on how to fix this? |
Version
3.9.3
Environment info
Steps to reproduce
vue create vue-test
cd vue-test
npm run serve
What is expected?
Normal running of vue process and to be able to see a web page with the vue information attached to it.
What is actually happening?
Receiving an error from Vue claiming that it cannot get access to a port. The port is available and have performed a check on MacOS to ensure that nothing is listening to or blocking the port
0 info it worked if it ends with ok
1 verbose cli [ '/usr/local/Cellar/node/12.6.0/bin/node',
1 verbose cli '/usr/local/bin/npm',
1 verbose cli 'run',
1 verbose cli 'serve' ]
2 info using [email protected]
3 info using [email protected]
4 verbose run-script [ 'preserve', 'serve', 'postserve' ]
5 info lifecycle [email protected]
preserve: [email protected]serve: [email protected]6 info lifecycle [email protected]
7 verbose lifecycle [email protected]
serve: unsafe-perm in lifecycle trueserve: PATH: /usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/Users/gpierce/Desktop/vuetest/node_modules/.bin:/anaconda3/bin:/anaconda3/condabin:/usr/local/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/Library/Frameworks/Mono.framework/Versions/Current/Commands8 verbose lifecycle [email protected]
9 verbose lifecycle [email protected]
serve: CWD: /Users/gpierce/Desktop/vuetestserve: Args: [ '-c', 'vue-cli-service serve' ]10 silly lifecycle [email protected]
11 silly lifecycle [email protected]
serve: Returned: code: 1 signal: nullserve: Failed to exec serve script12 info lifecycle [email protected]
13 verbose stack Error: [email protected] serve:
vue-cli-service serve
13 verbose stack Exit status 1
13 verbose stack at EventEmitter. (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:301:16)
13 verbose stack at EventEmitter.emit (events.js:198:13)
13 verbose stack at ChildProcess. (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
13 verbose stack at ChildProcess.emit (events.js:198:13)
13 verbose stack at maybeClose (internal/child_process.js:982:16)
13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:259:5)
14 verbose pkgid [email protected]
15 verbose cwd /Users/gpierce/Desktop/vuetest
16 verbose Darwin 18.7.0
17 verbose argv "/usr/local/Cellar/node/12.6.0/bin/node" "/usr/local/bin/npm" "run" "serve"
18 verbose node v10.16.0
19 verbose npm v6.9.0
20 error code ELIFECYCLE
21 error errno 1
22 error [email protected] serve:
vue-cli-service serve
22 error Exit status 1
23 error Failed at the [email protected] serve script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]
The text was updated successfully, but these errors were encountered: