[PR #8921] chore(sdk): update @hey-api/openapi-ts to 0.90.4 #12912

Closed
opened 2026-02-16 18:17:47 -05:00 by yindo · 0 comments
Owner

Original Pull Request: https://github.com/anomalyco/opencode/pull/8921

State: closed
Merged: Yes


Summary

Updates @hey-api/openapi-ts from 0.88.1 to 0.90.4 which includes a fix for the "Unexpected end of JSON input" error.

Fixes #7889
Fixes #7715

Problem

When servers return HTTP 200 with no Content-Length header and an empty body, response.json() throws:

Unexpected end of JSON input

Solution

The fix was already implemented upstream in hey-api/openapi-ts#3201 and released in v0.90.4.

The generated client now handles this case:

case 'json': {
  // response.json() would throw; read as text and parse if non-empty.
  const text = await response.text();
  data = text ? JSON.parse(text) : {};
  break;
}

Changes

  • Updated @hey-api/openapi-ts from 0.88.10.90.4
  • Regenerated SDK with the fix included
  • All typechecks pass

Related

This supersedes the manual fix in PR #7888 for the SDK portion - the storage layer fixes in that PR are still needed separately.

**Original Pull Request:** https://github.com/anomalyco/opencode/pull/8921 **State:** closed **Merged:** Yes --- ## Summary Updates `@hey-api/openapi-ts` from `0.88.1` to `0.90.4` which includes a fix for the "Unexpected end of JSON input" error. Fixes #7889 Fixes #7715 ## Problem When servers return HTTP 200 with no `Content-Length` header and an empty body, `response.json()` throws: ``` Unexpected end of JSON input ``` ## Solution The fix was already implemented upstream in [hey-api/openapi-ts#3201](https://github.com/hey-api/openapi-ts/pull/3201) and released in v0.90.4. The generated client now handles this case: ```typescript case 'json': { // response.json() would throw; read as text and parse if non-empty. const text = await response.text(); data = text ? JSON.parse(text) : {}; break; } ``` ## Changes - Updated `@hey-api/openapi-ts` from `0.88.1` → `0.90.4` - Regenerated SDK with the fix included - All typechecks pass ## Related This supersedes the manual fix in PR #7888 for the SDK portion - the storage layer fixes in that PR are still needed separately.
yindo added the pull-request label 2026-02-16 18:17:47 -05:00
yindo closed this issue 2026-02-16 18:17:47 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#12912