docs(agents): a gate checklist agents run before a PR leaves draft
- AGENTS.md: "Before the PR leaves draft" spells out every gate rule (proposal by Joe), Problem and Screenshot only when they apply - pr_gate.py --dry-run <PR> prints what is missing and writes nothing; write modes run only in CI - a test keeps AGENTS.md and CONTRIBUTING.md on the gate's values (400 lines, 80 characters, UI paths, planning folders, labels) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@@ -2,6 +2,9 @@
2
2
3
3
Run by .github/workflows/pr-gate.yml under pull_request_target: it reads the PR as data
4
4
through the API and never checks out or runs code from the PR.
5
6
Locally, before a PR leaves draft: `python3 .github/scripts/pr_gate.py --dry-run <number>`.
7
It prints what is missing and changes nothing on GitHub.
5
8
"""
6
9
7
10
import json
@@ -16,16 +19,18 @@ from dataclasses import dataclass, field
16
19
from typing import Any
17
20
18
21
TITLE_PATTERN = re.compile(r"^(feat|fix|perf|refactor|docs|test|chore|ci|build)(\([a-z0-9-]+\))?!?: \S")
19
UI_PATH_PATTERN = re.compile(r"^crates/app/src/(views|settings|components|widgets)/|^crates/app/src/[^/]+_view\.rs$|/locales/")
22
UI_DIRECTORIES = ("views", "settings", "components", "widgets")
23
UI_PATH_PATTERN = re.compile(rf"^crates/app/src/({'|'.join(UI_DIRECTORIES)})/|^crates/app/src/[^/]+_view\.rs$|/locales/")
20
24
IMAGE_PATTERN = re.compile(r"!\[[^\]]*\]\(|<img\s|<video\s|github\.com/user-attachments/|\.(png|jpe?g|gif|webp|mp4|webm)\b", re.IGNORECASE)
21
25
ISSUE_REFERENCE_PATTERN = re.compile(
22
26
r"\b(?:close[sd]?|fix(?:e[sd])?|resolve[sd]?):?\s+(?:https://github\.com/danieldaeschle/rusty-teams/issues/|#)(\d+)", re.IGNORECASE
23
27
)
24
28
NO_VISUAL_CHECKBOX_PATTERN = re.compile(r"^\s*[-*]\s*\[[xX]\]\s*no visible change", re.IGNORECASE | re.MULTILINE)
25
FORBIDDEN_PATH_PATTERN = re.compile(r"^(openspec|\.specify|\.kiro)/")
29
PLANNING_FOLDERS = ("openspec", ".specify", ".kiro")
30
FORBIDDEN_PATH_PATTERN = re.compile(rf"^({'|'.join(re.escape(folder) for folder in PLANNING_FOLDERS)})/")
26
31
WINDOWS_CODE_PATTERN = re.compile(r"^\+.*(cfg\((all\()?windows|target_os\s*=\s*\"windows\")", re.MULTILINE)
27
32
WINDOWS_PATH_PATTERN = re.compile(r"(^|/)(win32|windows)(/|_[a-z]+\.rs$)|_win(dows)?\.rs$")
28
LOCKFILE_NAMES =("Cargo.lock", "package-lock.json", "pnpm-lock.yaml", "yarn.lock")
33
LOCKFILE_NAMES = ("Cargo.lock", "package-lock.json", "pnpm-lock.yaml", "yarn.lock")
29
34
30
35
MAX_CHANGED_LINES = 400
31
36
MIN_PROBLEM_CHARACTERS = 80
@@ -42,6 +47,7 @@ LABEL_NO_VISUAL = "gate: no visual"
42
47
LABEL_SKIP = "gate: skip"
43
48
44
49
COMMENT_MARKER = "<!-- pr-gate -->"
50
DEFAULT_REPOSITORY = "danieldaeschle/rusty-teams"
45
51
46
52
47
53
@dataclass
@@ -189,7 +195,8 @@ class GitHub:
189
195
full_url = url if url.startswith("https://") else self.base_url + url
190
196
data = json.dumps(payload).encode() if payload is not None else None
191
197
request = urllib.request.Request(full_url, data=data, method=method)
192
request.add_header("Authorization", f"Bearer {self.token}")
198
if self.token:
199
request.add_header("Authorization", f"Bearer {self.token}")
193
200
request.add_header("Accept", "application/vnd.github+json")
194
201
request.add_header("X-GitHub-Api-Version", "2022-11-28")
195
202
for attempt in range(3):
@@ -299,8 +306,30 @@ def run_gate(github: GitHub, number: int, enforce: bool) -> bool:
299
306
return is_draft or not missing
300
307
301
308
309
def dry_run(github: GitHub, number: int) -> int:
310
_, pull_request = load_pull_request(github, number)
311
missing = check(pull_request)
312
if not missing:
313
print(f"#{number}: ready for review")
314
return 0
315
print(f"#{number}: not ready, missing:")
316
for item in missing:
317
print(f"- {item.replace('**', '')}")
318
return 1
319
320
302
321
def main() -> int:
303
github = GitHub(os.environ["GITHUB_REPOSITORY"], os.environ["GITHUB_TOKEN"])
322
repository = os.environ.get("GITHUB_REPOSITORY") or DEFAULT_REPOSITORY
323
github = GitHub(repository, os.environ.get("GITHUB_TOKEN", ""))
324
if len(sys.argv) > 1:
325
number_argument = re.search(r"(\d+)$", sys.argv[2]) if len(sys.argv) == 3 and sys.argv[1] == "--dry-run" else None
326
if not number_argument:
327
print("usage: python3 .github/scripts/pr_gate.py --dry-run <PR number or URL>", file=sys.stderr)
328
return 2
329
return dry_run(github, int(number_argument.group(1)))
330
if os.environ.get("GITHUB_ACTIONS") != "true":
331
print("Writes to GitHub only run in CI. Locally use --dry-run <PR number>.", file=sys.stderr)
332
return 2
304
333
number = os.environ.get("PR_NUMBER", "").strip()
305
334
if number:
306
335
return 0 if run_gate(github, int(number), enforce=True) else 1
@@ -2,6 +2,9 @@2
2
3
Run by .github/workflows/pr-gate.yml under pull_request_target: it reads the PR as data3
Run by .github/workflows/pr-gate.yml under pull_request_target: it reads the PR as data4
through the API and never checks out or runs code from the PR.4
through the API and never checks out or runs code from the PR.5
6
Locally, before a PR leaves draft: `python3 .github/scripts/pr_gate.py --dry-run <number>`.7
It prints what is missing and changes nothing on GitHub.5
"""8
"""6
9
7
import json10
import json@@ -16,16 +19,18 @@ from dataclasses import dataclass, field16
from typing import Any19
from typing import Any17
20
18
TITLE_PATTERN = re.compile(r"^(feat|fix|perf|refactor|docs|test|chore|ci|build)(\([a-z0-9-]+\))?!?: \S")21
TITLE_PATTERN = re.compile(r"^(feat|fix|perf|refactor|docs|test|chore|ci|build)(\([a-z0-9-]+\))?!?: \S")19
UI_PATH_PATTERN = re.compile(r"^crates/app/src/(views|settings|components|widgets)/|^crates/app/src/[^/]+_view\.rs$|/locales/")22
UI_DIRECTORIES = ("views", "settings", "components", "widgets")23
UI_PATH_PATTERN = re.compile(rf"^crates/app/src/({'|'.join(UI_DIRECTORIES)})/|^crates/app/src/[^/]+_view\.rs$|/locales/")20
IMAGE_PATTERN = re.compile(r"!\[[^\]]*\]\(|<img\s|<video\s|github\.com/user-attachments/|\.(png|jpe?g|gif|webp|mp4|webm)\b", re.IGNORECASE)24
IMAGE_PATTERN = re.compile(r"!\[[^\]]*\]\(|<img\s|<video\s|github\.com/user-attachments/|\.(png|jpe?g|gif|webp|mp4|webm)\b", re.IGNORECASE)21
ISSUE_REFERENCE_PATTERN = re.compile(25
ISSUE_REFERENCE_PATTERN = re.compile(22
r"\b(?:close[sd]?|fix(?:e[sd])?|resolve[sd]?):?\s+(?:https://github\.com/danieldaeschle/rusty-teams/issues/|#)(\d+)", re.IGNORECASE26
r"\b(?:close[sd]?|fix(?:e[sd])?|resolve[sd]?):?\s+(?:https://github\.com/danieldaeschle/rusty-teams/issues/|#)(\d+)", re.IGNORECASE23
)27
)24
NO_VISUAL_CHECKBOX_PATTERN = re.compile(r"^\s*[-*]\s*\[[xX]\]\s*no visible change", re.IGNORECASE | re.MULTILINE)28
NO_VISUAL_CHECKBOX_PATTERN = re.compile(r"^\s*[-*]\s*\[[xX]\]\s*no visible change", re.IGNORECASE | re.MULTILINE)25
FORBIDDEN_PATH_PATTERN = re.compile(r"^(openspec|\.specify|\.kiro)/")29
PLANNING_FOLDERS = ("openspec", ".specify", ".kiro")30
FORBIDDEN_PATH_PATTERN = re.compile(rf"^({'|'.join(re.escape(folder) for folder in PLANNING_FOLDERS)})/")26
WINDOWS_CODE_PATTERN = re.compile(r"^\+.*(cfg\((all\()?windows|target_os\s*=\s*\"windows\")", re.MULTILINE)31
WINDOWS_CODE_PATTERN = re.compile(r"^\+.*(cfg\((all\()?windows|target_os\s*=\s*\"windows\")", re.MULTILINE)27
WINDOWS_PATH_PATTERN = re.compile(r"(^|/)(win32|windows)(/|_[a-z]+\.rs$)|_win(dows)?\.rs$")32
WINDOWS_PATH_PATTERN = re.compile(r"(^|/)(win32|windows)(/|_[a-z]+\.rs$)|_win(dows)?\.rs$")28
LOCKFILE_NAMES =("Cargo.lock", "package-lock.json", "pnpm-lock.yaml", "yarn.lock")33
LOCKFILE_NAMES = ("Cargo.lock", "package-lock.json", "pnpm-lock.yaml", "yarn.lock")29
34
30
MAX_CHANGED_LINES = 40035
MAX_CHANGED_LINES = 40031
MIN_PROBLEM_CHARACTERS = 8036
MIN_PROBLEM_CHARACTERS = 80@@ -42,6 +47,7 @@ LABEL_NO_VISUAL = "gate: no visual"42
LABEL_SKIP = "gate: skip"47
LABEL_SKIP = "gate: skip"43
48
44
COMMENT_MARKER = "<!-- pr-gate -->"49
COMMENT_MARKER = "<!-- pr-gate -->"50
DEFAULT_REPOSITORY = "danieldaeschle/rusty-teams"45
51
46
52
47
@dataclass53
@dataclass@@ -189,7 +195,8 @@ class GitHub:189
full_url = url if url.startswith("https://") else self.base_url + url195
full_url = url if url.startswith("https://") else self.base_url + url190
data = json.dumps(payload).encode() if payload is not None else None196
data = json.dumps(payload).encode() if payload is not None else None191
request = urllib.request.Request(full_url, data=data, method=method)197
request = urllib.request.Request(full_url, data=data, method=method)192
request.add_header("Authorization", f"Bearer {self.token}")198
if self.token:199
request.add_header("Authorization", f"Bearer {self.token}")193
request.add_header("Accept", "application/vnd.github+json")200
request.add_header("Accept", "application/vnd.github+json")194
request.add_header("X-GitHub-Api-Version", "2022-11-28")201
request.add_header("X-GitHub-Api-Version", "2022-11-28")195
for attempt in range(3):202
for attempt in range(3):@@ -299,8 +306,30 @@ def run_gate(github: GitHub, number: int, enforce: bool) -> bool:299
return is_draft or not missing306
return is_draft or not missing300
307
301
308
309
def dry_run(github: GitHub, number: int) -> int:310
_, pull_request = load_pull_request(github, number)311
missing = check(pull_request)312
if not missing:313
print(f"#{number}: ready for review")314
return 0315
print(f"#{number}: not ready, missing:")316
for item in missing:317
print(f"- {item.replace('**', '')}")318
return 1319
320
302
def main() -> int:321
def main() -> int:303
github = GitHub(os.environ["GITHUB_REPOSITORY"], os.environ["GITHUB_TOKEN"])322
repository = os.environ.get("GITHUB_REPOSITORY") or DEFAULT_REPOSITORY323
github = GitHub(repository, os.environ.get("GITHUB_TOKEN", ""))324
if len(sys.argv) > 1:325
number_argument = re.search(r"(\d+)$", sys.argv[2]) if len(sys.argv) == 3 and sys.argv[1] == "--dry-run" else None326
if not number_argument:327
print("usage: python3 .github/scripts/pr_gate.py --dry-run <PR number or URL>", file=sys.stderr)328
return 2329
return dry_run(github, int(number_argument.group(1)))330
if os.environ.get("GITHUB_ACTIONS") != "true":331
print("Writes to GitHub only run in CI. Locally use --dry-run <PR number>.", file=sys.stderr)332
return 2304
number = os.environ.get("PR_NUMBER", "").strip()333
number = os.environ.get("PR_NUMBER", "").strip()305
if number:334
if number:306
return 0 if run_gate(github, int(number), enforce=True) else 1335
return 0 if run_gate(github, int(number), enforce=True) else 1@@ -1,5 +1,7 @@
1
1
import unittest
2
from pathlib import Path
2
3
4
import pr_gate
3
5
from pr_gate import LABEL_ACCEPTED, LABEL_NO_VISUAL, ChangedFile, PullRequest, check, linked_issue_numbers, parse_sections
4
6
5
7
GOOD_BODY = """## Summary
@@ -112,5 +114,37 @@ class GateTests(unittest.TestCase):
112
114
self.assertEqual(missing_keys(make(files=files)), ["Scope", "Scope"])
113
115
114
116
117
class DocumentationTests(unittest.TestCase):
118
"""AGENTS.md and CONTRIBUTING.md repeat the gate's rules; they must name the same values."""
119
120
repository_root = Path(__file__).resolve().parents[2]
121
122
def assert_mentions(self, file_name, *expected):
123
text = (self.repository_root / file_name).read_text()
124
for value in expected:
125
self.assertIn(value, text, f"{file_name} does not mention {value!r}")
126
127
def shared_values(self):
128
return (
129
f"more than {pr_gate.MAX_CHANGED_LINES} changed lines",
130
pr_gate.LABEL_ACCEPTED,
131
pr_gate.LABEL_NO_VISUAL,
132
pr_gate.LABEL_SKIP,
133
*(f"`{folder}/`" for folder in pr_gate.PLANNING_FOLDERS),
134
)
135
136
def test_agents_matches_gate(self):
137
self.assert_mentions(
138
"AGENTS.md",
139
*self.shared_values(),
140
f"at least {pr_gate.MIN_PROBLEM_CHARACTERS} characters",
141
*(f"{directory}/`" for directory in pr_gate.UI_DIRECTORIES),
142
*(f"`## {name}`" for name in pr_gate.REQUIRED_SECTIONS),
143
)
144
145
def test_contributing_matches_gate(self):
146
self.assert_mentions("CONTRIBUTING.md", *self.shared_values())
147
148
115
149
if __name__ == "__main__":
116
150
unittest.main()
@@ -1,5 +1,7 @@1
import unittest1
import unittest2
from pathlib import Path2
3
4
import pr_gate3
from pr_gate import LABEL_ACCEPTED, LABEL_NO_VISUAL, ChangedFile, PullRequest, check, linked_issue_numbers, parse_sections5
from pr_gate import LABEL_ACCEPTED, LABEL_NO_VISUAL, ChangedFile, PullRequest, check, linked_issue_numbers, parse_sections4
6
5
GOOD_BODY = """## Summary7
GOOD_BODY = """## Summary@@ -112,5 +114,37 @@ class GateTests(unittest.TestCase):112
self.assertEqual(missing_keys(make(files=files)), ["Scope", "Scope"])114
self.assertEqual(missing_keys(make(files=files)), ["Scope", "Scope"])113
115
114
116
117
class DocumentationTests(unittest.TestCase):118
"""AGENTS.md and CONTRIBUTING.md repeat the gate's rules; they must name the same values."""119
120
repository_root = Path(__file__).resolve().parents[2]121
122
def assert_mentions(self, file_name, *expected):123
text = (self.repository_root / file_name).read_text()124
for value in expected:125
self.assertIn(value, text, f"{file_name} does not mention {value!r}")126
127
def shared_values(self):128
return (129
f"more than {pr_gate.MAX_CHANGED_LINES} changed lines",130
pr_gate.LABEL_ACCEPTED,131
pr_gate.LABEL_NO_VISUAL,132
pr_gate.LABEL_SKIP,133
*(f"`{folder}/`" for folder in pr_gate.PLANNING_FOLDERS),134
)135
136
def test_agents_matches_gate(self):137
self.assert_mentions(138
"AGENTS.md",139
*self.shared_values(),140
f"at least {pr_gate.MIN_PROBLEM_CHARACTERS} characters",141
*(f"{directory}/`" for directory in pr_gate.UI_DIRECTORIES),142
*(f"`## {name}`" for name in pr_gate.REQUIRED_SECTIONS),143
)144
145
def test_contributing_matches_gate(self):146
self.assert_mentions("CONTRIBUTING.md", *self.shared_values())147
148
115
if __name__ == "__main__":149
if __name__ == "__main__":116
unittest.main()150
unittest.main()@@ -28,8 +28,17 @@ Code under `cfg(windows)` is not compiled by tests on Linux or macOS. CI builds
28
28
29
29
## Before the PR leaves draft
30
30
31
Do this without being asked, before you mark the PR ready for review. Leave it a draft until every item below is in the description. The PR template's HTML comments do not count: a section that is only a comment is empty. The PR gate check enforces the same list (CONTRIBUTING.md, "When a PR is ready for review"). `gate: no visual` and `gate: skip` are for maintainers only.
32
33
The body has `## Summary`, `## AI model`, `## Tests` and `## Review`, plus `## Problem` when item 4 applies and `## Screenshot` when item 6 applies.
34
31
35
1. Commit, run `git fetch origin`, and get at least two independent reviews of `git diff origin/main...HEAD`.
32
36
2. A reviewer must not have written the change. Use a fresh agent session, a subagent, or a review command such as `/code-review` or `/review`. On Copilot, a Copilot code review on the draft PR counts as one.
33
3. Fix or answer every valid finding. In the PR's Review section, write one line per review (what ran it), then one line per finding: fixed, or not fixed and why.
34
4. Check the PR against the table in CONTRIBUTING.md, "When a PR is ready for review". The PR gate check enforces it.
35
5. Commit and PR title: `type(scope): message`. Type is one of `feat fix perf refactor docs test chore ci build`, the scope is lowercase, no emoji. Write it from the user's view. It becomes the release note line.
37
3. Fix or answer every valid finding. In `## Review`, write at least two non-empty lines: one line per review (what ran it), then one line per finding: fixed, or not fixed and why.
38
4. No `Closes` / `Fixes` / `Resolves` plus `#n` or an issue URL on this repo: write `## Problem` (at least 80 characters). Say what is wrong or missing, when a user hits it (steps or when/then), and what should happen instead. Write `Closes #123` only when that issue exists.
39
5. A `feat` PR, or more than 400 changed lines (lockfiles do not count), needs an issue labelled `status: accepted`. A maintainer sets that label. Do not add it yourself. Without it, do not mark the PR ready: say so, or split the change.
40
6. A change under `crates/app/src/views/`, `settings/`, `components/`, `widgets/`, a `crates/app/src/*_view.rs` file, or `locales/` needs a screenshot in the body, taken with `cargo run -p app -- --demo` or `scripts/headless-shot.sh`. No visible change: tick `- [x] No visible change` and say why. Never a real account.
41
7. In `## Tests`, say what ran and what did not. If the diff touches Windows-only code, say whether you built it on Windows.
42
8. No planning folders in the diff (`openspec/`, `.specify/`, `.kiro/`). A `vendor/` change says why in the summary. At most 5 open PRs, drafts included.
43
9. Title: `type(scope): message`. Type is one of `feat fix perf refactor docs test chore ci build`, the scope is lowercase, no emoji. Write it from the user's view. It becomes the release note line.
44
10. Run `python3 .github/scripts/pr_gate.py --dry-run <PR number>`. It must print "ready for review". Only then mark the PR ready.
@@ -28,8 +28,17 @@ Code under `cfg(windows)` is not compiled by tests on Linux or macOS. CI builds28
28
29
## Before the PR leaves draft29
## Before the PR leaves draft30
30
31
Do this without being asked, before you mark the PR ready for review. Leave it a draft until every item below is in the description. The PR template's HTML comments do not count: a section that is only a comment is empty. The PR gate check enforces the same list (CONTRIBUTING.md, "When a PR is ready for review"). `gate: no visual` and `gate: skip` are for maintainers only.32
33
The body has `## Summary`, `## AI model`, `## Tests` and `## Review`, plus `## Problem` when item 4 applies and `## Screenshot` when item 6 applies.34
31
1. Commit, run `git fetch origin`, and get at least two independent reviews of `git diff origin/main...HEAD`.35
1. Commit, run `git fetch origin`, and get at least two independent reviews of `git diff origin/main...HEAD`.32
2. A reviewer must not have written the change. Use a fresh agent session, a subagent, or a review command such as `/code-review` or `/review`. On Copilot, a Copilot code review on the draft PR counts as one.36
2. A reviewer must not have written the change. Use a fresh agent session, a subagent, or a review command such as `/code-review` or `/review`. On Copilot, a Copilot code review on the draft PR counts as one.33
3. Fix or answer every valid finding. In the PR's Review section, write one line per review (what ran it), then one line per finding: fixed, or not fixed and why.37
3. Fix or answer every valid finding. In `## Review`, write at least two non-empty lines: one line per review (what ran it), then one line per finding: fixed, or not fixed and why.34
4. Check the PR against the table in CONTRIBUTING.md, "When a PR is ready for review". The PR gate check enforces it.38
4. No `Closes` / `Fixes` / `Resolves` plus `#n` or an issue URL on this repo: write `## Problem` (at least 80 characters). Say what is wrong or missing, when a user hits it (steps or when/then), and what should happen instead. Write `Closes #123` only when that issue exists.35
5. Commit and PR title: `type(scope): message`. Type is one of `feat fix perf refactor docs test chore ci build`, the scope is lowercase, no emoji. Write it from the user's view. It becomes the release note line.39
5. A `feat` PR, or more than 400 changed lines (lockfiles do not count), needs an issue labelled `status: accepted`. A maintainer sets that label. Do not add it yourself. Without it, do not mark the PR ready: say so, or split the change.40
6. A change under `crates/app/src/views/`, `settings/`, `components/`, `widgets/`, a `crates/app/src/*_view.rs` file, or `locales/` needs a screenshot in the body, taken with `cargo run -p app -- --demo` or `scripts/headless-shot.sh`. No visible change: tick `- [x] No visible change` and say why. Never a real account.41
7. In `## Tests`, say what ran and what did not. If the diff touches Windows-only code, say whether you built it on Windows.42
8. No planning folders in the diff (`openspec/`, `.specify/`, `.kiro/`). A `vendor/` change says why in the summary. At most 5 open PRs, drafts included.43
9. Title: `type(scope): message`. Type is one of `feat fix perf refactor docs test chore ci build`, the scope is lowercase, no emoji. Write it from the user's view. It becomes the release note line.44
10. Run `python3 .github/scripts/pr_gate.py --dry-run <PR number>`. It must print "ready for review". Only then mark the PR ready.@@ -40,10 +40,10 @@ A bot check (`PR gate`) runs on every PR that is not a draft. Until it passes, t
40
40
| Template | Summary, AI model, Tests and Review filled in, not just the hints |
41
41
| Problem | No `Closes #123`: a Problem section says what is wrong or missing, when a user hits it (steps or when/then) and what should happen instead |
42
42
| Issue first | A `feat` PR or more than 400 changed lines (lockfiles do not count) links an issue labelled `status: accepted` |
43
| Screenshot | A change to UI code (`crates/app/src/views/`, `settings/`, locales) shows the changed area with demo data, or ticks "No visible change" with a reason |
43
| Screenshot | A change to UI code (`crates/app/src/views/`, `settings/`, `components/`, `widgets/`, `*_view.rs`, `locales/`) shows the changed area with demo data, or ticks "No visible change" with a reason |
44
44
| Tests | What ran and what did not. A change to Windows-only code says whether it was built on Windows |
45
45
| Review | At least two independent reviews, each finding fixed or answered |
46
| Scope | No planning folders (`openspec/` and the like). A change to `vendor/` says why in the description |
46
| Scope | No planning folders (`openspec/`, `.specify/`, `.kiro/`). A change to `vendor/` says why in the description |
47
47
| Open PRs | At most 5 open PRs, drafts included |
48
48
49
49
A PR that passes gets `status: needs review` and goes into the review queue. `gate: no visual` and `gate: skip` are for maintainers only.
@@ -40,10 +40,10 @@ A bot check (`PR gate`) runs on every PR that is not a draft. Until it passes, t40
| Template | Summary, AI model, Tests and Review filled in, not just the hints |40
| Template | Summary, AI model, Tests and Review filled in, not just the hints |41
| Problem | No `Closes #123`: a Problem section says what is wrong or missing, when a user hits it (steps or when/then) and what should happen instead |41
| Problem | No `Closes #123`: a Problem section says what is wrong or missing, when a user hits it (steps or when/then) and what should happen instead |42
| Issue first | A `feat` PR or more than 400 changed lines (lockfiles do not count) links an issue labelled `status: accepted` |42
| Issue first | A `feat` PR or more than 400 changed lines (lockfiles do not count) links an issue labelled `status: accepted` |43
| Screenshot | A change to UI code (`crates/app/src/views/`, `settings/`, locales) shows the changed area with demo data, or ticks "No visible change" with a reason |43
| Screenshot | A change to UI code (`crates/app/src/views/`, `settings/`, `components/`, `widgets/`, `*_view.rs`, `locales/`) shows the changed area with demo data, or ticks "No visible change" with a reason |44
| Tests | What ran and what did not. A change to Windows-only code says whether it was built on Windows |44
| Tests | What ran and what did not. A change to Windows-only code says whether it was built on Windows |45
| Review | At least two independent reviews, each finding fixed or answered |45
| Review | At least two independent reviews, each finding fixed or answered |46
| Scope | No planning folders (`openspec/` and the like). A change to `vendor/` says why in the description |46
| Scope | No planning folders (`openspec/`, `.specify/`, `.kiro/`). A change to `vendor/` says why in the description |47
| Open PRs | At most 5 open PRs, drafts included |47
| Open PRs | At most 5 open PRs, drafts included |48
48
49
A PR that passes gets `status: needs review` and goes into the review queue. `gate: no visual` and `gate: skip` are for maintainers only.49
A PR that passes gets `status: needs review` and goes into the review queue. `gate: no visual` and `gate: skip` are for maintainers only.