What happens
While the packages endpoints were answering 500 (the circular-JSON failure filed alongside this issue), the dev server printed nothing: preview_logs / stdout at the default log level showed no error, no stack, no request line. The only evidence was the client-side console (Failed to load resource: 500) and the response body itself.
Measured on main @ a39b02a, showcase, objectstack dev --seed-admin -p 3911, three consecutive GET /api/v1/packages from Studio plus manual curl reproductions, all 500, zero log output.
Why it matters
Route & surface ownership §3: absence must be loud. A 5xx that is invisible to the operator is diagnosed from the browser or not at all; here the failure had been reachable since #12348 landed (2026-08-25) and nobody saw it because nothing was logged.
Expected
Every 5xx produced by the REST layer's error envelope (packages/rest/src/error-response.ts / the direct-mount package routes' catch blocks, and the runtime dispatcher's errorFromThrown) logs at error level with method, path, request id and the thrown error's message + stack, regardless of --log-level's default. 4xx may stay quiet; 5xx never.
Suggested fix
- Centralize: the place that turns a thrown error into a 500 envelope logs it once (avoid double logging where both the package routes and the dispatcher catch).
- Add a test that a handler throwing a plain
Error yields a 500 and an error-level log entry carrying the message.
Found during the objectui pin-bump dogfood (PR #14295).
Generated by Claude Code
What happens
While the packages endpoints were answering 500 (the circular-JSON failure filed alongside this issue), the dev server printed nothing:
preview_logs/ stdout at the default log level showed no error, no stack, no request line. The only evidence was the client-side console (Failed to load resource: 500) and the response body itself.Measured on
main@ a39b02a, showcase,objectstack dev --seed-admin -p 3911, three consecutiveGET /api/v1/packagesfrom Studio plus manualcurlreproductions, all 500, zero log output.Why it matters
Route & surface ownership §3: absence must be loud. A 5xx that is invisible to the operator is diagnosed from the browser or not at all; here the failure had been reachable since #12348 landed (2026-08-25) and nobody saw it because nothing was logged.
Expected
Every 5xx produced by the REST layer's error envelope (
packages/rest/src/error-response.ts/ the direct-mount package routes' catch blocks, and the runtime dispatcher'serrorFromThrown) logs aterrorlevel with method, path, request id and the thrown error's message + stack, regardless of--log-level's default. 4xx may stay quiet; 5xx never.Suggested fix
Erroryields a 500 and anerror-level log entry carrying the message.Found during the objectui pin-bump dogfood (PR #14295).
Generated by Claude Code