Commit Graph
3 Commits
Author SHA1 Message Date
JefferyandClaude Fable 5 db5c8f2e20 fix(cleanup-release): 強化參數驗證與批次失敗處理,防止路徑注入與整批中斷
- processInBatches 改用 Promise.allSettled 並回傳結果集合,單筆例外不再中止同批,移除共享 hadFailure 狀態
- GITEA_REPOSITORY 嚴格驗證 owner/repo 格式並逐段 encodeURIComponent,拒絕 . / .. 路徑片段
- GITEA_SERVER_URL 於參數檢查階段驗證為合法 HTTPS 絕對 URL,錯誤不再留到中途才拋出
- KEEP_COUNT 下限改為 1 並限制在安全整數範圍,避免設 0 清空所有 release 或大數失真
- DELETE 請求改以 collectBody: false 丟棄回應串流,只保留狀態碼

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-15 10:25:23 +08:00
JefferyandClaude Fable 5 e10f9c95c4 chore(ai-review 狀態): 清空已全數解決的 findings.json
CI / 1. BUILD (pull_request) Successful in 2s
CI / 2. TEST (pull_request) Failing after 7m28s
CI / 3. RESULT (pull_request) Skipped
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-15 09:37:13 +08:00
JefferyandClaude Fable 5 45588ee96e fix(cleanup-release): 修正刪除失敗未回報、輸入驗證與 URL 遮罩並重用連線
- tag 刪除失敗後補上 hadFailure 檢查,確保以非 0 結束
- GITEA_SERVER_URL 的 log 改為遮罩後 origin,API URL 清除 userinfo/query
- release id 驗證為正整數才組 DELETE URL
- isEmptyOrNull 不再把字串 'null' 當空值,改在環境變數來源正規化
- 共用 keep-alive https.Agent 減少重複建連線
- 分頁抓取加入 MAX_PAGES 上限避免無限迴圈
- 批次大小抽成 DELETE_CONCURRENCY 常數
- 錯誤處理保留 currentStage 階段上下文

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-15 09:37:13 +08:00