4 months ago
85e1288Hermes can drop the prototype chain on Error subclasses, so `error instanceof JsonRpcResponseError` (and even `error instanceof Error`) would silently miss the "Already initialized" handshake error and let it bubble out of `resumeThread`/`readThread` as "Failed to load thread feed". Match by `error.code` or `error.message` instead, and pin the prototype on `JsonRpcResponseError` so `instanceof` works too. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Parenta9faa25