fix(ci): 格式修复防循环索引 + AI审查fail-open(2个bug修复) #1045
Reference in New Issue
Block a user
Delete Branch "fix/auto-fix-loop-detection"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Bug修复合集
Bug 1: 防循环检测取错commit
Gitea PR commits API 返回倒序(最新在前),
commits[-1]取到最早的 commit,防循环检测失效。修复:
commits[-1]→commits[0]Bug 2: AI Code Review fail-open 未生效
代码注释写了fail-open原则,但LLM调用失败和未捕获异常时都是
exit 1,会阻塞PR合并。修复:两处
exit 1→exit 0fail-open原则:AI审查是辅助手段,自身故障不能阻塞正常开发。
【阻塞级判定】
📊 审查概览
🔴 阻塞级问题(必须修复)
无
💡 改进建议(不阻塞合并)
无
✅ 良好实践
commits[0]能够正确获取到最新的提交信息,从而准确判断是否需要跳过格式修复,有效防止了 CI 循环触发问题。🤖 由 AI 代码审查机器人自动生成 | 2026-07-28 00:24:25 | 模型:
fix(ci): 防循环检测取最新commit - API返回倒序用[0]而非[-1]to fix(ci): 格式修复防循环索引 + AI审查fail-open(2个bug修复)LGTM - bug fixes verified
🗑️ 预览环境已清理
PR #1045 已关闭或合并,对应的预览环境已被清理。