Repository navigation
fix(buddy): 区分文件被移动或删除与其他预览失败 - #406
Merged
shanyuhai123 merged 3 commits intoOct 22, 2026
Merged
shanyuhai123 merged 3 commits into
shanyuhai123 merged 3 commits into
Conversation
文件在列出或展示之后被移动或删除时,预览与产出页统一显示“加载失败”,用户分不清是文件不见了 还是预览本身出了问题。 现在运行时对这类情况返回 FILE_NOT_FOUND:空间文件服务与产出服务在文件缺失时抛出该错误码, 文件预览和产出页据此显示“文件已被移动或删除”,其他失败仍显示原来的加载失败提示。 补充了中英文文案与对应的单元测试。 Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
This was referenced Oct 20, 2026
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.
背景与关联 / Context and related issue
主要改动 / Changes
FILE_NOT_FOUND错误码(运行时与前端错误解析各增加该码)。文件预览组件和产出页据此显示新增文案“文件已被移动或删除”,其他失败仍显示原来的加载失败提示,重试按钮保留。补充了中英文文案,并为ArtifactService、SpaceFileService、useResourcePreviews各增加了单元测试。验证 / Verification
兼容与风险 / Compatibility and risks
不适用 / N/A。只是把一类已有的失败细分出更准确的提示,没有改变存储、授权或迁移。
界面变更 / UI changes
文件缺失时,预览区与产出页的提示由“加载失败”变为“文件已被移动或删除”。
🤖 Generated with Claude Code