AI 助手错误删除用户文件 - 严重事故
Nobody has claimed this yet.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 25/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Stale
- Domain
- security
Research direction
The issue proposes safeguards for file deletion but names no repository files, tests, or implementation entry points. Start by locating where command execution and deletion confirmations are handled, then check how untracked files are detected. Done means the proposed confirmation, file type, untracked file, and dangerous command safeguards have defined behavior and coverage.
Written by the indexing model from the issue text.
Description
事故概述
用户在使用 Claude Code 时,AI 助手在执行"清理图片"操作时错误地删除了用户目录下的所有 mp4 视频文件。
问题经过
- 用户要求清理
cache/videos/目录下的图片文件 - AI 助手错误地执行了删除操作,将该目录下的所有文件(包括 mp4 视频)全部删除
- 删除命令:
rm -f $(ls | grep -v \"^特定文件$\") - 该目录下的 mp4 文件未被 git 追踪,无法恢复
根因分析
- AI 助手没有正确理解用户指令中的"图片"范围
- 删除操作前没有列出要删除的文件清单并获得用户确认
- 对未版本控制的文件(cache 目录)执行删除时缺乏额外警告机制
实际损失
用户损失了约 200 美元的测试视频文件
建议改进
- 加强删除操作确认:在执行任何删除操作前,必须列出要删除的文件并获得用户明确确认
- 文件类型验证:删除前验证文件类型,对混合类型目录要有提示
- 未追踪文件警告:对未 git 追踪的文件执行删除前,应额外警告用户
- 危险命令拦截:对于可能造成大规模删除的命令(如
rm -f *),应要求二次确认
复现步骤
- 用户说"清理图片"
- AI 执行:
rm -f $(ls | grep -v \"^特定文件$\") - 结果:目录下的所有文件被删除,包括视频
此问题由 Claude Code AI 助手引起。
- Dominant language
- No language data
- Stars
- 588
- Forks
- 83
- PR merge metrics
- No merged PRs in 30d
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from MiniMax-AI/MiniMax-M2.5
-
Difficulty 4/5 3-5 days Newbie friendliness 38/100
MiniMax-AI/MiniMax-M2.5#41 · 1 comment ·
-
Difficulty 1/5 Under an hour Newbie friendliness 48/100
MiniMax-AI/MiniMax-M2.5#39 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 45/100
MiniMax-AI/MiniMax-M2.5#38 · 1 comment ·
-
Difficulty 4/5 3-5 days Newbie friendliness 25/100
MiniMax-AI/MiniMax-M2.5#37 · 1 comment ·
-
Difficulty 3/5 1-2 days Newbie friendliness 35/100
MiniMax-AI/MiniMax-M2.5#36 · 3 comments ·
All issues in MiniMax-AI/MiniMax-M2.5
Similar issues
-
area: infra type: security
Difficulty 2/5 1-3 hours Newbie friendliness 67/100
Maintainers usually reply within 1 day
-
Approve the Cloudflare agent plugin for harness sessionsPossibly taken @joshtsch claimed this today. Openenhancement ready-for-agent
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
dynamic good first issue help wanted security
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
blindtk/personal-site#279 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 67/100
remotion-dev/skills#37 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100