Skip to content

Commit f1230af

Browse files
committed
Merge pull request 'Fix go-gitea#13: verify ADF integration via README docs subsection' (go-gitea#19) from task/13-adf-verify into main
2 parents 668ffaa + 8712c7f commit f1230af

3 files changed

Lines changed: 498 additions & 0 deletions

File tree

.docs/design-13.md

Lines changed: 238 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,238 @@
1+
# Implementation Plan: Verify ADF integration for gitea (#13)
2+
3+
**Status**: Draft
4+
**Research Doc**: `.docs/research-13.md`
5+
**Author**: Ferrox (Rust Engineer agent)
6+
**Date**: 2026-04-30
7+
**Estimated Effort**: 30 minutes
8+
9+
## Overview
10+
11+
### Summary
12+
13+
Demonstrate end-to-end ADF round-trip on issue #13 by:
14+
15+
1. Posting a confirmation comment on #13 (Step 2 in issue body)
16+
2. Adding a small "Documentation" subsection to the existing fork-only
17+
`## Robot API` section of `README.md` that links the four existing
18+
fork-only docs (Step 3 in issue body)
19+
3. Opening a PR via `gtr create-pull` and tagging `@adf:gitea-reviewer`
20+
21+
### Approach
22+
23+
Markdown-only patch on the *already fork-divergent* `README.md`. No code,
24+
no new files, no upstream-clean files touched.
25+
26+
### Scope
27+
28+
**In Scope:**
29+
30+
- Comment on #13 confirming `@adf:gitea-developer` visibility
31+
- Append a "Documentation" subsection to `README.md` Robot API block
32+
- Branch, commit, push, PR
33+
34+
**Out of Scope:**
35+
36+
- Any Go code change
37+
- Any rewrite of existing README content (surgical-changes protocol)
38+
- Any new top-level files
39+
- Any change to upstream-pristine files
40+
41+
**Avoid At All Cost** (from 5/25 analysis):
42+
43+
- Editing `CHANGELOG.md` -- noisy fork divergence already
44+
- Adding a new `FORK.md` -- proliferates roots
45+
- Touching the existing Robot API CLI / Docker subsections -- not requested
46+
- Linting drive-bys on AGENTS.md or unrelated markdown -- prohibited
47+
- Generating `.docs/research-13.md` follow-ups (already complete)
48+
49+
## Architecture
50+
51+
### Component Diagram
52+
53+
```
54+
[Agent: Ferrox]
55+
|--> gtr comment --> Issue #13 (visibility confirmation)
56+
|--> git branch + edit README.md
57+
|--> git commit + push
58+
'--> gtr create-pull --> PR (mentions @adf:gitea-reviewer)
59+
```
60+
61+
### Data Flow
62+
63+
```
64+
Issue #13 body -> agent reads --> agent comments --> validator ticks Step 2
65+
|
66+
+-> agent edits README --> commit --> PR --> Step 3 ticked on merge
67+
```
68+
69+
### Key Design Decisions
70+
71+
| Decision | Rationale | Alternatives Rejected |
72+
|----------|-----------|----------------------|
73+
| Patch `README.md` Robot API block (additive subsection) | Already fork-divergent (+79 lines vs upstream); section exists; addition genuinely improves docs discoverability | New `FORK.md` (proliferates); CHANGELOG edit (noisy); upstream-clean file edit (cherry-pick debt) |
74+
| Use `gtr create-pull` over browser | Keeps full integration test in scope -- this is the verification | Browser (skips a hop of the round-trip we're verifying) |
75+
| Single commit | One commit = one reviewable unit; trivial change does not warrant multi-step | Multi-commit (overhead with no benefit at this size) |
76+
77+
### Eliminated Options (Essentialism)
78+
79+
| Option Rejected | Why Rejected | Risk of Including |
80+
|-----------------|--------------|-------------------|
81+
| Adding a Robot API HTTP test | #13 is verification of the *agent pipeline*, not the API surface | Scope creep, opens design questions out of #13 |
82+
| Reformatting existing README content | "Surgical changes" protocol -- only touch what is requested | Drive-by churn; reviewer noise |
83+
| Backporting a fix from #16 | Different issue, different gate | Cross-issue contamination |
84+
| Editing `CONTRIBUTING.md` | Not requested; already fork-divergent (+436 lines) -- adding more noise without prompt | Reviewer rejects on scope |
85+
86+
### Simplicity Check
87+
88+
> What if this could be easy?
89+
90+
It is. The change is:
91+
92+
```markdown
93+
### Documentation
94+
95+
- [Robot API security model](docs/ROBOT_SECURITY.md)
96+
- [MCP server reference](docs/MCP_SERVER.md)
97+
- [Robot CLI testing guide](docs/ROBOT_CLI_TESTING.md)
98+
- [End-to-end testing scenario](docs/E2E_TESTING_SCENARIO.md)
99+
```
100+
101+
Six lines of markdown, inserted after an existing subsection header.
102+
A senior engineer would not call this overcomplicated.
103+
104+
**Nothing Speculative Checklist**:
105+
106+
- [x] No features the user did not request
107+
- [x] No abstractions "in case we need them later"
108+
- [x] No flexibility "just in case"
109+
- [x] No error handling for scenarios that cannot occur
110+
- [x] No premature optimisation
111+
112+
## File Changes
113+
114+
### New Files
115+
116+
| File | Purpose |
117+
|------|---------|
118+
| `.docs/research-13.md` | Phase 1 V-Model artefact (already created) |
119+
| `.docs/design-13.md` | Phase 2 V-Model artefact (this document) |
120+
121+
### Modified Files
122+
123+
| File | Changes |
124+
|------|---------|
125+
| `README.md` | Append "Documentation" subsection to existing `## Robot API` block (~6 lines) |
126+
127+
### Deleted Files
128+
129+
None.
130+
131+
## API Design
132+
133+
Not applicable. No public API change.
134+
135+
## Test Strategy
136+
137+
### Unit Tests
138+
139+
Not applicable. Markdown-only patch.
140+
141+
### Integration Tests
142+
143+
The PR opening *is* the integration test for #13. Specifically:
144+
145+
| Test | Location | Purpose |
146+
|------|----------|---------|
147+
| Comment lands on #13 | live Gitea API | Step 2 of issue body |
148+
| Branch pushes successfully | live Gitea API | Confirms write permission |
149+
| PR opens via `gtr create-pull` | live Gitea API | Step 3 of issue body |
150+
| `make fmt` clean | local | Pre-commit hygiene |
151+
| `make vet` clean | local | Pre-commit hygiene |
152+
153+
### Property Tests
154+
155+
Not applicable.
156+
157+
## Implementation Steps
158+
159+
### Step 1: Confirmation comment on #13
160+
161+
**Files:** none
162+
**Description:** Post a comment to #13 starting with `[ferrox]` authorship
163+
attribution per `AGENTS.md`, confirming agent visibility and the planned
164+
PR contents.
165+
**Tests:** `gtr comment` exit code zero; comment visible via
166+
`gtr view-issue --index 13`.
167+
**Estimated:** 2 min
168+
169+
### Step 2: Branch + README patch
170+
171+
**Files:** `README.md`
172+
**Description:** Create branch `task/13-adf-verify`. Append a
173+
`### Documentation` subsection to the existing `## Robot API` block in
174+
`README.md`, listing the four fork-only docs.
175+
**Tests:** Visual diff inspection; rendered preview via raw markdown.
176+
**Estimated:** 5 min
177+
178+
### Step 3: Pre-commit hygiene
179+
180+
**Files:** none (verification only)
181+
**Description:** Run `make fmt` (no Go change but exercises pre-commit
182+
expectation) and `make vet` (sanity).
183+
**Tests:** Both commands exit zero; `git status` shows only the README
184+
change and the two new `.docs/*.md` files.
185+
**Estimated:** 3 min
186+
187+
### Step 4: Commit + push
188+
189+
**Files:** committed
190+
**Description:** Single commit, `[ferrox]` prefix, `Refs #13` trailer.
191+
**Tests:** `git log -1` shows the expected message; `git push` succeeds.
192+
**Estimated:** 2 min
193+
194+
### Step 5: PR + mention
195+
196+
**Files:** none
197+
**Description:** `gtr create-pull --owner terraphim --repo gitea --base main
198+
--head task/13-adf-verify --title "Fix #13: verify ADF integration via
199+
README docs subsection"`. Body mentions `@adf:gitea-reviewer`.
200+
**Tests:** PR visible via `gtr list-pulls`; PR number returned.
201+
**Estimated:** 3 min
202+
203+
## Rollback Plan
204+
205+
If issues are discovered post-merge:
206+
207+
1. `git revert <merge-commit>` on `main`
208+
2. The README change is purely additive -- revert is mechanical and safe
209+
3. No data migration, no feature flag, no consumer impact
210+
211+
## Migration
212+
213+
Not applicable.
214+
215+
## Dependencies
216+
217+
### New Dependencies
218+
219+
None.
220+
221+
### Dependency Updates
222+
223+
None.
224+
225+
## Performance Considerations
226+
227+
Not applicable -- markdown-only patch.
228+
229+
## Open Items
230+
231+
None.
232+
233+
## Approval
234+
235+
- [x] Technical review complete (self-review given trivial scope)
236+
- [x] Test strategy approved (integration test = the PR itself)
237+
- [x] Performance targets agreed (n/a)
238+
- [ ] Human approval received (awaiting reviewer on PR)

0 commit comments

Comments
 (0)