Skip to content

fix(ssr): return 500 on render error instead of hanging; partial data… - #967

Merged
treoden merged 1 commit into
devfrom
optimize_build
Jun 29, 2026
Merged

fix(ssr): return 500 on render error instead of hanging; partial data…#967
treoden merged 1 commit into
devfrom
optimize_build

Conversation

@treoden

@treoden treoden commented Jun 29, 2026

Copy link
Copy Markdown
Collaborator

… on field error

  • renderProduction runs inside a floated promise, so a throw never reached the calling middleware's try/catch and the request hung until requestTimeout fired (no status, no body). Thread next through render/renderProduction and forward render-time errors to the error handler so the client gets a proper 500.
  • A single failing or non-critical GraphQL field aborted the whole SSR page with a 500. Log field errors and render with whatever data resolved (partial, or {}) instead of discarding it.

PR Checklist

Please check if your PR fulfills the following requirements:

  • Tests for the changes have been added (for bug fixes / features)

PR Type

What kind of change does this PR introduce?

  • Bugfix
  • Feature
  • Code style update (formatting, local variables)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • CI related changes
  • Other... Please describe:

What is the current behavior?

Issue Number: N/A

What is the new behavior?

Does this PR introduce a breaking change?

  • Yes
  • No

Other information

… on field error

- renderProduction runs inside a floated promise, so a throw never reached the
  calling middleware's try/catch and the request hung until requestTimeout fired
  (no status, no body). Thread `next` through render/renderProduction and forward
  render-time errors to the error handler so the client gets a proper 500.
- A single failing or non-critical GraphQL field aborted the whole SSR page with
  a 500. Log field errors and render with whatever data resolved (partial, or {})
  instead of discarding it.
@treoden
treoden merged commit 473eb19 into dev Jun 29, 2026
2 checks passed
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.

1 participant