Skip to content

Commit c27098a

Browse files
ci: add the apify-factory review workflow (#1182)
Lets apify-factory review pull requests here and approve the trivial ones. - Requesting `apify-factory` as a reviewer runs an AI review; when every gate passes, the review finds nothing and a second model agrees, it approves instead of commenting. - A push that changes the code, removing the request, or going back to draft withdraws the bot's own approval. - This repository's `factory_auto_approve` property is true, which is what allows approvals, and mtrunkat becomes the code owner of the workflow file. - These paths are never auto-approved here, on top of the defaults every repository has. An agent proposed them from the repository's layout; edit the list in the workflow like any other code. | Path | Why | Files | | --- | --- | --- | | `src/apify/_charging.py` | Pay-per-event ChargingManager that computes and submits charges to users against pricing info; any change can alter what customers are billed. | 1 | | `src/apify/_crypto.py` | RSA/AES encryption, private-key loading, secret-input decryption and HMAC signing; subtle changes can leak secrets or break cryptographic guarantees. | 1 | | `.rules.md` | Instruction file for coding agents (duplicate of CLAUDE.md) that steers automated contributors; changes to agent guidance need human review. | 1 | Refs https://github.com/apify/ai-developer/blob/main/actions/auto-approve/README.md --------- Co-authored-by: Claude <noreply@anthropic.com>
1 parent a8723e8 commit c27098a

2 files changed

Lines changed: 36 additions & 0 deletions

File tree

‎.github/CODEOWNERS‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,4 @@
22

33
/docs/**/*.md @szaganek
44
/docs/**/*.mdx @szaganek
5+
/.github/workflows/factory_review.yaml @mtrunkat
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: apify-factory review (AI review, and auto-approval)
2+
3+
# Calls the apify-factory review and auto-approval pipeline (apify/ai-developer, wired up in
4+
# apify/workflows). Approvals additionally need the repository's `factory_auto_approve` custom
5+
# property set to true.
6+
on:
7+
# Taken from the default branch, never from the pull request, so a pull request cannot rewrite
8+
# its own review pipeline. Pull request code is never checked out or executed.
9+
pull_request_target:
10+
types:
11+
- review_requested
12+
- review_request_removed
13+
- converted_to_draft
14+
- ready_for_review
15+
- synchronize
16+
17+
permissions:
18+
contents: read
19+
pull-requests: write
20+
21+
jobs:
22+
factory-review:
23+
uses: apify/workflows/.github/workflows/factory_review.yaml@main
24+
secrets: inherit
25+
# Paths never auto-approved here, on top of the pipeline's defaults. Proposed from the
26+
# repository's layout when this workflow was added; edit them like any other code.
27+
with:
28+
policy: |
29+
{
30+
"denyGlobs": [
31+
"src/apify/_charging.py",
32+
"src/apify/_crypto.py",
33+
".rules.md"
34+
]
35+
}

0 commit comments

Comments
 (0)