Fixapp-sdks

@revenexx/app-sdk@0.7.1

Patch Changes

  • b046a90: Answer an update with nothing to update with 400, in the data client rather than only in mountCrud.

    PostgREST answers a PATCH whose body carries no columns with 200 [], so the remote adapter's rows[0] was undefined. The App returned that from its handler and the open-runtimes runtime tried Buffer.from(JSON.stringify(undefined)), which throws a Node type error the App then reported as a 500 — with the raw Node message in the response body. 0.6.0 added the guard to mountCrud, but Apps that route a write themselves (PUT /v1/greetings/{id}, PUT /v1/payments/providers/{id}) never went through it, so they kept 500ing. The rule now lives in EntityClient.update, below every routing style.

    While there: no write path can return undefined any more. A PATCH that matched no row is a 404 (the row was deleted or is invisible under RLS) and an insert that returns no representation is a described 5xx, instead of an undefined that breaks wherever it is serialised. The PHP runtime mirrors both rules.

    Patch, not minor: ^0.7.0 has to pick this up without every App changing its manifest, and nothing is removed — the changed paths previously produced an unserialisable value or a crash.