title: "Cannot read property 'match' of undefined" during Npm install
body: <p>I encountered error during  building Jenkins</p>
  <p><strong>Jenkins Log</strong></p>
  <blockquote>
  <blockquote>
  <p>Task :api:processResources
  Task :api:classes
  Task :web:nodeSetup
  Task :web:npmSetup /var/lib/jenkins/workspace/hds_v2_docker/web/.gradle/npm/npm-v6.11.2/bin/npm
  -&gt; /var/lib/jenkins/workspace/hds_v2_docker/web/.gradle/npm/npm-v6.11.2/lib/node_modules/npm/bin/npm-cli.js
  /var/lib/jenkins/workspace/hds_v2_docker/web/.gradle/npm/npm-v6.11.2/bin/npx
  -&gt; /var/lib/jenkins/workspace/hds_v2_docker/web/.gradle/npm/npm-v6.11.2/lib/node_modules/npm/bin/npx-cli.js</p>
  </blockquote>
  <ul>
  <li>npm@6.11.2 added 430 packages from 832 contributors in 6.837s</li>
  </ul>
  <blockquote>
  <p>Task :web:npmInstall FAILED npm ERR! Cannot read property 'match' of undefined</p>
  </blockquote>
  <p>npm ERR! A complete log of this run can be found in: npm ERR!<br />
  /var/lib/jenkins/.npm/_logs/2019-10-16T01_11_20_594Z-debug.log</p>
  <p>FAILURE: Build failed with an exception.</p>
  <ul>
  <li>What went wrong: Execution failed for task ':web:npmInstall'.</li>
  </ul>
  <blockquote>
  <p>Process 'command '/var/lib/jenkins/workspace/hds_v2_docker/web/.gradle/npm/npm-v6.11.2/bin/npm''
  finished with non-zero exit value 1</p>
  </blockquote>
  <ul>
  <li><p>Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.</p>
  </li>
  <li><p>Get more help at <a href="https://help.gradle.org" rel="noreferrer">https://help.gradle.org</a></p>
  </li>
  </ul>
  <p>Deprecated Gradle features were used in this build, making it
  incompatible with Gradle 6.0. Use '--warning-mode all' to show the
  individual deprecation warnings. See
  <a href="https://docs.gradle.org/5.0/userguide/command_line_interface.html#sec:command_line_warnings" rel="noreferrer">https://docs.gradle.org/5.0/userguide/command_line_interface.html#sec:command_line_warnings</a></p>
  <p>BUILD FAILED in 33s</p>
  </blockquote>
  <p><strong>/var/lib/jenkins/.npm/_logs/2019-10-16T01_11_20_594Z-debug.log</strong></p>
  <pre><code>17 silly saveTree   │ ├─┬ clean-css@4.2.1
  17 silly saveTree   │ │ └── source-map@0.6.1
  17 silly saveTree   │ ├── commander@2.17.1
  17 silly saveTree   │ └── he@1.2.0
  17 silly saveTree   └─┬ loader-utils@0.2.17
  17 silly saveTree     ├── big.js@3.2.0
  17 silly saveTree     ├── emojis-list@2.1.0
  17 silly saveTree     └── json5@0.5.1
  18 verbose stack TypeError: Cannot read property 'match' of undefined
  18 verbose stack     at tarballToVersion (/usr/local/lib/node_modules/npm/lib/install/inflate-shrinkwrap.js:87:20)
  18 verbose stack     at inflatableChild (/usr/local/lib/node_modules/npm/lib/install/inflate-shrinkwrap.js:99:22)
  18 verbose stack     at BB.each (/usr/local/lib/node_modules/npm/lib/install/inflate-shrinkwrap.js:55:12)
  18 verbose stack     at tryCatcher (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/util.js:16:23)
  18 verbose stack     at Object.gotValue (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/reduce.js:155:18)
  18 verbose stack     at Object.gotAccum (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/reduce.js:144:25)
  18 verbose stack     at Object.tryCatcher (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/util.js:16:23)
  18 verbose stack     at Promise._settlePromiseFromHandler (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:512:31)
  18 verbose stack     at Promise._settlePromise (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:569:18)
  18 verbose stack     at Promise._settlePromiseCtx (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:606:10)
  18 verbose stack     at _drainQueueStep (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:142:12)
  18 verbose stack     at _drainQueue (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:131:9)
  18 verbose stack     at Async._drainQueues (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:147:5)
  18 verbose stack     at Immediate.Async.drainQueues (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:17:14)
  18 verbose stack     at runCallback (timers.js:810:20)
  18 verbose stack     at tryOnImmediate (timers.js:768:5)
  19 verbose cwd /var/lib/jenkins/workspace/hds_v2_docker/web
  20 verbose Linux 4.4.0-59-generic
  21 verbose argv &quot;/usr/bin/node&quot; &quot;/usr/local/bin/npm&quot; &quot;install&quot;
  22 verbose node v8.16.0
  23 verbose npm  v6.9.0
  24 error Cannot read property 'match' of undefined
  25 verbose exit [ 1, true ]
  </code></pre>