Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Node.js v22.2 causes ng build hangs up #27674

Copy link
Copy link
@lacolaco

Description

@lacolaco
Issue body actions

Command

build

Is this a regression?

  • Yes, this behavior used to work in the previous version

The previous version in which this bug was not present was

No response

Description

When the Node.js version is v22.2.0 (released on 2024-05-15), the ng build command hangs up. Node.js v22.1.0 doesn't.
Angular CLI is not supporting that version of Node.js officially, but on Firebase App Hosting, the build environment is using Node.js v22.2 today by default. So it is an easy situation for developers to get stumped.

My workaround is to set engines.node field in package.json as "20". App Hosting builder can determine the Node.js version to install.

Minimal Reproduction

  • set Node.js version to v22.2.0
  • ng new on @angular/cli@latest (v17.3.7)
  • ng build
  • print Building... and never finished.

Exception or Error

No response

Your Environment

Angular CLI: 17.3.7
Node: 22.2.0 (Unsupported)
Package Manager: pnpm 8.15.6
OS: darwin arm64

Angular: 17.3.9
... animations, common, compiler, compiler-cli, core, forms
... platform-browser, platform-browser-dynamic, platform-server
... router

Package                         Version
---------------------------------------------------------
@angular-devkit/architect       0.1703.7
@angular-devkit/build-angular   17.3.7
@angular-devkit/core            17.3.7
@angular-devkit/schematics      17.3.7
@angular/cli                    17.3.7
@angular/ssr                    17.3.7
@schematics/angular             17.3.7
rxjs                            7.8.1
typescript                      5.4.5
zone.js                         0.14.6
    
Warning: The current version of Node (22.2.0) is not supported by Angular.

Anything else relevant?

No response

Reactions are currently unavailable

Metadata

Metadata

Assignees

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    Morty Proxy This is a proxified and sanitized view of the page, visit original site.