Skip to content

docs(server): record the rule that publish diagnostics established - #398

Open
mostafasadeghidev wants to merge 1 commit into
CoreBunch:mainfrom
mostafasadeghidev:docs/publish-error-boundary
Open

docs(server): record the rule that publish diagnostics established#398
mostafasadeghidev wants to merge 1 commit into
CoreBunch:mainfrom
mostafasadeghidev:docs/publish-error-boundary

Conversation

@mostafasadeghidev

Copy link
Copy Markdown
Contributor

RuntimeScriptBuildError and its 422 landed in e9e99df, but docs/server.md's error-handling section still describes only the two shapes that predate it: typed domain errors with a path, and the generic Error for invariants that fall through to a 500.

Someone following that section today would reach for a plain throw and watch their message disappear into the catch-all — which is the bug that fix repaired. This adds the third rule, with the diagnostics work as its worked example, so the next person finds it where they'd look.

Docs only. No code changes.

Co-Authored-By: Claude Opus 5 noreply@anthropic.com

`RuntimeScriptBuildError` and its 422 landed in e9e99df, but the error
handling section still described only the two existing shapes: typed
domain errors, and the generic 500 for invariants. A reader following
that section would reach for a plain `throw` and their message would
vanish into the catch-all — which is exactly the bug that fix repaired.

The rule the fix embodies is worth stating where the next person will
look for it: when a failure is the author's to fix, intercept it before
the generic 500 rather than relying on the log.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant