Setup guide: stage 1
On this page
- Rules for whoever runs it
- What you will add
- Step 1. Check readiness
- Step 2. Pick the Open Factory Floor version
- Step 3. Write the rules
- Step 4. Try the rules on changes that have already merged
- Step 5. Add the review standard
- Step 6. Add the workflows
- Step 7. Arrange the reviewer, and tell the agents that work here
- Step 8. Merge, then make the checks required
- Step 9. See it work
- Step 10. Hand over
- Keeping it running
- What stage 1 does not do
Stage 1 puts two stations in front of every change: the project's own tests, then an independent review. Nothing merges until both pass. This is the stage Open Factory Floor supports today.
This page is written for an agent setting it up with the repository's owner. A person can follow it too. Run the readiness check first; this guide uses its report.
#Rules for whoever runs it
- The owner decides; you propose. Three decisions are theirs and are marked Owner decides below: the rules, who reviews, and making the checks required. Do not go past one of those without their answer.
- Everything goes in by pull request. No direct pushes, including the files this guide adds.
- Do not weaken anything already there. If the repository has branch rules or a review habit, add to them. Never replace or remove one.
- Never record a review that did not happen. Not to test the gate, not to unblock yourself. The test in step 9 shows how to see the gate work without one.
- Say what you did not do. If a step was skipped or could not be checked, the hand-over in step 10 says so.
#What you will add
| File in the repository | What it is |
|---|---|
factory.yml | The rules: which checks must pass, which changes need a review, which paths are risky and why |
docs/REVIEW_STANDARD.md | What a reviewer checks and how the result is recorded |
.github/workflows/factory-pull-request.yml | A workflow that does nothing when a pull request is opened or changed, so that the gate can start after it |
.github/workflows/factory-gate.yml | A few lines that call Open Factory Floor's gate at one fixed version |
A paragraph in the notes agents read (AGENTS.md, CLAUDE.md or the contributor guide) | How work is done here now |
And one setting: the test checks and independent-review become required to merge.
#Step 1. Check readiness
Use the readiness report. If its verdict is not stage 1, stop and give the owner the gaps. If it has an "unknown" in section A, get it answered first. The one exception is A1 graded unknown because Actions are limited to a selected list: only a run settles that, so carry on and watch for it in step 9.
#Step 2. Pick the Open Factory Floor version
git ls-remote --tags --sort=-v:refname https://github.com/theaiengineers/factory | head -2
Take the 40-character id on the line for the newest tag; if a second line for the same tag ends ^{}, take that one instead. That commit id is the version. Write it down with the tag name; it is used in steps 3 and 6.
Use a version later than v0.76.0: the gate workflow in step 6 starts in a way that earlier versions cannot be started in. (The starter files and the preview this guide uses arrived in v0.2.0, and the starter's never_skip line is read from v0.5.0.)
Get a copy of Open Factory Floor at that version to work from, in a new directory outside the repository you are setting up:
FACTORY=$(mktemp -d)
git clone https://github.com/theaiengineers/factory "$FACTORY" && git -C "$FACTORY" checkout COMMIT
python3 -m venv "$FACTORY/.venv"
"$FACTORY/.venv/bin/pip" install --require-hashes --only-binary :all: -r "$FACTORY/requirements.txt"
The later steps call this directory $FACTORY. If your shell does not keep variables from one command to the next, write the directory's path down and use it in place of $FACTORY; a later step that fails with "no such file or directory" on .venv/bin/python has lost it.
#Step 3. Write the rules
Copy starter/factory.yml from your copy of Open Factory Floor to the root of the repository as factory.yml, and fill it in from the readiness report's "For setup" section. The factory file spec says what each key means. factory: is only a name for the group of repositories run this way; nothing reads it yet, and the organisation's name will do.
Owner decides two lists. Put your proposal in front of them with the reason for each entry.
The risky areas. For each: a name, the paths, and a why. The why is shown to the reviewer on every high-risk change, so write what goes wrong for a real person, not what the code is ("moves money; a mistake charges real customers", not "billing module"). If the repository already has rules, as code, that say more than a path can (an edit to one function of a large file, a migration that only adds), it can name them as its judge and keep one set of rules: see a repository's own judge. Fewer, sharper areas are better than many. If everything is high risk, nothing is. A small repository may have only one, usually its workflows; that is a fine answer. Rewrite the why of every example you keep so that it is true of this repository.
The paths a review may skip. A change that touches only these needs no review at all. Start with prose ("**/*.md") and stop there unless the owner asks for more. Four things to tell them before they add any:
- A skipped path is skipped even inside a risky area.
- Skipping tests means a change can delete a test, or loosen what it asserts, with nobody looking.
- Generated files are safe to skip only if something else checks they match their source.
- Skipping all prose would also skip the file that tells agents how to work here (
AGENTS.md,CLAUDE.md), so that file could change with no review. Naming it as a risky area does not help, because a skipped path is skipped first. The starter therefore lists those files undernever_skip, which keeps them reviewed whatever the skip list says. Set it to the file this repository's agents actually read (the one step 7 adds to), and add any other prose that steers the work, such as a runbook. It needs v0.5.0 or later: an earlier gate ignores the key without saying so.
Two files are always high risk whatever the lists say: factory.yml itself and the review standard it names.
The preview in step 4 follows never_skip too, so it shows what the list does.
When the file is filled in, delete the starter's comments about replacing values; grep -n CHANGE factory.yml should then find nothing. The gate accepts a file with a placeholder left in: a placeholder path never matches, and a placeholder why is shown to reviewers as it stands.
Set require under the testing station to the test check names from the readiness report. The gate does not enforce that list yet. It is the record of what step 8 makes required, and it is where a later version of Open Factory Floor will read it from.
A risk area may name paths that do not exist yet (the scripts a later step will add): it does no harm, and it is in force the moment they appear.
#Step 4. Try the rules on changes that have already merged
Before anyone depends on the rules, see what they would have said about recent work. From the root of the repository:
REPO=$PWD
gh pr list --state merged --limit 30 --json number,title,files |
(cd "$FACTORY" && .venv/bin/python -m factory.preview --rules "$REPO/factory.yml")
It prints one line for each change with its level, then the totals. It calls nothing and changes nothing. A repository with no merged pull requests yet has nothing to try the rules on: the preview says so, and the three pull requests in step 9 are then the first trial of the rules. If it stops with a one-sentence error, the file has a mistake; fix it and run again.
Read the output with the owner:
- A change they think of as risky that shows
code: a risk area is missing, or its paths are wrong. - A change they think of as routine that shows
high: an area is drawn too wide. - A change that shows
noneand touched something that runs: a skip path is too generous. - A risk area listed as touched by no change: either a quiet area, or a path that does not match how the repository spells it. Check the path exists.
Change the rules and run it again until the owner is content. Its limits: it sees at most the first 100 files of a change (it marks a change listed with that many) and only the new name of a renamed file, so the real gate can be stricter than this preview on very large changes and on moves. If the file has no independent-review station, the preview says so and shows every change as needing no review, because the gate then checks nothing.
#Step 5. Add the review standard
Copy docs/REVIEW_STANDARD.md from your copy of Open Factory Floor to the same path in the repository, or point standard: in factory.yml at a standard the team already has. If the team writes its own, it must keep the record section word for word: the gate reads that marker and nothing else.
#Step 6. Add the workflows
Copy two files from your copy of Open Factory Floor:
starter/factory-pull-request.ymlto.github/workflows/factory-pull-request.yml, unchanged. Keep itsname:: the gate starts when a workflow of that name finishes.starter/factory-gate.ymlto.github/workflows/factory-gate.yml, and replaceCOMMIT, in both places, with the id from step 2. Then tidy the comment at the top: the lines about copying the file and finding the commit id have done their job; keep the sentences that say when the workflow starts and that it never runs a pull request's code.
Why there are two. The gate has to set a status on a pull request, including one from a fork, and may need a secret (the automatic reviewer's key), and it must never run the pull request's code. A workflow started by pull_request cannot do that for a fork's pull request: GitHub gives it no secrets and a token that can only read. So factory-pull-request.yml starts on pull_request and does nothing else; it exists so that its finishing is something to start after. The gate starts on workflow_run when it finishes, which GitHub always runs from the default branch, with the repository's secrets and a token that can write. On a fork's pull request the small workflow is the fork's own copy, which the fork can change, so the gate believes nothing it says or leaves behind: it looks the pull request up through GitHub's API from the commit GitHub says the run was for, and reads that pull request's head as it is at that moment. No Actions policy is needed, on a public repository or a private one. (Until v0.76.0 the gate started from pull_request_target, which GitHub has not started on a public repository since 2 December 2026 unless the owner allows it by a policy.)
What this means day to day, which the owner should know:
- The gate's first status comes after the small workflow has run: usually some 10 to 30 seconds later than when the gate started straight from the pull request, the time GitHub takes to queue and start one more short job.
- The pull request no longer shows a check called
gate / gate. A run started byworkflow_runbelongs to the default branch, so its check is not shown on the pull request. Theindependent-reviewstatus is unchanged, and its "Details" link still leads to the run. The pull request showsfactory-pull-request / changedinstead. Never require that one: on a fork's pull request it is the fork's to make green, so requiring it adds no protection, and a pull request whose runs are skipped (below) or whose copy of the file is renamed could then never merge. - On a public repository GitHub holds the workflows of a first-time contributor's pull request until a maintainer approves them (the repository's Actions setting says whose). Until then the gate's run on a push does not start. GitHub also runs no
pull_requestworkflow while a pull request has a merge conflict. The sweep (below) gives such a pull request its status anyway: it reads the pull request as data and runs nothing of the contributor's. - Two ways a pull request's own runs can be stopped, the first with no file changed. First, a skip instruction: when the head commit's message contains
[skip ci],[ci skip],[no ci],[skip actions]or[actions skip], or ends with the trailerskip-checks: trueafter two empty lines, GitHub runs no workflow that starts onpull_request(orpush) for it, sofactory-pull-request.ymldoes not run and nor do the gate's and the reviewer's runs that follow it. (pull_request_targetignored these, so this is new.) Anyone who writes the commit can put one there, by accident or on purpose. Second, a fork can change, rename or delete its own copy offactory-pull-request.yml; that is a change under.github/workflows/, so keep.github/out ofskip_when_onlyand such a change needs a review. - When that happens to a new commit, the commit has no status, so with
independent-reviewrequired (step 8) it cannot merge. It gets one when anybody comments on the pull request (the gate's run on a comment is not affected), or at the next sweep. - What is weaker than before. A status belongs to a commit, not to a pull request. If a commit already has a status and its runs are stopped, then changing the pull request's base branch, or opening a second pull request from the same branch, starts no gate run: the commit keeps the status it had until somebody comments or the next sweep. The old trigger judged a change of base at once. So a commit that was green because, against its first base, it changed only prose can show green against a base where the same commit changes code. What can come in that way is limited to the difference between the two bases: commits that are already in this repository, on another of its branches, which somebody with write access put there. Nothing the contributor wrote can be brought in that the gate has not judged. And a person with write access still has to press merge. Any comment on the pull request, or the next sweep, puts the status right.
- Pull requests that share a commit are judged together, always. GitHub's list of a commit's pull requests leaves out every fork's, so each gate run (after a push, after a comment, and in the sweep) also reads every open pull request of the repository and judges each whose head is that commit, whatever fork or branch it comes from; the worst answer is the one set. That costs one request for each hundred open pull requests, every time the gate looks. With more than 1,000 open pull requests the gate will not judge on part of the picture: every run says
error, and nothing can merge until there are fewer. - A denial anybody can cause. A commit's status belongs to the commit. So anybody can open a second pull request from somebody else's fork branch into a branch where that commit changes code, and the commit, and with it the first pull request, shows not passed until a maintainer closes the second one. That is right for a status that belongs to a commit, and the old trigger did the same.
The sweep. The starter also starts the gate every half hour (schedule), and lets you start it by hand (Actions, factory-gate, "Run workflow"). It puts right what a push does not: a status left standing by a change of base while the runs were skipped, and a pull request that never got a status (skipped runs, a first-time contributor's runs waiting for approval, a merge conflict). Each time it:
- reads every open pull request (as above; with more than 1,000 it judges nothing and the run fails);
- groups them by head commit, over the whole list;
- chooses at most 20 commits (
sweep_limitin the gate workflow'swith:changes it): all of them when there are no more than that; otherwise half are the commits whose pull requests changed most recently, and half are taken in turn from all of them, moving on with each sweep, so every commit is reached however the changes are ordered; - judges each with every open pull request on it, exactly as a push would, and writes a status only where the one there is not what it should be. A sweep that finds nothing wrong writes nothing.
It posts nothing, starts no review and reads no closed pull request. Anything it cannot read keeps the status it has, and the run fails; anything it reads but cannot judge gets error, never a pass. Where factory.yml names a judge, each sweep runs it once for every pull request it judges, which is that judge's cost every half hour.
How long something wrong can last: with 20 or fewer commits at the head of open pull requests, until the next sweep, about half an hour. With more, until the commit's turn comes: with 100 open pull requests on different commits, up to 10 sweeps (five hours); with 500, up to 50 (a day). A larger sweep_limit shortens that and costs more. GitHub can start a scheduled run late when it is busy; a schedule runs only from the default branch; and on a public repository GitHub turns schedules off after 60 days without activity in the repository. A comment on the pull request puts its status right at once.
What it costs. Requests: about one for each hundred open pull requests to read the list, then about eight for each commit judged, and some twenty more for each commit whose status it corrects. So a sweep is about 160 requests at 20 or at 100 open pull requests, and about 165 at 500; every half hour, about 330 an hour, of the 1,000 an hour GitHub gives a workflow's token in each repository (15,000 on GitHub Enterprise Cloud). A run after a push is about 20 requests, after a comment about 19, plus two for each further hundred open pull requests. If the allowance runs out GitHub refuses requests for the rest of the hour; the gate tries each three times, then the run fails: a status it had not yet written stays as it was, one it could not finish is error, and none is ever turned green by a refusal. Keep sweep_limit times the sweeps an hour times ten well inside the allowance. Minutes: on a public repository nothing. On a private one each sweep is a short billed run, rounded up to a minute: every half hour is some 1,500 minutes a month. Make it hourly ("11 * * * *") or take the schedule lines out if that is too much. Without it, a status left standing by a change of base lasts until somebody comments on or pushes to the pull request, and a pull request whose runs were skipped has no status until then. A private repository can also simply stay on pull_request_target (below), which needs no policy there and judged a change of base at once.
Already set up with pull_request_target? You need not move if the repository is private, or if its owner has allowed pull_request_target by an Actions policy: the old starters keep working, and a newer version of Open Factory Floor serves them exactly as before. To move, in one pull request: add factory-pull-request.yml; in factory-gate.yml replace the pull_request_target: trigger and its types: line with the three workflow_run: lines from the new starter (keep issue_comment); move both commit ids to a version later than v0.76.0. Do the same for the reviewer and the leftovers if you have them (see the automatic reviewer and hoppers). That pull request is judged by the workflows already on the default branch. On a public repository whose old trigger has stopped starting, it gets its status when its review record is posted: the gate's run on a comment was never affected. Once it has merged, every pull request is judged the new way from its next push.
Check before you commit:
- Both places carry the same full commit id. A tag name or a branch name there means the code that judges every change can be swapped without a review.
- The
permissionsblock is unchanged. The job needs to write one status and read pull requests, and nothing more.factory-pull-request.ymlhaspermissions: {}, no secrets and no checkout, and must keep them: on a fork's pull request it runs as the fork wrote it, so it is never given anything worth taking. - The file is valid YAML:
"$FACTORY/.venv/bin/python" -c 'import sys, yaml; yaml.safe_load(open(sys.argv[1]))' .github/workflows/factory-gate.ymlprints nothing when it is.
If the repository already enforces a review rule of its own and the owner wants to compare before switching, uncomment context: independent-review-trial. The gate then reports under that name beside the existing rule, and step 8 leaves it out of the required checks.
#Step 7. Arrange the reviewer, and tell the agents that work here
Owner decides who reviews.
The gate needs a comment on the pull request, from an account that can write to the repository, whose first line is the marker for the exact head commit. How the review comes to be done is up to the team. Three arrangements work today:
The automatic reviewer (v0.3.0 or later): a model reviews each change when its tests pass, with nobody starting it. It needs a model credential, a signing key and a line in
factory.yml, and by default a high-risk change still needs a person. Set it up after this guide, from its own page.A person reads the change against the standard and posts the record.
A fresh agent, started for this one review and given only the pull request and the standard. It must not be the session that wrote the change, and it must not be shown the author's reasoning: a reviewer handed the author's conclusion tends to confirm it. A brief that works:
Review pull request NUMBER in OWNER/REPO against docs/REVIEW_STANDARD.md in that repository. You did not write this change and you have been told nothing about it on purpose. Read the diff, follow the changed code through its callers, and run the tests that cover it. Post your result as a new comment in the form the standard gives, for the head commit as it is when you finish. If you find something blocking, record findings; do not fix it yourself.
A reviewer that posts through a GitHub App does not count, and neither does the workflow's own token, unless factory.yml names that account as its automatic reviewer. If author and reviewer share one login, the gate cannot tell them apart; the standard says so, and the owner should know it.
Then add a short section to the file the repository's agents read at the start of their work. If the repository has no such file, create AGENTS.md at its root. Without it, an authoring agent does not know the line exists. Adapt this:
How changes are made here. Every change goes in by pull request. Run the tests before you open one:
THE TEST COMMAND. Do not review your own change and do not post a review record for it. When the checks are green, ask for an independent review asdocs/REVIEW_STANDARD.mddescribes. A new commit after a review needs a new review. Changes tofactory.ymland the review standard are always high risk, and so is anything in the risk areasfactory.ymllists. If a check blocks you, say so; do not look for a way round it.
#Step 8. Merge, then make the checks required
Open one pull request with the files from steps 3, 5, 6 and 7. The gate will not report on it: the workflow only starts once it is on the default branch. Have it reviewed and merge it. If the repository has no way of reviewing yet, use the reviewer from step 7. Tell them that the standard is not on the default branch yet: they read docs/REVIEW_STANDARD.md from this pull request's branch, and there is no gate summary to consult for this one change.
The order from here, since steps 8 and 9 take turns:
- Merge that pull request.
- Step 9, first half: open the three test pull requests and read the status on each, with nothing required yet. Leave them open.
- The rest of this step: make the checks required.
- Step 9, second half: the review, then the new commit, on one of the three. It then also shows merging being blocked and unblocked.
Owner decides the last part, and an administrator makes it. In the rules for the default branch:
- require a pull request before merging;
- require these status checks: each test check from the readiness report, and
independent-review; - do not let administrators bypass the rules. An administrator's merge that skips the gate is the one nobody will notice.
Require independent-review by that exact name. A fork's pull request can add a workflow with a job of its own called independent-review, and a job's check carries the job's name. Branch protection lets you choose the source a required check must come from ("expected source" in the settings, the app_id of each required check in the API), and then refuses the merge when another source sets it. The gate writes its status with the workflow's own token, so pick the source GitHub offers for it once it has reported (GitHub's documents do not say which app such a status belongs to; it is shown as github-actions). That stops a status of that name written by any other app or by a person's token. It cannot stop a fork's job, which runs under GitHub Actions as well. GitHub's documents also do not say how a required name is counted when a failing status and a passing check of that name are on the same commit, beyond warning that one name used twice "can cause ambiguous status check results"; try it (below) before you rely on it. What does protect you is approving outside contributors' workflows before they run: the repository's Actions setting "Approval for running fork pull request workflows from contributors" set to "Require approval for all external contributors". A maintainer then sees a new or changed workflow in a fork's pull request before any of it runs. (The gate's status itself does not wait for that: the sweep sets it.) A pull request also shows a check called factory-pull-request / changed: that is the small workflow the gate starts after, and on a fork's pull request it is the fork's own. Do not require it. (A repository still on the old trigger shows gate / gate instead, the job that works the answer out, green whenever it reached an answer; do not require that either.)
GitHub's own "required approvals" can stay at zero. The independent review is recorded as a comment and enforced by the status, and where one account does all the work nobody could give a GitHub approval anyway. A team that already requires approvals can keep them; the two do not conflict.
Read the rules that are there before changing anything, and add to them. If you make the change through the API, do not send a request that replaces the whole protection with a new one: it silently drops every rule you did not repeat. Afterwards read the rules back and show the owner the result.
When the branch has no rules at all (readiness A4 found no ruleset and "Branch not protected"), there is nothing to drop, and one request sets everything above. Put the test check names in contexts, and if step 6 gave the gate another name, use that name in place of independent-review only once the owner has decided it should block:
gh api -X PUT repos/OWNER/REPO/branches/BRANCH/protection --input - <<'EOF'
{
"required_status_checks": {"strict": false, "contexts": ["YOUR-TEST-CHECK", "independent-review"]},
"enforce_admins": true,
"required_pull_request_reviews": {"required_approving_review_count": 0},
"restrictions": null
}
EOF
gh api repos/OWNER/REPO/branches/BRANCH/protection
strict: false means a pull request need not be up to date with the branch before merging; that is the owner's choice and not something Open Factory Floor needs. Read the protection again just before sending it, in case something was added since the readiness check. When rules already exist, do not send this request. Change them in the repository's settings pages; or, if status checks are already required, add the names and nothing else with gh api -X POST repos/OWNER/REPO/branches/BRANCH/protection/required_status_checks/contexts -f 'contexts[]=independent-review'.
Once independent-review is required, a pull request on which the gate has not reported cannot merge. That is intended. It also means that if the workflow is ever removed or cannot start, merging stops until it is fixed or the requirement is lifted (see "Turning it off").
#Step 9. See it work
Open three small pull requests and watch the independent-review status on each. Close the ones that were only for testing.
| Change | What the status should say |
|---|---|
Only a file the review skips, such as a line in the README (not a file listed under never_skip) | Passed: "No code changed: no independent review needed" |
| A line of real code outside every risk area | Not passed: "No independent review recorded for" the commit. The summary on the run lists the code that changed |
| A file inside a risk area | Not passed, naming the area. The summary gives the area, the file, the rule and why the area matters |
The summary is on the workflow run's page: follow the "Details" link beside the status, or find the run with gh run list --repo OWNER/REPO --workflow factory-gate.yml, then gh run view RUN --repo OWNER/REPO and open the link it prints. The same text is printed in the job's log.
On one that is waiting, have the reviewer from step 7 do a real review and post the record. The status should turn to passed once the workflow has run again, which the comment starts. Then push another commit to it: the status should go back to not passed, saying the review is for the earlier commit.
On a public repository, try a fork too, from a second account, before you rely on the gate there. Each of these settles something only a real run can:
- A fork's pull request: the status arrives on the fork's head commit once its runs are approved (and the sweep gives it one before they are).
- A fork's pull request whose copy of
factory-pull-request.ymlfails, is renamed, or hasif: falseon its job: no status, or a status that is not passed; never a pass the commit should not have. A comment then sets the right one. - A head commit whose message says
[skip ci]: no status until a comment or a sweep. Then change the pull request's base to a branch against which the commit changes code: the status is put right by the next comment or sweep. - One fork branch opened into two branches, one where it is prose only: the status is the worse of the two, after a push, after a comment on either, and after a sweep.
- A job called
independent-reviewin a fork's workflow that passes while the gate's status says not passed: whether the pull request can merge. If it can, the expected source does not protect you, and approving outside contributors' workflows is what does. - A new push while the small workflow is still running: the older commit is left alone and the newer one is judged.
- The sweep, started by hand (Actions, factory-gate, "Run workflow") and then by the schedule: that it runs with the gate's settings and the reviewer key, that its token may read a commit's statuses and write the gate's, how late GitHub starts the scheduled runs, and, on a private repository, the minutes it costs.
- A commit whose message ends with the
skip-checks: truetrailer: the same as[skip ci]. - A first-time contributor's pull request waiting for approval, and one with a merge conflict: the sweep gives each its status.
- A comment on a pull request far down the list: that it moves to the top of GitHub's list of the most recently changed, which is the half of each sweep that follows changes.
If the status never appears, look at the workflow's runs. The usual causes: the workflow is not on the default branch yet; outside workflows are not allowed (readiness A1); COMMIT was not replaced; factory-pull-request.yml is missing or renamed, or did not run on the pull request: the head commit's message holds a skip instruction such as [skip ci], a first-time contributor's runs are waiting for a maintainer's approval, or the pull request has a merge conflict. A comment on the pull request, or a sweep started by hand, gives it a status in each of those cases. The gate's run says in its log which pull request it found for the commit, or that it found none. If it says error, the description says what could not be read; it is usually factory.yml failing to parse on the default branch.
#Step 10. Hand over
Tell the owner, in plain words:
- what is now required to merge, and which Open Factory Floor version is pinned;
- the rules they agreed, and where to change them (
factory.yml, by pull request, always reviewed); - who reviews;
- anything from the readiness report still open, with the worst test gap first;
- what was skipped or could not be checked.
#Keeping it running
Changing the rules. Edit factory.yml by pull request. The gate reads the rules from the default branch, so a change to the rules is judged by the rules as they were, and takes effect when it merges. Run step 4 again before proposing it.
Taking a new Open Factory Floor version. Nothing arrives by itself. To move, replace the commit id in both places in factory-gate.yml, by pull request. Read what changed between the two versions first. To go back, restore the old id.
The automatic reviewer's credential. If you use the automatic reviewer, its model credential will one day expire or be withdrawn. Nothing merges unreviewed when it does, but reviews stop until a person replaces it. Add the health check so that somebody is told: see when the credential stops working.
Turning it off. Remove independent-review from the required checks, then remove the workflows (factory-gate.yml, and factory-pull-request.yml once nothing else starts after it). Do it in that order, or merging is blocked in between. Both are the owner's decision.
Seeing what happened. python3 -m factory.events export writes out the record of each change (opened, reviewed, sent back, merged) from what GitHub already holds; test results are not in it yet. See the record of every step. For a short report in plain words of where every open change stands, python3 -m factory.status: see how is the factory getting on?.
#What stage 1 does not do
- It does not do the review. It checks that one was recorded for the exact commit. The automatic reviewer is the optional station that does.
- It does not check that the tests passed. The required checks in step 8 do that.
- It does not check that the reviewer is a different account from the author.
- It does nothing after a change merges: no release decision, no release, no watch, no alerts. Those are the release half, for a project with something live to release to.
- It works on GitHub only.
This guide is docs/SETUP.md in the repository, and this page is made from it. Something wrong or unclear? Open an issue or send a pull request. Next: Setup guide: the release half.