Fail on HTTP Status 204 (No Content) Hello, I'm using Synadia Cloud which has a DELETE…
- User
Fail on HTTP Status 204 (No Content) Hello,
I'm using Synadia Cloud which has a
DELETEAPI that returns a response with no body.code$ restish synadia delete-nats-user --help Deletes a NATS user from an account ## Argument Schema: { user-id: (string) } ## Responses 204/400/401/403/404 Response has no bodyIn this case, it's expected to have an empty body. Nevertheless,
restishfails with the error:codeERROR: Parse response error ERROR: Caught error: EOFHere is the full log:
code - Assistant
I’ll trace the response decompression/parsing path, add a focused regression test for a gzip-marked 204 response, then run the relevant package and broader tests. I’m using the
rsh-testskill because this is a CLI behavior regression. - Assistant
rgisn’t installed in this workspace, so I’m switching togrep/find. The failure appears likely to occur while decoding the response’s advertised gzip encoding before body parsing, so I’m locating both stages and their existing tests. - Assistant
The regression belongs in response normalization: a 204 is defined to have no body, so Restish should not initialize a decompressor merely because the server left
Content-Encoding: gzipon the response. I’m adding that semantic guard and exercising it through a real CLI request. - Assistant
The focused test run is still compiling dependencies. The new test reaches the user-facing
delete -o jsonpath against an HTTP server that returns exactly204plusContent-Encoding: gzip; it asserts successful empty-body rendering. - Assistant
The regression test now passes the former EOF point; its only mismatch was the expected presentation. The CLI intentionally emits no bytes for a 204 (rather than JSON
null), which matches the API contract, so I’m correcting the assertion to require empty stdout. - Assistant
The focused regression and both affected packages pass. I’m running the repository-wide fast suite now to catch cross-package effects; the implementation is deliberately limited to 204 normalization and preserves response headers for formatting/debugging.
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.