question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

With version 12.2, the dependencies no longer install behind corporate registry

See original GitHub issue

🐞 Bug report

Command (mark with an x)

  • new
  • build
  • serve
  • test
  • e2e
  • generate
  • add
  • update
  • lint
  • extract-i18n
  • run
  • config
  • help
  • version
  • doc

Is this a regression?

Yes, it works in the latest 12.1

Description

The esbuilder dependency tries to install its own dependencies in a post-install script and fails behind a corporate proxy / registry. See these (maybe related) issues: https://github.com/evanw/esbuild/issues/1382 https://github.com/evanw/esbuild/issues/1485, apparently this is correct behavior, but now it affects angular CLI as well.

🔬 Minimal Reproduction

I cannot create an online repoduction of this.

🔥 Exception or Error


> esbuild@0.12.17 postinstall C:\Repos\myrepo\node_modules\esbuild
> node install.js

Trying to install "esbuild-windows-64" using npm
Failed to install "esbuild-windows-64" using npm: Command failed: npm install --loglevel=error --prefer-offline --no-audit --progress=false esbuild-windows-64@0.12.17
npm ERR! code E401
npm ERR! Unable to authenticate, need: Basic realm="http://ourcorporateregistry", Negotiate, NTLM

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\myuser\AppData\Roaming\npm-cache\_logs\2021-08-09T05_52_58_429Z-debug.log

Trying to download "https://registry.npmjs.org/esbuild-windows-64/-/esbuild-windows-64-0.12.17.tgz"
Failed to download "https://registry.npmjs.org/esbuild-windows-64/-/esbuild-windows-64-0.12.17.tgz": connect ECONNREFUSED 104.16.22.35:443

🌍 Your Environment


Angular CLI: 12.2.0
Node: 12.21.0
Package Manager: npm 6.14.11
OS: win32 x64

Angular: 12.2.0
... cli, compiler, compiler-cli, core, language-service

Package                         Version
---------------------------------------------------------
@angular-devkit/architect       0.1202.0
@angular-devkit/build-angular   12.2.0
@angular-devkit/core            12.2.0
@angular-devkit/schematics      12.1.3
@schematics/angular             12.1.3
ng-packagr                      12.2.0
rxjs                            6.6.7
typescript                      4.3.5

Anything else relevant? 64-bit Windows 10 behind a corporate (Azure Artifacts) registry

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:7 (1 by maintainers)

github_iconTop GitHub Comments

3reactions
alan-agius4commented, Aug 9, 2021

Indeed, I don’t see this as being actionable from our end. That said, the fact that it doesn’t use the local NPMRC files seem like a different ESbuild bug.

This is caused because the CWD is changed from the project root to a temp directory, which caused the local NPMRC files not to be read by NPM/Yarn.

See: https://github.com/evanw/esbuild/blob/eb2872e1ab4ae09bef6fae71db6eb2381ede131b/lib/npm/install.ts#L178

I also suggest to subscribe to https://github.com/evanw/esbuild/issues/789

1reaction
woppa684commented, Sep 29, 2021

@alan-agius4 I see that the esbuild bug you mentioned should be solved. Does that also mean that it is also solved in Angular CLI? And it is only solved in v13 then, right? I see 12.2.7 still uses a 0.12.x version of esbuild. If this is the case, would it be possible to put the fixed version in 12.2.8 (if there is still a version coming up)? Upgrading to Angular 13 is not planned soon for our company.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Package '@angular/cli' is not a dependency - Stack Overflow
Using package manager: 'npm' Collecting installed dependencies... Found 28 dependencies. Package '@angular/cli' is not a dependency.
Read more >
Xcode 13.1 will gets "stuck" on iOS Monterey/ New 2021 pro
I have been trying to download Xcode 13.1 on the new 16" MacBook pro-2021, with iOS Monterey and it keeps getting stuck at...
Read more >
Dameware 12.2.1 release notes - SolarWinds Documentation
Learn about the new features and improvements for Dameware. The release notes list issues fixed in the release, open issues, and important installation...
Read more >
Spring Boot Reference Documentation
Try the How-to documents. They provide solutions to the most common questions. Learn the Spring basics. Spring Boot builds on many other Spring...
Read more >
Docker Engine release notes - Docker Documentation
This release of Docker Engine contains updated versions of Docker Compose, ... proxies configured through the $HTTP_PROXY environment variable are no longer ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found