<h3 dir="auto">Is there an existing issue for this?</h3>
<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the existing issues</li>
</ul>
<h3 dir="auto">This issue exists in the latest npm version</h3>
<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I am using the latest npm</li>
</ul>
<h3 dir="auto">Current Behavior</h3>
<p dir="auto">npm ERR! network Invalid response body while trying to fetch <a href="https://registry.npmjs.org/postcss-import" rel="nofollow">https://registry.npmjs.org/postcss-import</a>: Socket timeout<br>
npm ERR! network This is a problem related to network connectivity.<br>
npm ERR! network In most cases you are behind a proxy or have bad network settings.<br>
npm ERR! network<br>
npm ERR! network If you are behind a proxy, please make sure that the<br>
npm ERR! network 'proxy' config is set properly.  See: 'npm help config'</p>
<p dir="auto">npm ERR! A complete log of this run can be found in:<br>
npm ERR!     /home/bentex/.npm/_logs/2022-03-11T08_41_06_921Z-debug-0.log<br>
<g-emoji class="g-emoji" alias="heavy_multiplication_x" fallback-src="https://github.githubassets.com/images/icons/emoji/unicode/2716.png">✖</g-emoji> Package install failed, see above.<br>
The Schematic workflow failed. See above.</p>
<h3 dir="auto">Expected Behavior</h3>
<p dir="auto">I expect to  create a new angular project  using the command ng new but seems theres a socket timeout each time i try</p>
<h3 dir="auto">Steps To Reproduce</h3>
<ol dir="auto">
<li>In this environment... linux distro parrotOs</li>
<li>With this config...</li>
<li>Run '...' ng new ..</li>
<li>See error...</li>
</ol>
<h3 dir="auto">Environment</h3>
<p dir="auto">npm -v<br>
8.3.1</p>
<p dir="auto">$node -v<br>
v17.4.0</p>
<p dir="auto">"user" config from /home/bentex/.npmrc</p>
<p dir="auto">legacy-peer-deps = true</p>
<p dir="auto">; node bin location = /home/bentex/.nvm/versions/node/v17.4.0/bin/node</p>
<h3 dir="auto">Current Behavior:</h3>
<p dir="auto">When trying to install packages, without a previous cache, we get constant timeouts when trying to fetch packages, both locally and in a CI environment. The package that fails is always different, so there isn't a specific package causing the issue.</p>
<p dir="auto">Stack trace:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="19505 verbose stack FetchError: request to https://.../npm/registry/typescript/-/typescript-4.1.3.tgz failed, reason: Socket timeout
19505 verbose stack     at ClientRequest.&lt;anonymous&gt; (C:\npm\prefix\node_modules\npm\node_modules\minipass-fetch\lib\index.js:97:14)
19505 verbose stack     at ClientRequest.emit (events.js:315:20)
19505 verbose stack     at TLSSocket.socketErrorListener (_http_client.js:469:9)
19505 verbose stack     at TLSSocket.emit (events.js:327:22)
19505 verbose stack     at emitErrorNT (internal/streams/destroy.js:106:8)
19505 verbose stack     at emitErrorCloseNT (internal/streams/destroy.js:74:3)
19505 verbose stack     at processTicksAndRejections (internal/process/task_queues.js:80:21)
19506 verbose cwd D:\a\1\s
19507 verbose Windows_NT 10.0.17763
19508 verbose argv &quot;C:\\hostedtoolcache\\windows\\node\\14.15.4\\x64\\node.exe&quot; &quot;C:\\npm\\prefix\\node_modules\\npm\\bin\\npm-cli.js&quot; &quot;ci&quot; &quot;--no-audit&quot;
19509 verbose node v14.15.4
19510 verbose npm  v7.9.0
19511 error code ERR_SOCKET_TIMEOUT
19512 error errno ERR_SOCKET_TIMEOUT
19513 error request to https://.../npm/registry/typescript/-/typescript-4.1.3.tgz failed, reason: Socket timeout
19514 verbose exit 1"><pre class="notranslate"><code class="notranslate">19505 verbose stack FetchError: request to https://.../npm/registry/typescript/-/typescript-4.1.3.tgz failed, reason: Socket timeout
19505 verbose stack     at ClientRequest.&lt;anonymous&gt; (C:\npm\prefix\node_modules\npm\node_modules\minipass-fetch\lib\index.js:97:14)
19505 verbose stack     at ClientRequest.emit (events.js:315:20)
19505 verbose stack     at TLSSocket.socketErrorListener (_http_client.js:469:9)
19505 verbose stack     at TLSSocket.emit (events.js:327:22)
19505 verbose stack     at emitErrorNT (internal/streams/destroy.js:106:8)
19505 verbose stack     at emitErrorCloseNT (internal/streams/destroy.js:74:3)
19505 verbose stack     at processTicksAndRejections (internal/process/task_queues.js:80:21)
19506 verbose cwd D:\a\1\s
19507 verbose Windows_NT 10.0.17763
19508 verbose argv "C:\\hostedtoolcache\\windows\\node\\14.15.4\\x64\\node.exe" "C:\\npm\\prefix\\node_modules\\npm\\bin\\npm-cli.js" "ci" "--no-audit"
19509 verbose node v14.15.4
19510 verbose npm  v7.9.0
19511 error code ERR_SOCKET_TIMEOUT
19512 error errno ERR_SOCKET_TIMEOUT
19513 error request to https://.../npm/registry/typescript/-/typescript-4.1.3.tgz failed, reason: Socket timeout
19514 verbose exit 1
</code></pre></div>
<p dir="auto">Tried using the fetch-retries, fetch-retry-mintimeout, and fetch-retry-maxtimeout options, but didn't seem to have any effect.</p>
<h3 dir="auto">Expected Behavior:</h3>
<p dir="auto">Install packages without timing out.</p>
<h3 dir="auto">Steps To Reproduce:</h3>
<p dir="auto">Using a project with workspaces (~6425 packages)<br>
No cache available<br>
Run <code class="notranslate">npm ci</code></p>
<h3 dir="auto">Environment:</h3>
<p dir="auto">OS: Mac OS 11.2.3 or Windows 10<br>
Node: 14.15.4<br>
npm: 7.9.0</p>