fix(gate-check-v3): use submitted_at for review timestamps
Gitea reviews use "submitted_at" not "created_at" for when the review was submitted. The earlier signal_1_comment_scan fix (inherited from sop-tier-check investigation) already handled this; signal_2 and signal_3 were missing the same correction. Fixes KeyError: 'created_at' on PRs with no comments/reviews. Includes the individual-check-status fix (use "status" not "state"). Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
parent
9d05335b1a
commit
3eb06e40e6
@ -228,7 +228,7 @@ def signal_2_reviews(pr_number: int, repo: str) -> dict:
|
||||
"review_id": r["id"],
|
||||
"user": r["user"]["login"],
|
||||
"commit_id": r.get("commit_id", ""),
|
||||
"created_at": r["created_at"],
|
||||
"created_at": r.get("submitted_at") or r.get("created_at", ""),
|
||||
}
|
||||
)
|
||||
return {
|
||||
@ -276,7 +276,7 @@ def signal_3_staleness(pr_number: int, repo: str) -> dict:
|
||||
"review_commit": review_commit,
|
||||
"pr_head": head_sha,
|
||||
"age_hours": round(age_seconds / 3600, 1),
|
||||
"created_at": r["created_at"],
|
||||
"created_at": r.get("submitted_at") or r.get("created_at", ""),
|
||||
}
|
||||
)
|
||||
return {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user