fix: 修复代码审查进度条逻辑
Deploy PR-Helper / deploy (push) Successful in 28s

- 后端: file_start 事件改为在获取信号量之后发送,避免并发时所有文件同时'开始'导致进度瞬间跳到90%
- 前端: 进度追踪改为基于 file_end 事件(完成)而非 file_start(开始),进度条平滑反映实际审查进度
This commit is contained in:
2026-06-21 15:17:51 +08:00
parent 55bfdf08ce
commit c7b03303e4
2 changed files with 5 additions and 5 deletions
+1 -1
View File
@@ -134,7 +134,7 @@ func GenerateReview(db *sql.DB, repoPath, base, head string, topN, concurrency i
sem <- struct{}{} // acquire slot
defer func() { <-sem }() // release slot
// Send file_start (order doesn't matter, frontend tracks by filename)
// Send file_start after acquiring semaphore — this means the file is actually being reviewed now
if safeCallback != nil {
safeCallback("file_start", map[string]interface{}{
"file": f.Filename,