docs(worker): document company mode (fetch, push, draft PR) and its open smoke tests
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
# Review, merge & conflict resolution
|
||||
|
||||
> **Explore-note — verify before trusting.** Distilled map of a subsystem, not authoritative.
|
||||
> Last verified against `44d94caa` (2026-10-01), which made the parent's worktree the unit
|
||||
> branch (children fast-forwarded into it).
|
||||
> Last verified against `0e6a48e2` (2026-10-01): parent's worktree is the unit branch (children
|
||||
> fast-forwarded into it); in a company repo approve ends in a pushed branch + draft PR.
|
||||
> Planning mode renders per file and `DiffLinesView` is retired.
|
||||
> Drift check: `git log --oneline 20bce9b..HEAD -- src/ClaudeDo.Worker/Lifecycle src/ClaudeDo.Worker/State src/ClaudeDo.Worker/Planning src/ClaudeDo.Ui/ViewModels/Conflicts src/ClaudeDo.Worker/External`
|
||||
> Stable structure only (no line numbers). See docs/explore-notes/README.md.
|
||||
@@ -28,6 +28,19 @@ There is no separate "Merge all" entry.
|
||||
- **Child of a unit** (parent has an `Active` worktree) → `ApproveAndMergeAsync` absorbs it into
|
||||
the unit branch (`UnitBranchService.AbsorbChildAsync`, ff-only) instead of merging to the target.
|
||||
- **No active worktree** (sandbox run) → straight to `Done`.
|
||||
- **Company repo** (`PullRequestPublisher.IsCompanyRepoAsync`, origin matches
|
||||
`company_remote_pattern`, checked live) with an `Active` worktree → `ApproveCompanyAsync`
|
||||
instead of a merge, after the planning-parent gate and the child absorb: missing PAT / non-ADO
|
||||
remote is `blocked` before anything runs, then the verify command in the **worktree**
|
||||
(`skipVerify` ignored — no local merge to defer it to; red = `verify_failed`, nothing pushed),
|
||||
then `PullRequestPublisher.PublishAsync`: `git push -u origin <branch>` (PAT via `GIT_CONFIG_*`
|
||||
env, `AzureDevOpsClient.GitAuthEnv`), find-or-create the draft PR, store
|
||||
`worktrees.pull_request_url`, `WorktreeUpdated`. Result `pr_created` / `pr_updated` + URL
|
||||
(`MergeResult.PullRequestUrl`; MCP puts it in `mergeMessage`). Task stays `WaitingForReview`,
|
||||
worktree `Active`, ticket `InBearbeitung`; `Done` is the user's manual toggle after the ADO
|
||||
merge. A PR failure after a successful push is `blocked` with `gepusht, PR fehlgeschlagen: …`.
|
||||
⚠️ Only approve branches — `merge_task`/the merge modal and the legacy-unit orchestrator still
|
||||
merge locally in a company repo.
|
||||
|
||||
Review transitions all live in `TaskStateService`: `SubmitForReviewAsync`,
|
||||
`SubmitForChildrenAsync`, `ApproveReviewAsync`, `RejectToQueueAsync`, `RejectToIdleAsync`,
|
||||
|
||||
@@ -74,6 +74,24 @@ Bleibt manuell zu prüfen (UI-Pfad, nie sichtbar gelaufen):
|
||||
- [ ] Base-URL leeren → Menüeintrag verschwindet, keine Netzwerkaufrufe mehr.
|
||||
- [ ] Sichtprüfung des Settings-Tabs + des Ticket-Projekt-Dropdowns (nie gerendert gesehen).
|
||||
|
||||
## Offene Verifikation (2026-10-01, Unit-Branch Teil 3: Firmen-Modus / Draft-PR)
|
||||
|
||||
Build + gefilterte Tests grün (Worker: AzureDevOps/CompanyFetchBase/CompanyApprove/CommitMessageBuilder,
|
||||
Ui: TicketSettingsTab/MergeSectionCompanyRepo, Data: PromptFiles, Localization). **Nie gegen echtes ADO,
|
||||
nicht visuell geprüft:**
|
||||
|
||||
- [ ] Sichtprüfung: Settings-Reiter heißt „Externe Dienste", Abschnitt Azure DevOps (PAT, Test, Löschen);
|
||||
Detail-Pane im Firmen-Repo: kein Ziel-Dropdown, Button „Draft-PR erstellen" → nach dem Approve
|
||||
„PR aktualisieren" + Button „Pull Request öffnen"; Approve bleibt hinter „Diff öffnen" gegated.
|
||||
- [ ] PAT eintragen, „Verbindung testen" — meldet Repo + Default-Branch der ersten Firmen-Liste.
|
||||
- [ ] Ticket-Task in einem echten Firmen-Repo bis zum Draft-PR: Branch `<typ>/<ticket>-<slug>` startet
|
||||
von frisch gefetchtem `origin/<basis>`, Commit ohne `ClaudeDo-Task:`-Trailer, PR-Titel
|
||||
`…, Resolves #<id>`, Beschreibung mit Ticket-Link (Projekt-Id-Lookup über `GET /api/ticket/{id}`
|
||||
ist nur gegen den Stub getestet) und `Geprüft:`-Zeile, Task bleibt WaitingForReview.
|
||||
- [ ] Zweiter Approve nach Reject mit Feedback → `pr_updated`, derselbe PR bekommt die neuen Commits.
|
||||
- [ ] Planning-Unit mit 2 Children im Firmen-Repo → ein PR für die ganze Unit.
|
||||
- [ ] API-Version-Fallback (Server meldet „supports is X") ist nur gegen den Stub getestet.
|
||||
|
||||
## Offene Verifikation (2026-10-01, Ticket-Import über alle Projekte)
|
||||
|
||||
Build + Unit-Tests grün, **nicht visuell/live verifiziert**:
|
||||
|
||||
Reference in New Issue
Block a user