fix(server): sanitize runtime exception responses - #1138
Open
knqiufan wants to merge 1 commit into
Open
Conversation
knqiufan
force-pushed
the
fix/issue-1137-sanitize-runtime-errors
branch
from
July 6, 2026 13:40
a37bb5d to
1d6b89d
Compare
Member
|
LGTM |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
/api/v1/system/status, and keep raw probe exceptions in server logs only.APIErrormessages and batch item errors that previously embeddedstr(e)with generic public messages.Stack note
a37bb5d(fix(server): sanitize runtime exception responses). After fix(server): sanitize startup errors in API responses #1136 merges, this PR diff should collapse to the Runtime dependency check and request-path errors still expose raw exceptions in API responses #1137 changes only.Test plan
python -m pytest tests/unit/server/test_health_check.py tests/unit/server/test_system_health.pypython -m pytest tests/unit/servergit diff --checkpython -m pytest tests/unitwas attempted locally; it still fails on unrelated local environment/tool assumptions, including API/model environment overrides, missing ModelScope cache, Windows script/tool availability, and an existing sqlite FTS setup error.Fixes #1137