v1 plan: task 06 must update the one admin.Handler call in main.go for the gate; note the finding
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
@@ -20,7 +20,7 @@ from a blank file. This task commits all of them.
|
||||
## Files
|
||||
|
||||
- Already copied (verify with `cmp`, never edit): `internal/admin/admin_test.go`, `example.toml`
|
||||
- Modify: `internal/admin/admin.go` (split if over 400 lines), `docs/implementer-log.md`
|
||||
- Modify: `internal/admin/admin.go` (split if over 400 lines), `cmd/crossbar/main.go` (one call, see step 5), `docs/implementer-log.md`
|
||||
- Already modified, commit as they are after their tests pass: `internal/store/store.go`, `internal/store/schema.go`, `internal/lease/lease.go`
|
||||
|
||||
## Interfaces
|
||||
@@ -109,12 +109,14 @@ Endpoints (all JSON unless said; errors `{"error":"…"}`; wrong method → 405
|
||||
- [ ] **2. Confirm the inherited pieces pass.** `go test -race -count=1 ./internal/store/ ./internal/lease/`. Expected: both `ok`.
|
||||
- [ ] **3. Write `internal/admin/admin.go`** (delete the draft first if it is easier). `gofmt -w internal/admin/`.
|
||||
- [ ] **4. See the test pass.** `go test -race -count=1 ./internal/admin/`. Expected: `ok`.
|
||||
- [ ] **5. Run the gate.** `make gate`. Expected last line: `gate: ok`. (`cmd/crossbar` still passes
|
||||
nils to `proxy.New`; that is task 07's job and does not fail the gate.)
|
||||
- [ ] **5. Make the module build.** The new `admin.Handler` signature breaks the one call in
|
||||
`cmd/crossbar/main.go`; change that call to `admin.Handler(cfg, table, nil, nil, nil, nil)` and
|
||||
nothing else in that file (task 07 wires the real values). Then `make gate`. Expected last line:
|
||||
`gate: ok`.
|
||||
- [ ] **6. Log and commit.** Row `v1/06-admin`. Deviations: say that the store and lease additions came from the earlier session.
|
||||
|
||||
```sh
|
||||
git add internal/admin internal/store internal/lease example.toml docs/implementer-log.md
|
||||
git add internal/admin internal/store internal/lease cmd/crossbar example.toml docs/implementer-log.md
|
||||
git commit
|
||||
```
|
||||
|
||||
|
||||
@@ -115,3 +115,7 @@ tools/run-plan.sh docs/plans/v1 # from a clean checkout on master
|
||||
Split into `06-admin.md` (handler only; inherits the store/lease additions from the tree) and
|
||||
`07-main.md` (wiring); the smoke task became 08. Session stopped by the owner; the broken
|
||||
`admin.go` draft was left in the tree for the next session to replace.
|
||||
- 2026-09-25, task 06 (admin), during the run: the task text said the wiring in `cmd/crossbar`
|
||||
"does not fail the gate", but `go vet ./...` compiles `main.go`, whose two-argument
|
||||
`admin.Handler` call no longer matches — the gate does fail. Ornith noticed while reading.
|
||||
Task fault (mine): step 5 now allows the one-call edit to `main.go`.
|
||||
|
||||
Reference in New Issue
Block a user