Skip to content

Upcoming Release Changes#2398

Merged
PowerKiKi merged 1 commit intomasterfrom
changeset-release/master
Apr 15, 2026
Merged

Upcoming Release Changes#2398
PowerKiKi merged 1 commit intomasterfrom
changeset-release/master

Conversation

@github-actions
Copy link
Copy Markdown
Contributor

@github-actions github-actions bot commented Apr 15, 2026

This PR was opened by the Changesets release GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to master, this PR will be updated.

Releases

apollo-angular@14.0.0

Major Changes

  • #2395
    4e9f107
    Thanks @JesseZomer! - BREAKING CHANGE: HTTP errors now return
    Apollo Client's ServerError instead of Angular's HttpErrorResponse

    When Apollo Server returns non-2xx HTTP status codes (status >= 300), apollo-angular's HTTP links
    now return ServerError from @apollo/client/errors instead of Angular's HttpErrorResponse.
    This enables proper error detection in errorLinks using ServerError.is(error) and provides
    consistent error handling with Apollo Client's ecosystem.

    Migration Guide:

    Before:

    import { HttpErrorResponse } from '@angular/common/http';
    
    link.request(operation).subscribe({
      error: err => {
        if (err instanceof HttpErrorResponse) {
          console.log(err.status);
          console.log(err.error);
        }
      },
    });

    After:

    import { ServerError } from '@apollo/client/errors';
    
    link.request(operation).subscribe({
      error: err => {
        if (ServerError.is(err)) {
          console.log(err.statusCode);
          console.log(err.bodyText);
          console.log(err.response.headers);
        }
      },
    });

    Properties Changed:

    • err.statuserr.statusCode
    • err.errorerr.bodyText (always string, JSON stringified for objects)
    • err.headers (Angular HttpHeaders) → err.response.headers (native Headers)
    • Access response via err.response which includes: status, statusText, ok, url, type,
      redirected

    Note: This only affects HTTP-level errors (status >= 300). Network errors and other error
    types remain unchanged. GraphQL errors in the response body are still processed normally through
    Apollo Client's error handling.

    Fixes HttpErrorResponse error in ErrorLink #2394

Patch Changes

  • #2392
    8d2be64
    Thanks @vz-tl! - Allow headers type in DefaultContext to be Record or
    HttpHeaders

@github-actions github-actions bot force-pushed the changeset-release/master branch from a61d843 to cbc3286 Compare April 15, 2026 15:04
@PowerKiKi PowerKiKi enabled auto-merge April 15, 2026 15:08
@PowerKiKi PowerKiKi disabled auto-merge April 15, 2026 15:13
@PowerKiKi PowerKiKi merged commit 705d32f into master Apr 15, 2026
@PowerKiKi PowerKiKi deleted the changeset-release/master branch April 15, 2026 15:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

HttpErrorResponse error in ErrorLink

1 participant