Thanks to visit codestin.com
Credit goes to github.com

Skip to content

resource does not recognize HttpErrorResponse as error #61861

Open
@manfredsteyer

Description

@manfredsteyer

Which @angular/* package(s) are the source of the bug?

core

Is this a regression?

No

Description

  1. A resource's loader delegates to the HttpClient that throws an HttpErrorResponse
  2. The resource does not recognize the HttpErrorResponse as an Error, hence, it creates an error Object with the message Resource returned an error that's not an Error instance: [object Object]. Check this error's .cause for the actual error.

Please provide a link to a minimal reproduction of the bug

No response

Please provide the exception or error you saw


Please provide the environment you discovered this bug in (run ng version)

Angular CLI: 20.0.0
Node: 22.14.0
Package Manager: npm 10.9.2
OS: darwin arm64

Angular: 20.0.0
... animations, build, cli, common, compiler, compiler-cli, core
... forms, platform-browser, platform-browser-dynamic, router

Package                      Version
------------------------------------------------------
@angular-devkit/architect    0.1902.14
@angular-devkit/core         19.2.14
@angular-devkit/schematics   19.2.14
@schematics/angular          20.0.0
rxjs                         7.8.2
typescript                   5.8.3
zone.js                      0.15.1

Anything else?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions