Unable to run "vue-cli-service serve" [vue 3] - vue.js

PROBLEM
I'm trying to update packages and ran ncu -u once I did that I ran npm install to apply the new updates but it wouldn't work. It appear that it gave me issues with eslint??? Though I tried replicating the problem so I could post the error here and I can't seem to get it but if I remember correctly I had to do npm install --legacy-peer-deps. Anyways once I applied that it installs but once I try running npm run serve I get an error.
WHAT I'VE TRIED
I've checked the versions of each package and they all are updated to the most recent version. I've deleted the "package-lock.json" and "node_modules" and reinstalled them. I'm pretty stumped what it could be. I looked up on some other stackoverflow posts mentioning about clearing the cache too but that didn't work.
CONSOLE (when running npm run serve)
PS C:\Users\vdcam\Documents\GitHub\project-cc> npm run serve
> project-cc#0.1.0 serve
> vue-cli-service serve
INFO Starting development server...
ERROR Error: Rule can only have one resource source (provided resource and test + include + exclude) in {
"exclude": [
null
],
"use": [
{
"loader": "C:\\Users\\vdcam\\Documents\\GitHub\\project-cc\\node_modules\\cache-loader\\dist\\cjs.js",
"options": {
"cacheDirectory": "C:\\Users\\vdcam\\Documents\\GitHub\\project-cc\\node_modules\\.cache\\babel-loader",
"cacheIdentifier": "39d06afa"
},
"ident": "clonedRuleSet-38.use[0]"
},
{
"loader": "C:\\Users\\vdcam\\Documents\\GitHub\\project-cc\\node_modules\\babel-loader\\lib\\index.js",
"options": "undefined",
"ident": "undefined"
}
]
}
Error: Rule can only have one resource source (provided resource and test + include + exclude) in
{
"exclude": [
null
],
"use": [
{
"loader": "C:\\Users\\vdcam\\Documents\\GitHub\\project-cc\\node_modules\\cache-loader\\dist\\cjs.js",
"options": {
"cacheDirectory": "C:\\Users\\vdcam\\Documents\\GitHub\\project-cc\\node_modules\\.cache\\babel-loader",
"cacheIdentifier": "39d06afa"
},
"ident": "clonedRuleSet-38.use[0]"
},
{
"loader": "C:\\Users\\vdcam\\Documents\\GitHub\\project-cc\\node_modules\\babel-loader\\lib\\index.js",
"options": "undefined",
"ident": "undefined"
}
]
}
at checkResourceSource (C:\Users\vdcam\Documents\GitHub\project-cc\node_modules\#vue\cli-service\node_modules\webpack\lib\RuleSet.js:167:11)
at Function.normalizeRule (C:\Users\vdcam\Documents\GitHub\project-cc\node_modules\#vue\cli-service\node_modules\webpack\lib\RuleSet.js:198:4)
at C:\Users\vdcam\Documents\GitHub\project-cc\node_modules\#vue\cli-service\node_modules\webpack\lib\RuleSet.js:110:20
at Array.map (<anonymous>)
at Function.normalizeRules (C:\Users\vdcam\Documents\GitHub\project-cc\node_modules\#vue\cli-service\node_modules\webpack\lib\RuleSet.js:109:17)
at new RuleSet (C:\Users\vdcam\Documents\GitHub\project-cc\node_modules\#vue\cli-service\node_modules\webpack\lib\RuleSet.js:104:24)
at new NormalModuleFactory (C:\Users\vdcam\Documents\GitHub\project-cc\node_modules\#vue\cli-service\node_modules\webpack\lib\NormalModuleFactory.js:115:18)
at Compiler.createNormalModuleFactory (C:\Users\vdcam\Documents\GitHub\project-cc\node_modules\#vue\cli-service\node_modules\webpack\lib\Compiler.js:636:31)
at Compiler.newCompilationParams (C:\Users\vdcam\Documents\GitHub\project-cc\node_modules\#vue\cli-service\node_modules\webpack\lib\Compiler.js:653:30)
at Compiler.compile (C:\Users\vdcam\Documents\GitHub\project-cc\node_modules\#vue\cli-service\node_modules\webpack\lib\Compiler.js:661:23)
at C:\Users\vdcam\Documents\GitHub\project-cc\node_modules\#vue\cli-service\node_modules\webpack\lib\Watching.js:77:18
at AsyncSeriesHook.eval [as callAsync] (eval at create (C:\Users\vdcam\Documents\GitHub\project-cc\node_modules\tapable\lib\HookCodeFactory.js:33:10), <anonymous>:22:1)
at AsyncSeriesHook.lazyCompileHook (C:\Users\vdcam\Documents\GitHub\project-cc\node_modules\tapable\lib\Hook.js:154:20)
at Watching._go (C:\Users\vdcam\Documents\GitHub\project-cc\node_modules\#vue\cli-service\node_modules\webpack\lib\Watching.js:41:32)
at C:\Users\vdcam\Documents\GitHub\project-cc\node_modules\#vue\cli-service\node_modules\webpack\lib\Watching.js:33:9
at Compiler.readRecords (C:\Users\vdcam\Documents\GitHub\project-cc\node_modules\#vue\cli-service\node_modules\webpack\lib\Compiler.js:529:11)
npm ERR! code 1
npm ERR! path C:\Users\vdcam\Documents\GitHub\project-cc
npm ERR! command failed
npm ERR! command C:\WINDOWS\system32\cmd.exe /d /s /c vue-cli-service serve
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\vdcam\AppData\Local\npm-cache\_logs\2021-03-24T03_03_44_891Z-debug.log
DEBUG LOG ("npm run serve")
0 verbose cli [
0 verbose cli 'C:\\Program Files\\nodejs\\node.exe',
0 verbose cli 'C:\\Users\\vdcam\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js',
0 verbose cli 'run',
0 verbose cli 'serve'
0 verbose cli ]
1 info using npm#7.7.0
2 info using node#v12.16.1
3 timing npm:load:whichnode Completed in 2ms
4 timing config:load:defaults Completed in 1ms
5 timing config:load:file:C:\Users\vdcam\AppData\Roaming\npm\node_modules\npm\npmrc Completed in 3ms
6 timing config:load:builtin Completed in 3ms
7 timing config:load:cli Completed in 1ms
8 timing config:load:env Completed in 0ms
9 timing config:load:file:C:\Users\vdcam\Documents\GitHub\project-cc\.npmrc Completed in 0ms
10 timing config:load:project Completed in 1ms
11 timing config:load:file:C:\Users\vdcam\.npmrc Completed in 1ms
12 timing config:load:user Completed in 1ms
13 timing config:load:file:C:\Users\vdcam\AppData\Roaming\npm\etc\npmrc Completed in 0ms
14 timing config:load:global Completed in 0ms
15 timing config:load:validate Completed in 0ms
16 timing config:load:setEnvs Completed in 1ms
17 timing config:load Completed in 8ms
18 timing npm:load:configload Completed in 8ms
19 timing npm:load:setTitle Completed in 0ms
20 timing npm:load:setupLog Completed in 2ms
21 timing npm:load:cleanupLog Completed in 2ms
22 timing npm:load:configScope Completed in 0ms
23 timing npm:load:projectScope Completed in 0ms
24 timing npm:load Completed in 14ms
25 timing config:load:flatten Completed in 3ms
26 timing command:run Completed in 4496ms
27 verbose stack Error: command failed
27 verbose stack at ChildProcess.<anonymous> (C:\Users\vdcam\AppData\Roaming\npm\node_modules\npm\node_modules\#npmcli\promise-spawn\index.js:64:27)
27 verbose stack at ChildProcess.emit (events.js:311:20)
27 verbose stack at maybeClose (internal/child_process.js:1021:16)
27 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:286:5)
28 verbose pkgid project-cc#0.1.0
29 verbose cwd C:\Users\vdcam\Documents\GitHub\project-cc
30 verbose Windows_NT 10.0.18363
31 verbose argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\vdcam\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js" "run" "serve"
32 verbose node v12.16.1
33 verbose npm v7.7.0
34 error code 1
35 error path C:\Users\vdcam\Documents\GitHub\project-cc
36 error command failed
37 error command C:\WINDOWS\system32\cmd.exe /d /s /c vue-cli-service serve
38 verbose exit 1
I would appreciate the help very much!!! Thank You!

A couple issues:
Your project depends on vue-cli-service 4.x (which only uses Webpack 4) and on webpack 5. For Webpack 5, vue-cli-service 5.x is required. Note #babel/eslint-parser is also needed, and you'll have to configure parserOptions.parser to match. See package.json below.
No need for dev dependency on webpack, webpack-cli, or webpack-bundle-analyzer, since vue-cli-service already depends on webpack and webpack-bundle-analyzer (which pulls them in transitively), and webpack-cli is not used in your project.
These dependencies should fix the issue:
// package.json
{
"devDependencies": {
"#babel/core": "^7.12.10",
"#babel/eslint-parser": "^7.12.1",
"#vue/cli-plugin-babel": "~5.0.0-alpha.7",
"#vue/cli-plugin-eslint": "~5.0.0-alpha.7",
"#vue/cli-plugin-router": "~5.0.0-alpha.7",
"#vue/cli-service": "~5.0.0-alpha.7",
"#vue/compiler-sfc": "^3.0.7",
"eslint": "^7.22.0",
"eslint-plugin-vue": "^7.8.0",
},
"eslintConfig": {
"parserOptions": {
"parser": "#babel/eslint-parser"
},
},
...
}
GitHub PR

fix this was to revert changes in my package-lock.json.
Then a npm prune to remove unuseful packages and npm update to be up-to-date.

Related

Build failing with vue-notification package

I'm working on a project with vuepress and the vue-notification package. Everything is ok when I run the project locally with the vuepress dev command.
However, I get this error message when build the project:
> vuepress build docs
wait Extracting site metadata...
tip Apply theme #vuepress/theme-default ...
tip Apply plugin container (i.e. "vuepress-plugin-container") ...
tip Apply plugin #vuepress/register-components (i.e. "#vuepress/plugin-register-components") ...
tip Apply plugin #vuepress/active-header-links (i.e. "#vuepress/plugin-active-header-links") ...
tip Apply plugin #vuepress/search (i.e. "#vuepress/plugin-search") ...
tip Apply plugin #vuepress/nprogress (i.e. "#vuepress/plugin-nprogress") ...
✔ Client
Compiled successfully in 9.57s
✔ Server
Compiled successfully in 6.32s
wait Rendering static HTML...
error Error rendering /: false
undefined
error Error rendering /404.html: false
undefined
ReferenceError: document is not defined
at addStyle (node_modules/vue-notification/dist/index.js:1019:0)
at addStylesToDom (node_modules/vue-notification/dist/index.js:1003:0)
at module.exports (node_modules/vue-notification/dist/index.js:957:0)
at Object.<anonymous> (node_modules/vue-notification/dist/index.js:898:0)
at __webpack_require__ (node_modules/vue-notification/dist/index.js:30:0)
at Object.<anonymous> (node_modules/vue-notification/dist/index.js:204:0)
at __webpack_require__ (node_modules/vue-notification/dist/index.js:30:0)
at Object.<anonymous> (node_modules/vue-notification/dist/index.js:154:0)
at __webpack_require__ (node_modules/vue-notification/dist/index.js:30:0)
at server-bundle.js:6487:18
at server-bundle.js:6490:10
at webpackUniversalModuleDefinition (node_modules/vue-notification/dist/index.js:3:0)
at Object.<anonymous> (node_modules/vue-notification/dist/index.js:10:1)
at __webpack_require__ (webpack/bootstrap:25:0)
at Module.<anonymous> (server-bundle.js:13363:12)
at __webpack_require__ (webpack/bootstrap:25:0)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! test-vuepress-notification#1.0.0 build: `vuepress build docs`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the test-vuepress-notification#1.0.0 build 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! /home/joao/.npm/_logs/2021-04-13T13_35_49_588Z-debug.log
This is the content of the log file
0 info it worked if it ends with ok
1 verbose cli [ '/usr/bin/node', '/usr/bin/npm', 'run', 'build' ]
2 info using npm#6.14.12
3 info using node#v14.16.1
4 verbose run-script [ 'prebuild', 'build', 'postbuild' ]
5 info lifecycle test-vuepress-notification#1.0.0~prebuild: test-vuepress-notification#1.0.0
6 info lifecycle test-vuepress-notification#1.0.0~build: test-vuepress-notification#1.0.0
7 verbose lifecycle test-vuepress-notification#1.0.0~build: unsafe-perm in lifecycle true
8 verbose lifecycle test-vuepress-notification#1.0.0~build: PATH: /usr/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/home/joao/test-vuepress-notification/node_modules/.bin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games
9 verbose lifecycle test-vuepress-notification#1.0.0~build: CWD: /home/joao/test-vuepress-notification
10 silly lifecycle test-vuepress-notification#1.0.0~build: Args: [ '-c', 'vuepress build docs' ]
11 silly lifecycle test-vuepress-notification#1.0.0~build: Returned: code: 1 signal: null
12 info lifecycle test-vuepress-notification#1.0.0~build: Failed to exec build script
13 verbose stack Error: test-vuepress-notification#1.0.0 build: `vuepress build docs`
13 verbose stack Exit status 1
13 verbose stack at EventEmitter.<anonymous> (/usr/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:332:16)
13 verbose stack at EventEmitter.emit (events.js:315:20)
13 verbose stack at ChildProcess.<anonymous> (/usr/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
13 verbose stack at ChildProcess.emit (events.js:315:20)
13 verbose stack at maybeClose (internal/child_process.js:1048:16)
13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:288:5)
14 verbose pkgid test-vuepress-notification#1.0.0
15 verbose cwd /home/joao/test-vuepress-notification
16 verbose Linux 4.19.0-16-amd64
17 verbose argv "/usr/bin/node" "/usr/bin/npm" "run" "build"
18 verbose node v14.16.1
19 verbose npm v6.14.12
20 error code ELIFECYCLE
21 error errno 1
22 error test-vuepress-notification#1.0.0 build: `vuepress build docs`
22 error Exit status 1
23 error Failed at the test-vuepress-notification#1.0.0 build script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]
And this is the information on my environment
Environment Info:
System:
OS: Linux 5.4 Debian GNU/Linux 10 (buster) 10 (buster)
CPU: (4) x64 Intel(R) Core(TM) i5-7200U CPU # 2.50GHz
Binaries:
Node: 14.16.0 - /usr/bin/node
Yarn: Not Found
npm: 6.14.11 - /usr/bin/npm
Browsers:
Chrome: Not Found
Firefox: Not Found
npmPackages:
#vuepress/core: 1.8.2
#vuepress/theme-default: 1.8.2
vuepress: ^1.8.2 => 1.8.2
npmGlobalPackages:
vuepress: Not Found
The repository that I have used to reproduce the error is available in https://github.com/joaohis/vuepress-vue-notification-issue
Am I importing and injecting the vue-notification package correctly?
Do vuepress and vue-notification are not compatible?
Thank you.
With the help of a colleague in Reddit, I figured out that this is a problem with server-side rendering. To cope with it, I have followed the vue-notification documentation resulting in this enhanceApp.js file
import Notifications from 'vue-notification/dist/ssr.js'
export default ({
Vue, // the version of Vue being used in the VuePress app
options, // the options for the root Vue instance
router, // the router instance for the app
siteData, // site metadata
isServer // is this enhancement applied in server-rendering or client
}) => {
Vue.use(Notifications)
// Import the conventional module for client-side render
if (!isServer) {
import('vue-notification/dist/index.js').then(module => {
Vue.use(module)
})
}
}
Now I can build the project without any problem.

NPM build issue with webpack-dev-server

I'm hoping someone can advise on a problem with NPM building that resulted from trying to use an old version of webpack-dev-server. I'm following a React tutorial and using the old versions of utilities it suggests. I installed webpack-dev-server version 2.5.1 and NPM couldn't build anymore. In my IDE I used Yarn to move up to webpack-dev-server 2.11.5 and now my application is running fine. "npm run dev-server" and "npm run build" work fine now. However, when I try "npm install" I get "ERR! Cannot read property 'match' of undefined".
I'm assuming if I can't run npm install I could get into trouble later on. Can someone help me understand what is wrong? My log file:
0 info it worked if it ends with ok
1 verbose cli [ '/usr/local/bin/node', '/usr/local/bin/npm', 'install' ]
2 info using npm#6.14.4
3 info using node#v12.16.2
4 verbose npm-session bf54bf8ec307523c
5 silly install runPreinstallTopLevelLifecycles
6 silly preinstall indecision-appnew#1.0.0
7 info lifecycle indecision-appnew#1.0.0~preinstall: indecision-appnew#1.0.0
8 silly install loadCurrentTree
9 silly install readLocalPackageData
10 timing stage:loadCurrentTree Completed in 787ms
11 silly install loadIdealTree
12 silly install cloneCurrentTreeToIdealTree
13 timing stage:loadIdealTree:cloneCurrentTree Completed in 6ms
14 silly install loadShrinkwrap
15 http fetch GET 304 https://registry.npmjs.org/babel-cli 271ms (from cache)
16 silly pacote version manifest for babel-cli#6.24.1 fetched in 279ms
17 timing stage:rollbackFailedOptional Completed in 0ms
18 timing stage:runTopLevelLifecycles Completed in 1106ms
19 silly saveTree indecision-appnew#1.0.0
19 silly saveTree └─┬ babel-cli#6.24.1
19 silly saveTree ├── babel-core#6.25.0
19 silly saveTree └─┬ chokidar#1.7.0
19 silly saveTree ├─┬ anymatch#1.3.2
19 silly saveTree │ └─┬ micromatch#2.3.11
19 silly saveTree │ ├─┬ arr-diff#2.0.0
19 silly saveTree │ │ └── arr-flatten#1.1.0
19 silly saveTree │ ├── array-unique#0.2.1
19 silly saveTree │ ├── braces#1.8.5
19 silly saveTree │ ├── expand-brackets#0.1.5
19 silly saveTree │ └── extglob#0.3.2
19 silly saveTree └── async-each#1.0.3
20 verbose stack TypeError: Cannot read property 'match' of undefined
20 verbose stack at tarballToVersion (/usr/local/lib/node_modules/npm/lib/install/inflate-shrinkwrap.js:87:20)
20 verbose stack at inflatableChild (/usr/local/lib/node_modules/npm/lib/install/inflate-shrinkwrap.js:99:22)
20 verbose stack at /usr/local/lib/node_modules/npm/lib/install/inflate-shrinkwrap.js:55:12
20 verbose stack at tryCatcher (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/util.js:16:23)
20 verbose stack at Object.gotValue (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/reduce.js:155:18)
20 verbose stack at Object.gotAccum (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/reduce.js:144:25)
20 verbose stack at Object.tryCatcher (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/util.js:16:23)
20 verbose stack at Promise._settlePromiseFromHandler (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:517:31)
20 verbose stack at Promise._settlePromise (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:574:18)
20 verbose stack at Promise._settlePromise0 (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:619:10)
20 verbose stack at Promise._settlePromises (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:699:18)
20 verbose stack at _drainQueueStep (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:138:12)
20 verbose stack at _drainQueue (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:131:9)
20 verbose stack at Async._drainQueues (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:147:5)
20 verbose stack at Immediate.Async.drainQueues [as _onImmediate] (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:17:14)
20 verbose stack at processImmediate (internal/timers.js:456:21)
21 verbose cwd /Library/WebServer/Documents/reactCourse/indecision-appNew
22 verbose Darwin 19.4.0
23 verbose argv "/usr/local/bin/node" "/usr/local/bin/npm" "install"
24 verbose node v12.16.2
25 verbose npm v6.14.4
26 error Cannot read property 'match' of undefined
27 verbose exit [ 1, true ]
package.json:
{
"name": "indecision-appnew",
"version": "1.0.0",
"main": "index.js",
"author": "some student",
"license": "MIT",
"description": "",
"scripts": {
"serve": "live-server public/",
"build": "webpack",
"dev-server": "webpack-dev-server"
},
"dependencies": {
"babel-cli": "6.24.1",
"babel-core": "6.25.0",
"babel-loader": "7.1.1",
"babel-preset-env": "1.5.2",
"babel-preset-react": "6.24.1",
"live-server": "^1.2.1",
"react": "16.0.0",
"react-dom": "16.0.0",
"validator": "8.0.0",
"webpack": "3.1.0",
"webpack-dev-server": "^2.11.5"
}
}
I found a generic way to debug these TypeError: Cannot read property 'match' of undefined errors here: https://stackoverflow.com/a/64369937/2441655

Azure devops error : This is probably not a problem with npm. There is likely additional logging output above

I am getting the following error in Azure DevOps build the pipeline. This works perfectly fine in the local environment.
The error is thrown in ng e2e step. I am on Angular 7.1 version.
2018-12-23T11:09:23.7978210Z ##[section]Starting: Run e2e
2018-12-23T11:09:23.7982921Z ==============================================================================
2018-12-23T11:09:23.7983079Z Task : npm
2018-12-23T11:09:23.7983172Z Description : Install and publish npm packages, or run an npm command. Supports npmjs.com and authenticated registries like Package Management.
2018-12-23T11:09:23.7983263Z Version : 1.144.0
2018-12-23T11:09:23.7983316Z Author : Microsoft Corporation
2018-12-23T11:09:23.7983401Z Help : [More Information](https://go.microsoft.com/fwlink/?LinkID=613746)
2018-12-23T11:09:23.7983480Z ==============================================================================
2018-12-23T11:09:24.2946060Z SYSTEMVSSCONNECTION exists true
2018-12-23T11:09:24.3883866Z SYSTEMVSSCONNECTION exists true
2018-12-23T11:09:24.6106087Z [command]C:\Windows\system32\cmd.exe /D /S /C ""C:\Program Files\nodejs\npm.cmd" --version"
2018-12-23T11:09:25.3644361Z 6.4.1
2018-12-23T11:09:27.0143140Z [command]C:\Windows\system32\cmd.exe /D /S /C ""C:\Program Files\nodejs\npm.cmd" config list"
2018-12-23T11:09:27.8299297Z ; cli configs
2018-12-23T11:09:27.8299516Z metrics-registry = "https://registry.npmjs.org/"
2018-12-23T11:09:27.8299587Z scope = ""
2018-12-23T11:09:27.8299667Z user-agent = "npm/6.4.1 node/v8.12.0 win32 x64"
2018-12-23T11:09:27.8299713Z
2018-12-23T11:09:27.8299768Z ; environment configs
2018-12-23T11:09:27.8299845Z cache = "C:\\npm\\cache"
2018-12-23T11:09:27.8299903Z prefix = "C:\\npm\\prefix"
2018-12-23T11:09:27.8299985Z userconfig = "D:\\a\\1\\npm\\19427.npmrc"
2018-12-23T11:09:27.8300028Z
2018-12-23T11:09:27.8300099Z ; builtin config undefined
2018-12-23T11:09:27.8300137Z
2018-12-23T11:09:27.8300196Z ; node bin location = C:\Program Files\nodejs\node.exe
2018-12-23T11:09:27.8300282Z ; cwd = D:\a\1\s\client
2018-12-23T11:09:27.8300340Z ; HOME = C:\Users\VssAdministrator
2018-12-23T11:09:27.8300451Z ; "npm config ls -l" to show all defaults.
2018-12-23T11:09:27.8300495Z
2018-12-23T11:09:27.8300930Z [command]C:\Windows\system32\cmd.exe /D /S /C ""C:\Program Files\nodejs\npm.cmd" run e2e:ci"
2018-12-23T11:09:30.8886103Z events.js:183
2018-12-23T11:09:30.8886306Z throw er; // Unhandled 'error' event
2018-12-23T11:09:30.8929743Z ^
2018-12-23T11:09:30.8929831Z
2018-12-23T11:09:30.8929890Z Error: read ECONNRESET
2018-12-23T11:09:30.8929964Z at TLSWrap.onread (net.js:622:25)
2018-12-23T11:09:30.8930031Z npm ERR! code ELIFECYCLE
2018-12-23T11:09:30.8930094Z npm ERR! errno 1
2018-12-23T11:09:30.8930157Z npm ERR! icepp#0.0.1 e2e:ci: `ng e2e --configuration=ci`
2018-12-23T11:09:30.8930238Z npm ERR! Exit status 1
2018-12-23T11:09:30.8930294Z npm ERR!
2018-12-23T11:09:30.8930362Z npm ERR! Failed at the icepp#0.0.1 e2e:ci script.
2018-12-23T11:09:30.8930448Z npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
2018-12-23T11:09:30.8930548Z
2018-12-23T11:09:30.8930611Z npm ERR! A complete log of this run can be found in:
2018-12-23T11:09:30.8930709Z npm ERR! C:\npm\cache\_logs\2018-12-23T11_09_30_852Z-debug.log
2018-12-23T11:09:30.8930759Z
2018-12-23T11:09:30.8930816Z > icepp#0.0.1 e2e:ci D:\a\1\s\client
2018-12-23T11:09:30.8930888Z > ng e2e --configuration=ci
2018-12-23T11:09:30.8930927Z
2018-12-23T11:09:30.8931013Z [11:09:30] I/file_manager - creating folder D:\a\1\s\client\node_modules\protractor\node_modules\webdriver-manager\selenium
2018-12-23T11:09:30.8931178Z [11:09:30] I/config_source - curl -oD:\a\1\s\client\node_modules\protractor\node_modules\webdriver-manager\selenium\chrome-response.xml https://chromedriver.storage.googleapis.com/
2018-12-23T11:09:30.9440180Z Found npm debug log, make sure the path matches with the one in npm's output: C:\npm\cache\_logs\2018-12-23T11_09_30_852Z-debug.log
2018-12-23T11:09:30.9440341Z 0 info it worked if it ends with ok
2018-12-23T11:09:30.9440416Z 1 verbose cli [ 'C:\\Program Files\\nodejs\\node.exe',
2018-12-23T11:09:30.9440540Z 1 verbose cli 'C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js',
2018-12-23T11:09:30.9442090Z 1 verbose cli 'run',
2018-12-23T11:09:30.9442167Z 1 verbose cli 'e2e:ci' ]
2018-12-23T11:09:30.9442227Z 2 info using npm#6.4.1
2018-12-23T11:09:30.9442298Z 3 info using node#v8.12.0
2018-12-23T11:09:30.9442532Z 4 verbose run-script [ 'pree2e:ci', 'e2e:ci', 'poste2e:ci' ]
2018-12-23T11:09:30.9442602Z 5 info lifecycle icepp#0.0.1~pree2e:ci: icepp#0.0.1
2018-12-23T11:09:30.9442681Z 6 info lifecycle icepp#0.0.1~e2e:ci: icepp#0.0.1
2018-12-23T11:09:30.9442752Z 7 verbose lifecycle icepp#0.0.1~e2e:ci: unsafe-perm in lifecycle true
2018-12-23T11:09:30.9443270Z 8 verbose lifecycle icepp#0.0.1~e2e:ci: PATH: C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin;D:\a\1\s\client\node_modules\.bin;C:\agents\2.144.0\externals\git\cmd;C:\tools\mingw64\bin;C:\Program Files\dotnet;C:\mysql-5.7.21-winx64\bin;C:\Program Files\Java\jdk1.8.0_192\bin;C:\npm\prefix;C:\hostedtoolcache\windows\Ruby\2.5.0\x64\bin;C:\Go1.11\bin;C:\Program Files\Git\bin;C:\Program Files\Git\usr\bin;C:\Program Files\Git\mingw64\bin;C:\Program Files (x86)\Microsoft SDKs\Azure\CLI2\wbin;C:\Program Files (x86)\Microsoft Visual Studio\Shared\Python36_64\Scripts;C:\Program Files (x86)\Microsoft Visual Studio\Shared\Python36_64;C:\Program Files\Microsoft MPI\Bin\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\ProgramData\Chocolatey\bin;C:\Program Files\Docker;C:\Program Files\dotnet\;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Program Files (x86)\Microsoft SQL Server\110\DTS\Binn\;C:\Program Files (x86)\Microsoft SQL Server\120\DTS\Binn\;C:\Program Files (x86)\Microsoft SQL Server\130\DTS\Binn\;C:\Program Files (x86)\Microsoft SQL Server\140\DTS\Binn\;C:\Program Files\Microsoft Service Fabric\bin\Fabric\Fabric.Code;C:\Program Files\Microsoft SDKs\Service Fabric\Tools\ServiceFabricLocalClusterManager;C:\Program Files\Git\cmd;C:\Program Files (x86)\Subversion\bin;C:\Program Files\nodejs\;C:\Program Files\CMake\bin;C:\Program Files\Mercurial;C:\Users\VssAdministrator\AppData\Local\Microsoft\WindowsApps
2018-12-23T11:09:30.9444142Z 9 verbose lifecycle icepp#0.0.1~e2e:ci: CWD: D:\a\1\s\client
2018-12-23T11:09:30.9444233Z 10 silly lifecycle icepp#0.0.1~e2e:ci: Args: [ '/d /s /c', 'ng e2e --configuration=ci' ]
2018-12-23T11:09:30.9444330Z 11 silly lifecycle icepp#0.0.1~e2e:ci: Returned: code: 1 signal: null
2018-12-23T11:09:30.9444416Z 12 info lifecycle icepp#0.0.1~e2e:ci: Failed to exec e2e:ci script
2018-12-23T11:09:30.9444491Z 13 verbose stack Error: icepp#0.0.1 e2e:ci: `ng e2e --configuration=ci`
2018-12-23T11:09:30.9444567Z 13 verbose stack Exit status 1
2018-12-23T11:09:30.9444648Z 13 verbose stack at EventEmitter.<anonymous> (C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\index.js:301:16)
2018-12-23T11:09:30.9444737Z 13 verbose stack at emitTwo (events.js:126:13)
2018-12-23T11:09:30.9444816Z 13 verbose stack at EventEmitter.emit (events.js:214:7)
2018-12-23T11:09:30.9444920Z 13 verbose stack at ChildProcess.<anonymous> (C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\lib\spawn.js:55:14)
2018-12-23T11:09:30.9444998Z 13 verbose stack at emitTwo (events.js:126:13)
2018-12-23T11:09:30.9445080Z 13 verbose stack at ChildProcess.emit (events.js:214:7)
2018-12-23T11:09:30.9445153Z 13 verbose stack at maybeClose (internal/child_process.js:915:16)
2018-12-23T11:09:30.9445248Z 13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)
2018-12-23T11:09:30.9445316Z 14 verbose pkgid icepp#0.0.1
2018-12-23T11:09:30.9445388Z 15 verbose cwd D:\a\1\s\client
2018-12-23T11:09:30.9445445Z 16 verbose Windows_NT 10.0.14393
2018-12-23T11:09:30.9445539Z 17 verbose argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "run" "e2e:ci"
2018-12-23T11:09:30.9445621Z 18 verbose node v8.12.0
2018-12-23T11:09:30.9445685Z 19 verbose npm v6.4.1
2018-12-23T11:09:30.9446141Z 20 error code ELIFECYCLE
2018-12-23T11:09:30.9446212Z 21 error errno 1
2018-12-23T11:09:30.9446271Z 22 error icepp#0.0.1 e2e:ci: `ng e2e --configuration=ci`
2018-12-23T11:09:30.9446347Z 22 error Exit status 1
2018-12-23T11:09:30.9446404Z 23 error Failed at the icepp#0.0.1 e2e:ci script.
2018-12-23T11:09:30.9446483Z 23 error This is probably not a problem with npm. There is likely additional logging output above.
2018-12-23T11:09:30.9446568Z 24 verbose exit [ 1, true ]
2018-12-23T11:09:30.9446605Z
2018-12-23T11:09:30.9511523Z ##[error]Error: Npm failed with return code: 1
2018-12-23T11:09:30.9523513Z ##[section]Finishing: Run e2e
I am using Hosted VS2017 agent. I don't think I am missing any module because it works perfectly fine on local environment.
Build Pipeline

Unable to install NPM packages due to path length constraint using NPM 5.X

I'm running Windows 10, NPM v5.5.1, and node v8.9.1.
Edit: I have since updated to node v8.9.4 and npm v5.6.0. The problem remains unchanged.
I set up my development environment on this machine about 2 months ago. I'm using Angular CLI to build my client apps.
Everything was going fine. I added a few packages via NPM without a problem, such as Gulp and ngx-bootstrap. Then I started to run into errors on some of my package installs.
The errors are:
npm ERR! code PATH_LENGTH_EXCEEDED
npm ERR! errno PATH_LENGTH_EXCEEDED
npm ERR! request to https://registry/npmjs.org/{{package}} failed, reason: path length constraint exceeded
npm ERR! A complete log of this run can be found in:
npm ERR! {{npm_cache path}}\_logs\2018-02-08T14_43_40_856Z-debug.log
The contents of that log file are:
0 info it worked if it ends with ok
1 verbose cli [ 'C:\\Program Files\\nodejs\\node.exe',
1 verbose cli 'C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js',
1 verbose cli 'install',
1 verbose cli 'ngx-cookie-service',
1 verbose cli '--save' ]
2 info using npm#5.5.1
3 info using node#v8.9.1
4 verbose npm-session d55be12849534a0a
5 silly install loadCurrentTree
6 silly install readLocalPackageData
7 silly fetchPackageMetaData error for ngx-cookie-service#latest request to https://registry.npmjs.org/ngx-cookie-service failed, reason: path length constraint exceeded
8 verbose type system
9 verbose stack FetchError: request to https://registry.npmjs.org/ngx-cookie-service failed, reason: path length constraint exceeded
9 verbose stack at ClientRequest.req.on.err (C:\Program Files\nodejs\node_modules\npm\node_modules\pacote\node_modules\make-fetch-happen\node_modules\node-fetch-npm\src\index.js:68:14)
9 verbose stack at emitOne (events.js:116:13)
9 verbose stack at ClientRequest.emit (events.js:211:7)
9 verbose stack at TLSSocket.socketErrorListener (_http_client.js:387:9)
9 verbose stack at emitOne (events.js:116:13)
9 verbose stack at TLSSocket.emit (events.js:211:7)
9 verbose stack at emitErrorNT (internal/streams/destroy.js:64:8)
9 verbose stack at _combinedTickCallback (internal/process/next_tick.js:138:11)
9 verbose stack at process._tickCallback (internal/process/next_tick.js:180:9)
10 verbose cwd C:\Development\test
11 verbose Windows_NT 10.0.15063
12 verbose argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "ngx-cookie-service" "--save"
13 verbose node v8.9.1
14 verbose npm v5.5.1
15 error code PATH_LENGTH_EXCEEDED
16 error errno PATH_LENGTH_EXCEEDED
17 error request to https://registry.npmjs.org/ngx-cookie-service failed, reason: path length constraint exceeded
18 verbose exit [ 1, true ]
I researched this, and found the Windows 10 file path 260 character limitation. I thought that npm version 3.1.0 should have fixed this issue, but I decided to followed the instructions in this answer, because I'm still running into this issue despite using NPM v5.5.1.
I found that my version of Windows was prior to the roll out of the feature that lets you disable this limitation. I updated to Version 1703 (OS Build 15063.483), and to enable Win32 long paths.
Yet I'm still getting the error, and unable to install a variety of npm packages.
In testing to see if it was an issue with packages that have a lot of dependencies, I tried installing or reinstalling a couple of other packages.
Some fail with the errors above. Others succeed with the following warnings:
npm WARN Unexepcted warming for https://registry.npmjs.org/: Miscellaneous Warning PATH_LENGTH_EXCEEDED: request to https://registry.npmjs.org/{{package name}} failed, reason: path length constraint exceeded
npm WARN Using stale package data from https://registry.npmjs.org/ due to a request error during validation
Packages throwing the error include:
jslint
ngx-cookie-service
chart.js
angular-cli
Packages that throw the warnings include:
font-awesome
#angular/cli
moment
ngx-bootstrap
bootstrap
jasmine
I suspect that something has changed, either in a policy on my workstation, or in our network security, that is causing this. All of the packages that succeed seem to be packages that I had previously installed, either as a direct install, or as a dependency of #angular/cli (one of the first packages I installed). I'm assuming that the stale package data warning indicates that whatever problem I have with the path length is preventing updated data being retrieved, and therefore npm is falling back to cached data from previous installations of the selected package and its dependencies.
So now I'm stumped as to how to diagnose exactly where the issue is happening. If its a security policy that changed, then I need to be able to describe exactly what is being blocked so that I can work with our security department to fix this. But the only information I can find about the PATH_LENGTH_EXCEEDED errors lead me to old information about versions of npm prior to 3.1.0.
How can I identify the source of this problem?
After additional searching, I found references to path length exceeded with regards to SSL/TLS certificate authorities. I tested this issue by changing the npm registry to use http instead of https (note: this is a temporary step only; I have turned https back on once I verified the issue):
npm config set registry http://registry.npmjs.org/
This allowed me to install the problematic packages.
It seems the underlying cause is SSL Inspection performed by our network security team. The decryption, inspection, and re-encryption process, and subsequent changes in the Issuing Authority on the certificate, apparently triggers this error.

npm publish wants to publish only to npm repository

I am using VSTS as NPM private repo but if I want to do npm publish always want's to publish not to my private repo but to the npm public repo.
I have installed
npm install -g vsts-npm-auth --registry https://registry.npmjs.com --always-auth false
Than i have done this:
vsts-npm-auth -config .npmrc
And my .npmrc file contains this
registry=https://myhost/_packaging/myfeed/npm/registry/
always-auth=true
I also used
"publishConfig": {
"registry": "https://myhost/_packaging/myfeed/npm/registry/"
},
To ovverride the registry but without success. It always want's to publish to the npm repo
npm ERR! Windows_NT 10.0.14393
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "publish"
npm ERR! node v7.7.3
npm ERR! npm v4.1.2
npm ERR! code ENEEDAUTH
npm ERR! need auth auth required for publishing
npm ERR! need auth You need to authorize this machine using `npm adduser`
0 info it worked if it ends with ok
1 verbose cli [ 'C:\\Program Files\\nodejs\\node.exe',
1 verbose cli 'C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js',
1 verbose cli 'publish' ]
2 info using npm#4.1.2
3 info using node#v7.7.3
4 verbose publish [ '.' ]
5 silly cache add args [ '.', null ]
6 verbose cache add spec .
7 silly cache add parsed spec Result {
7 silly cache add raw: '.',
7 silly cache add scope: null,
7 silly cache add escapedName: null,
7 silly cache add name: null,
7 silly cache add rawSpec: '.',
7 silly cache add spec: 'C:\\temp\\empty-list',
7 silly cache add type: 'directory' }
8 verbose addLocalDirectory C:\Users\cpi\AppData\Roaming\npm-cache\#systems\empty-list\1.0.0\package.tgz not in flight; packing
9 verbose correctMkdir C:\Users\cpi\AppData\Roaming\npm-cache correctMkdir not in flight; initializing
10 warn prepublish-on-install As of npm#5, `prepublish` scripts will run only for `npm publish`.
11 warn prepublish-on-install (In npm#4 and previous versions, it also runs for `npm install`.)
12 warn prepublish-on-install See the deprecation note in `npm help scripts` for more information.
13 info lifecycle #systems/empty-list#1.0.0~prepublish: #systems/empty-list#1.0.0
14 verbose lifecycle #systems/empty-list#1.0.0~prepublish: unsafe-perm in lifecycle true
15 verbose lifecycle #systems/empty-list#1.0.0~prepublish: PATH: C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin;C:\temp\empty-list\node_modules\.bin;C:\Program Files\ConEmu\ConEmu\Scripts;C:\Program Files\ConEmu;C:\Program Files\ConEmu\ConEmu;C:\Program Files\Java\jdk1.8.0_121\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Program Files (x86)\Microsoft Emulator Manager\1.0\;C:\Program Files\nodejs\;C:\Program Files (x86)\Skype\Phone\;C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\110\Tools\Binn\;C:\Program Files (x86)\Microsoft SQL Server\120\Tools\Binn\;C:\Program Files\Microsoft SQL Server\120\Tools\Binn\;C:\Program Files\Microsoft SQL Server\120\DTS\Binn\;C:\Program Files (x86)\Microsoft SQL Server\120\Tools\Binn\ManagementStudio\;C:\Program Files (x86)\Microsoft SQL Server\120\DTS\Binn\;C:\Program Files\dotnet\;C:\Program Files\Microsoft\Web Platform Installer\;C:\Program Files (x86)\Microsoft SQL Server\Client SDK\ODBC\130\Tools\Binn\;C:\Program Files (x86)\Microsoft SQL Server\140\Tools\Binn\;C:\Program Files (x86)\Microsoft SQL Server\140\DTS\Binn\;C:\Program Files (x86)\Microsoft SQL Server\140\Tools\Binn\ManagementStudio\;C:\Program Files\Git\cmd;C:\Users\cpi\AppData\Local\Microsoft\WindowsApps;C:\Users\cpi\AppData\Roaming\npm;C:\Program Files\Microsoft VS Code Insiders\bin
16 verbose lifecycle #systems/empty-list#1.0.0~prepublish: CWD: C:\temp\empty-list
17 silly lifecycle #systems/empty-list#1.0.0~prepublish: Args: [ '/d /s /c', 'ngc && npm run build' ]
18 silly lifecycle #systems/empty-list#1.0.0~prepublish: Returned: code: 0 signal: null
19 info lifecycle #systems/empty-list#1.0.0~prepare: #systems/empty-list#1.0.0
20 silly lifecycle #systems/empty-list#1.0.0~prepare: no script for prepare, continuing
21 verbose tar pack [ 'C:\\Users\\cpi\\AppData\\Roaming\\npm-cache\\#systems\\empty-list\\1.0.0\\package.tgz',
21 verbose tar pack 'C:\\temp\\empty-list' ]
22 verbose tarball C:\Users\cpi\AppData\Roaming\npm-cache\#systems\empty-list\1.0.0\package.tgz
23 verbose folder C:\temp\empty-list
24 verbose addLocalTarball adding from inside cache C:\Users\cpi\AppData\Roaming\npm-cache\#systems\empty-list\1.0.0\package.tgz
25 verbose correctMkdir C:\Users\cpi\AppData\Roaming\npm-cache correctMkdir not in flight; initializing
26 silly cache afterAdd #systems/empty-list#1.0.0
27 verbose afterAdd C:\Users\cpi\AppData\Roaming\npm-cache\#systems\empty-list\1.0.0\package\package.json not in flight; writing
28 verbose correctMkdir C:\Users\cpi\AppData\Roaming\npm-cache correctMkdir not in flight; initializing
29 verbose afterAdd C:\Users\cpi\AppData\Roaming\npm-cache\#systems\empty-list\1.0.0\package\package.json written
30 silly publish { name: '#systems/empty-list',
30 silly publish version: '1.0.0',
30 silly publish description: 'An empty list',
30 silly publish scripts:
30 silly publish { clean: 'rimraf bundles coverage src/**/*.d.ts src/**/*.metadata.json src/**/*.js tests/**/*.d.ts tests/**/*.metadata.json tests/**/*.js index.d.ts index.metadata.json index.js',
30 silly publish test: 'karma start',
30 silly publish 'test-watch': 'karma start --singleRun=false --autoWatch=true',
30 silly publish prepublish: 'ngc && npm run build',
30 silly publish build: 'webpack',
30 silly publish 'semantic-release': 'semantic-release pre && npm publish && semantic-release post' },
30 silly publish repository:
30 silly publish { type: 'git',
30 silly publish url: 'git+https://github.com/systems/empty-list.git' },
30 silly publish keywords: [ 'angular', 'angular 2', 'i18n', 'translate', 'ngx-translate' ],
30 silly publish publishConfig: { registry: 'https://systems.pkgs.visualstudio.com/_packaging/Systems.Test-Packages/npm/registry/' },
30 silly publish author: { name: 'Martin Pfeifhofer' },
30 silly publish license: 'MIT',
30 silly publish bugs: { url: 'https://github.com/systems/empty-list/issues' },
30 silly publish homepage: 'https://github.com/systems/empty-list#readme',
30 silly publish main: 'bundles/empty-list.umd.js',
30 silly publish module: 'index.js',
30 silly publish typings: 'index.d.ts',
30 silly publish peerDependencies:
30 silly publish { '#ngx-translate/core': '>=6.0.0',
30 silly publish '#angular/core': '>=4.3.0',
30 silly publish '#angular/common': '>=4.3.0' },
30 silly publish devDependencies:
30 silly publish { '#angular/animations': '4.3.1',
30 silly publish '#angular/common': '4.3.1',
30 silly publish '#angular/compiler': '4.3.1',
30 silly publish '#angular/compiler-cli': '4.3.1',
30 silly publish '#angular/core': '4.3.1',
30 silly publish '#angular/platform-browser': '4.3.1',
30 silly publish '#angular/platform-browser-dynamic': '4.3.1',
30 silly publish '#angular/platform-server': '4.3.1',
30 silly publish '#ngx-translate/core': '^7.0.0',
30 silly publish '#types/hammerjs': '2.0.34',
30 silly publish '#types/jasmine': '2.5.51',
30 silly publish '#types/node': '7.0.28',
30 silly publish 'awesome-typescript-loader': '3.1.3',
30 silly publish 'clean-webpack-plugin': '0.1.16',
30 silly publish codelyzer: '3.0.1',
30 silly publish commitizen: '2.9.6',
30 silly publish 'core-js': '2.4.1',
30 silly publish 'cz-conventional-changelog': '2.0.0',
30 silly publish 'istanbul-instrumenter-loader': '2.0.0',
30 silly publish 'jasmine-core': '2.6.2',
30 silly publish karma: '1.7.0',
30 silly publish 'karma-chrome-launcher': '2.1.1',
30 silly publish 'karma-coverage': '1.1.1',
30 silly publish 'karma-jasmine': '1.1.0',
30 silly publish 'karma-mocha-reporter': '2.2.3',
30 silly publish 'karma-remap-coverage': '0.1.4',
30 silly publish 'karma-sourcemap-loader': '0.3.7',
30 silly publish 'karma-webpack': '2.0.3',
30 silly publish 'loader-utils': '1.1.0',
30 silly publish 'reflect-metadata': '0.1.10',
30 silly publish rimraf: '2.6.1',
30 silly publish rxjs: '5.4.0',
30 silly publish 'semantic-release': '6.3.6',
30 silly publish 'source-map-loader': '0.2.1',
30 silly publish 'ts-helpers': '1.1.2',
30 silly publish tslint: '5.4.3',
30 silly publish 'tslint-loader': '3.5.3',
30 silly publish typescript: '2.3.4',
30 silly publish webpack: '3.0.0-rc.1',
30 silly publish 'zone.js': '0.8.11' },
30 silly publish config: { commitizen: { path: './node_modules/cz-conventional-changelog' } },
30 silly publish dependencies: { '#ngx-translate/http-loader': '^1.0.2' },
30 silly publish readme: '',
30 silly publish readmeFilename: 'README.md',
30 silly publish gitHead: '1d90b2d0696dc11ae80de565cd09d432db693b98',
30 silly publish _id: '#systems/empty-list#1.0.0',
30 silly publish _shasum: 'fbb07f54e36cbd754375bffebaab79d9903f7c60',
30 silly publish _from: '.' }
31 info lifecycle #systems/empty-list#1.0.0~prepublishOnly: #systems/empty-list#1.0.0
32 silly lifecycle #systems/empty-list#1.0.0~prepublishOnly: no script for prepublishOnly, continuing
33 verbose getPublishConfig { registry: 'https://xxx.pkgs.visualstudio.com/_packaging/Systems.Test-Packages/npm/registry/' }
34 silly mapToRegistry name #systems/empty-list
35 silly mapToRegistry scope (from package name) #systems
36 verbose mapToRegistry no registry URL found in name for scope #systems
37 silly mapToRegistry using default registry
38 silly mapToRegistry registry https://xxx.pkgs.visualstudio.com/_packaging/Systems.Test-Packages/npm/registry/
39 silly mapToRegistry data Result {
39 silly mapToRegistry raw: '#systems/empty-list',
39 silly mapToRegistry scope: '#systems',
39 silly mapToRegistry escapedName: '#systems%2fempty-list',
39 silly mapToRegistry name: '#systems/empty-list',
39 silly mapToRegistry rawSpec: '',
39 silly mapToRegistry spec: 'latest',
39 silly mapToRegistry type: 'tag' }
40 silly mapToRegistry uri https://xxx.pkgs.visualstudio.com/_packaging/Systems.Test-Packages/npm/registry/#systems%2fempty-list
41 verbose publish registryBase https://xxx.pkgs.visualstudio.com/_packaging/Systems.Test-Packages/npm/registry/
42 silly publish uploading C:\Users\cpi\AppData\Roaming\npm-cache\#systems\empty-list\1.0.0\package.tgz
43 verbose stack Error: auth required for publishing
43 verbose stack at CachingRegistryClient.publish (C:\Program Files\nodejs\node_modules\npm\node_modules\npm-registry-client\lib\publish.js:30:14)
43 verbose stack at C:\Program Files\nodejs\node_modules\npm\lib\publish.js:137:14
43 verbose stack at mapToRegistry (C:\Program Files\nodejs\node_modules\npm\lib\utils\map-to-registry.js:62:3)
43 verbose stack at publish_ (C:\Program Files\nodejs\node_modules\npm\lib\publish.js:108:3)
43 verbose stack at Array.<anonymous> (C:\Program Files\nodejs\node_modules\npm\node_modules\slide\lib\bind-actor.js:15:8)
43 verbose stack at LOOP (C:\Program Files\nodejs\node_modules\npm\node_modules\slide\lib\chain.js:15:14)
43 verbose stack at C:\Program Files\nodejs\node_modules\npm\node_modules\slide\lib\chain.js:18:7
43 verbose stack at done (C:\Program Files\nodejs\node_modules\npm\lib\utils\lifecycle.js:132:5)
43 verbose stack at LOOP (C:\Program Files\nodejs\node_modules\npm\node_modules\slide\lib\chain.js:7:26)
43 verbose stack at C:\Program Files\nodejs\node_modules\npm\node_modules\slide\lib\chain.js:18:7
44 verbose cwd C:\temp\empty-list
45 error Windows_NT 10.0.14393
46 error argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "publish"
47 error node v7.7.3
48 error npm v4.1.2
49 error code ENEEDAUTH
50 error need auth auth required for publishing
51 error need auth You need to authorize this machine using `npm adduser`
52 verbose exit [ 1, true ]
UPDATE: MyHome/.npmrc
//systems.pkgs.visualstudio.com/_packaging/Systems.Angular-Packages/npm/registry/:_authToken=xxxx
ok clearing the .npmrc file in my home folder and rerun vsts-npm-auth -config .npmrc folder solves the problem. Thanks to #starain-MSFT for his hint.