Comments (8)
Can you please run the update command with the --verbose
option and provide the output? Thanks.
from angular-cli.
I was attempting to recreate from scratch, unfortunately have the same issue with
ng new --create-application=false
It hangs if I have this in my ~/.npmrc
registry=https://example-company-private-repo.org/
But works if I have
registry=https://registry.npmjs.org
In both examples, the project directory .npmrc has
registry=https://registry.npmjs.org
I can't run ng new with verbose, doesn't seem to be an option
https://angular.io/cli/new
Thanks, Sam
from angular-cli.
@samwootton, I looks like you are reporting a a slightly different issue.
from angular-cli.
@alan-agius4 same issue, just with "new" instead of "update".
I guess as the initial directory just has .nmprc (and there is no ng workspace / project), that .npmrc is ignored and the ~/.npmrc is used. There's no way to specify an .npmrc or registry when running "ng new"?
from angular-cli.
@alan-agius4 I ran with --verbose, you can see from the log here, the ~/.npmrc is being chose (line 11).
You can see I use nvm too. Here's the log output:
0 verbose cli [
0 verbose cli '/Users/sam.wootton/.nvm/versions/node/v16.15.0/bin/node',
0 verbose cli '/Users/sam.wootton/.nvm/versions/node/v16.15.0/bin/npm',
0 verbose cli 'install',
0 verbose cli '@angular/[email protected]',
0 verbose cli '--prefix=/private/var/folders/qw/95f4vfgn1wb8gz402xpx0n6w0000gp/T/angular-cli-packages-StDlIR',
0 verbose cli '--no-package-lock'
0 verbose cli ]
1 info using [email protected]
2 info using [email protected]
3 timing npm:load:whichnode Completed in 0ms
4 timing config:load:defaults Completed in 1ms
5 timing config:load:file:/Users/sam.wootton/.nvm/versions/node/v16.15.0/lib/node_modules/npm/npmrc Completed in 1ms
6 timing config:load:builtin Completed in 1ms
7 timing config:load:cli Completed in 1ms
8 timing config:load:env Completed in 0ms
9 timing config:load:file:/private/var/folders/qw/95f4vfgn1wb8gz402xpx0n6w0000gp/T/angular-cli-packages-StDlIR/.npmrc Completed in 0ms
10 timing config:load:project Completed in 0ms
11 timing config:load:file:/Users/sam.wootton/.npmrc Completed in 2ms
12 timing config:load:user Completed in 2ms
13 timing config:load:file:/private/var/folders/qw/95f4vfgn1wb8gz402xpx0n6w0000gp/T/angular-cli-packages-StDlIR/etc/npmrc Completed in 0ms
14 timing config:load:global Completed in 0ms
15 timing config:load:validate Completed in 1ms
Here is the console output:
sam.wootton@L7S9LXD3-MC1 tyt % ng update @angular/core@17 @angular/cli@17 --verbose
Locating potential npmrc files:
Trying '/Users/sam.wootton/.npmrc'...found.
Trying '/Users/sam.wootton/devspace/personal/tyt/.npmrc'...found.
The installed Angular CLI version is outdated.
Installing a temporary Angular CLI versioned 17.2.3 to perform the update.
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE package: '@angular/[email protected]',
npm WARN EBADENGINE required: {
npm WARN EBADENGINE node: '^18.13.0 || >=20.9.0',
npm WARN EBADENGINE npm: '^6.11.0 || ^7.5.6 || >=8.0.0',
npm WARN EBADENGINE yarn: '>= 1.13.0'
npm WARN EBADENGINE },
npm WARN EBADENGINE current: { node: 'v16.15.0', npm: '8.5.5' }
npm WARN EBADENGINE }
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE package: '@angular-devkit/[email protected]',
npm WARN EBADENGINE required: {
npm WARN EBADENGINE node: '^18.13.0 || >=20.9.0',
npm WARN EBADENGINE npm: '^6.11.0 || ^7.5.6 || >=8.0.0',
npm WARN EBADENGINE yarn: '>= 1.13.0'
npm WARN EBADENGINE },
npm WARN EBADENGINE current: { node: 'v16.15.0', npm: '8.5.5' }
npm WARN EBADENGINE }
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE package: '@angular-devkit/[email protected]',
npm WARN EBADENGINE required: {
npm WARN EBADENGINE node: '^18.13.0 || >=20.9.0',
npm WARN EBADENGINE npm: '^6.11.0 || ^7.5.6 || >=8.0.0',
npm WARN EBADENGINE yarn: '>= 1.13.0'
npm WARN EBADENGINE },
npm WARN EBADENGINE current: { node: 'v16.15.0', npm: '8.5.5' }
npm WARN EBADENGINE }
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE package: '@angular-devkit/[email protected]',
npm WARN EBADENGINE required: {
npm WARN EBADENGINE node: '^18.13.0 || >=20.9.0',
npm WARN EBADENGINE npm: '^6.11.0 || ^7.5.6 || >=8.0.0',
npm WARN EBADENGINE yarn: '>= 1.13.0'
npm WARN EBADENGINE },
npm WARN EBADENGINE current: { node: 'v16.15.0', npm: '8.5.5' }
npm WARN EBADENGINE }
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE package: '@schematics/[email protected]',
npm WARN EBADENGINE required: {
npm WARN EBADENGINE node: '^18.13.0 || >=20.9.0',
npm WARN EBADENGINE npm: '^6.11.0 || ^7.5.6 || >=8.0.0',
npm WARN EBADENGINE yarn: '>= 1.13.0'
npm WARN EBADENGINE },
npm WARN EBADENGINE current: { node: 'v16.15.0', npm: '8.5.5' }
npm WARN EBADENGINE }
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE package: '[email protected]',
npm WARN EBADENGINE required: { node: '>=18' },
npm WARN EBADENGINE current: { node: 'v16.15.0', npm: '8.5.5' }
npm WARN EBADENGINE }
npm ERR! code ENOTFOUND
npm ERR! syscall getaddrinfo
npm ERR! errno ENOTFOUND
npm ERR! network request to https://example-company-private-repo.org/npm/all-npm/@schematics/angular/-/angular-17.2.3.tgz failed, reason: getaddrinfo ENOTFOUND artifactory.ci.gameop.net
npm ERR! network This is a problem related to network connectivity.
npm ERR! network In most cases you are behind a proxy or have bad network settings.
npm ERR! network
npm ERR! network If you are behind a proxy, please make sure that the
npm ERR! network 'proxy' config is set properly. See: 'npm help config'
I think this could be nvm rather than ng.
I could not replicate the original issue when I didn't use NVM.
Issue npm/cli#5460 ?
Sam
from angular-cli.
During ng update
, Angular CLI temporarily installs itself, generating a new directory, such as /private/var/folders/qw/95f4vfgn1wb8gz402xpx0n6w0000gp/T/angular-cli-packages-StDlIR
, where it executes npm install
to fetch the latest Angular CLI version for the update. However, NPM fails to locate the project's .npmrc configuration in this location.
For ng new
, you can utilize the --skip-install
flag, create the .npmrc
file after the command completes, and manually execute npm install
.
However, as highlighted in npm/cli#5460 (comment), unless your company's NPM repository also functions as a proxy to the public repository, employing scopes would certainly be a more recommended approach.
from angular-cli.
Thanks @alan-agius4.
I'll follow your steps for ng new
.
Is a change going to be made to ng update
?
Sam
from angular-cli.
Yes, but there is no ETA for the ng update
bug fix.
from angular-cli.
Related Issues (20)
- ng build with the --watch flag applied makes it difficult to `npm link` as the the package version numbers dynamically change HOT 4
- `application` builder fails to load imports with *?worker when prebudling is set to false. HOT 2
- Angular 17 custom library issue HOT 1
- Angular 17: getting Internal server error: Invalid URL error when starting dev server HOT 1
- @angular-devkit/build-angular depends on vulnerable version of webpack-dev-middleware HOT 10
- Production mode doesn't transform RegEx correctly HOT 3
- Is It Possible to Dynamically Select a Proxy Server When Serving an Application? HOT 2
- Debugging doesn't work in Visual Studio Code after upgrade to angular v17 with browser-esbuild builder
- Debugging doesn't work in Visual Studio Code after upgrade to angular v17 with browser-esbuild builder HOT 2
- vunerability in webpack-dev-middleware HOT 1
- output-hashing in angular 17 (prerender mode) does not work HOT 1
- The relative path image in the scss file is not added with base-href after ng build. HOT 4
- stylePreprocessorOptions.includePath is not following symlinks when using @angular-devkit/build-angular:application
- Support lazy loading imports in html template HOT 1
- Angular 17 SSR baseHref / baseUrl is not respected
- ng add @nguniversal/[email protected] is installing the package but, not creating the server files like server.ts. Getting error HOT 1
- npm install hangs forever and freezing rancher desktop while dockerizing angular application HOT 1
- Types disappearing (or heavily simplified) if not using `npm link` HOT 4
- Angular 17 prerender performance mark has not been set HOT 1
- Cannot import mapbox worker with application builder HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from angular-cli.