Skip to content

ng build fails with: An error occurred while extracting routes. #28683

Closed

Description

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

19.0.0-next.9

Description

When running ng build on a freshly generated Angular 19 prerelease project, an error is thrown.

Minimal Reproduction

  • Run npx @angular/cli@next new and enable SSR
  • Run ng build

Exception or Error

✘ [ERROR] An error occurred while extracting routes.

Error: No handler function exported from /projects/ng19-test-proj/node_modules/@angular/build/src/utils/server-rendering/routes-extractor-worker.js
    at /projects/ng19-test-proj/node_modules/piscina/dist/worker.js:142:23

Your Environment

Angular CLI: 19.0.0-next.12
Node: 20.18.0
Package Manager: npm 10.9.0
OS: darwin x64

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

Package Version

@angular-devkit/architect 0.1900.0-next.12
@angular-devkit/build-angular 19.0.0-next.12
@angular-devkit/core 19.0.0-next.12
@angular-devkit/schematics 19.0.0-next.12
@angular/cli 19.0.0-next.12
@angular/ssr 19.0.0-next.12
@schematics/angular 19.0.0-next.12
rxjs 7.8.1
typescript 5.6.3
zone.js 0.15.0

Anything else relevant?

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions