3.0.0-rc.5
vue create hello
A message confirming the Project has been created.
An error occurrs:
Error [ERR_STREAM_WRITE_AFTER_END]: write after end
at writeAfterEnd (_stream_writable.js:241:12)
at PassThrough.Writable.write (_stream_writable.js:291:5)
at PassThrough.Writable.end (_stream_writable.js:576:10)
at ReadEntry.entry.on (/Users/admin/node_modules/npm/node_modules/pacote/lib/extract-stream.js:19:41)
at ReadEntry.emit (events.js:185:15)
at ReadEntry.emit (/Users/admin/node_modules/npm/node_modules/tar/node_modules/minipass/index.js:296:25)
at ReadEntry.[maybeEmitEnd] (/Users/admin/node_modules/npm/node_modules/tar/node_modules/minipass/index.js:249:12)
at ReadEntry.end (/Users/admin/node_modules/npm/node_modules/tar/node_modules/minipass/index.js:162:27)
at Unpack.[consumeBody] (/Users/admin/node_modules/npm/node_modules/tar/lib/parse.js:210:13)
at Unpack.[consumeChunkSub] (/Users/admin/node_modules/npm/node_modules/tar/lib/parse.js:391:40)
at Unpack.[consumeChunk] (/Users/admin/node_modules/npm/node_modules/tar/lib/parse.js:362:30)
at Unzip.(anonymous function).on.chunk (/Users/admin/node_modules/npm/node_modules/tar/lib/parse.js:291:59)
at Unzip.emit (events.js:180:13)
at Unzip.emit (/Users/admin/node_modules/npm/node_modules/tar/node_modules/minipass/index.js:296:25)
at Unzip.write (/Users/admin/node_modules/npm/node_modules/tar/node_modules/minipass/index.js:99:17)
at Unzip.write (/Users/admin/node_modules/npm/node_modules/tar/node_modules/minizlib/index.js:284:29)
Emitted 'error' event at:
at writeAfterEnd (_stream_writable.js:243:10)
at PassThrough.Writable.write (_stream_writable.js:291:5)
[... lines matching original stack trace ...]
at Unzip.write (/Users/admin/node_modules/npm/node_modules/tar/node_modules/minizlib/index.js:284:29)
PS: Happens for both CLI and UI
PSS: I've downgraded my npm version to 5.6.0 (a few solutions online suggests this) but it still doesn't work.
Whats your node version?
Since this is an error during the npm install process I'm not sure we can do anything about this. vue-cli doesn't mess with that in any way, we just trigger it.
Looking at the stack, everything comes from npm itself so I'm afraid there's nothing we can do.
~/.vuerc file, make sure useTaobaoRegistry is false.Other than that, I really can't think of anything that in Vue CLI that can lead to this.
Was getting the same thing and had to downgrade my version of npm.
npm i -g [email protected]
Setting useTaobaoRegistry to false works to me.
Most helpful comment
Was getting the same thing and had to downgrade my version of npm.
npm i -g [email protected]