Review gate: automated PR reviewer (acceptance parse, tests, verdicts) (#5) #12

Merged
pbwraith merged 2 commits from issue-5 into main 2026-08-25 18:14:18 +02:00

2 Commits

Author SHA1 Message Date
Claude
5e5827c987 gitea-saas-core#5: drop duplicate gitea_client.py — canonical version is !17's (#4) 2026-08-25 10:43:46 -05:00
pbwraith-worker
df72b3926f gitea-saas-core#5: review gate — automated PR reviewer (acceptance parse, tests, verdicts)
Reviewer(repo_client, runner) with review_pr() -> Verdict and
post_verdict() posting [review-gate] comments. Parses acceptance
checklists + Files-allowed scope from the linked issue; runs pytest,
optional build cmd (REVIEW_BUILD_CMD), git diff --check with timeouts
(REVIEW_TEST_TIMEOUT_S, default 300); secret-pattern scan (sk_live_,
AKIA, gh tokens, private keys, assigned credentials) quoting each added
diff line as evidence (values redacted); optional configurable LLM pass
that is validated — unquoted findings dropped. Verdict rules: failing
tests -> BOUNCE (unless allow_test_failure in issue body); timeout ->
BOUNCE; scope violation -> BOUNCE; blocking finding -> BOUNCE; empty
acceptance -> NEEDS_GUIDANCE (never silent-approve); else APPROVE.
FAIL-CLOSED: no merge call anywhere. gitea_client.py adds the Gitea
seam (env token, urllib, mockable). 16 hermetic tests, no network, no
real subprocesses.
2026-08-25 04:31:08 -05:00