Repository navigation
add-register-edit-lane: fulfilment lane + apply button + watcher - #95
Merged
Merged
Conversation
…e watcher Ratified change realizing Brett's 'automate step 2' directive: a lane that applies dispatched create-project/edit-project commissions to the register (surgical block edits, comments preserved, pinned-schema validation before write), commits ONLY the register file and pushes with pull-rebase retry — git failure leaves the file edited and the descriptor dispatched. Exposed as POST /actions/apply-register-edits (loopback + gate actor), surfaced as the '⟳ apply N pending' header button, and runnable as a polling watcher (python3 -m ideation_dashboard.register_edit_lane --watch). 5 lane tests + wire test; renderer fetch pins widened to the named apply route; live browser check green (commission → apply → committed+pushed → button retires). Tasks 1.1-3.4 ticked; 3.5 (first unattended fulfilment) is Brett's. Co-Authored-By: Claude Fable 5 <[email protected]>
There was a problem hiding this comment.
Hi @brettheap! 👋
Your private repo does not have access to Sourcery.
Please upgrade to continue using Sourcery ✨
There was a problem hiding this comment.
Pull request overview
Implements the ratified add-register-edit-lane change for the ideation dashboard: a fulfilment lane that applies dispatched create/edit project commissions to project-register.yaml, plus a loopback-gated server route and a header button to run the lane on demand (with watch mode documented).
Changes:
- Added
register_edit_lane.pywith one-shot + watch-mode fulfilment, schema validation before write, and register-only git commit/push behavior. - Added
POST /actions/apply-register-editsand UI affordance (“⟳ apply N pending”) that triggers the lane and reloads on success. - Added verification coverage for the lane + wire route, plus updated renderer fetch pinning and runbook docs.
Reviewed changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| tests/ideation-dashboard/test_renderer.py | Updates fetch-site pin counts and adds the new apply route constant assertion. |
| tests/ideation-dashboard/test_register_edit_lane.py | Adds lane-level tests plus a real HTTP wire test for the apply route. |
| scripts/ideation_dashboard/web/views/repo-selector.js | Introduces the apply route constant and renders the “apply pending” header button. |
| scripts/ideation_dashboard/serve.py | Adds /actions/apply-register-edits route handler that invokes the lane and returns its report. |
| scripts/ideation_dashboard/register_edit_lane.py | New fulfilment lane implementation (apply, validate, deliver stamps, git commit/push, watch mode). |
| openspec/changes/add-register-edit-lane/tasks.md | Tracks implementation and verification tasks for the change. |
| openspec/changes/add-register-edit-lane/specs/ideation-dashboard/spec.md | Adds requirements/scenarios for the lane + button + watcher behavior. |
| openspec/changes/add-register-edit-lane/proposal.md | Records the ratified proposal, rationale, and non-goals. |
| docs/ideation-dashboard-session-runbook.md | Documents how to run the watcher and what the apply button does. |
Suppressed comments (1)
scripts/ideation_dashboard/register_edit_lane.py:141
- When removals delete the last block-style repository member, the function can leave a bare "repositories:" key with no list items. YAML parses that as null, which will fail schema validation and incorrectly refuse a satisfiable "remove" commission. The lane should collapse an empty membership back to an explicit empty list ("repositories: []").
drop = {current[r] for r in removed}
out = [line for i, line in enumerate(lines) if i not in drop]
if added:
# re-locate after removals, then place additions at the block's end
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+126
to
+136
| added = [str(r) for r in (job.get("add") or [])] | ||
| removed = [str(r) for r in (job.get("remove") or [])] | ||
| current = {lines[i].strip()[2:]: i for i in _member_lines(lines, start, end)} | ||
|
|
||
| stale_add = [a for a in added if a in current] | ||
| if stale_add: | ||
| return None, "already a member: " + ", ".join(stale_add) | ||
| stale_rm = [r for r in removed if r not in current] | ||
| if stale_rm: | ||
| return None, "not currently a member: " + ", ".join(stale_rm) | ||
|
|
Comment on lines
+245
to
+246
| def fulfil_once(repo_root: Path | str, *, git: bool = True, | ||
| delivered_by: str = DELIVERED_BY) -> LaneReport: |
Comment on lines
+236
to
+242
| for _ in range(2): | ||
| push = run("push") | ||
| if push.returncode == 0: | ||
| report.pushed = True | ||
| return | ||
| run("pull", "--rebase") | ||
| report.error = "git push failed after rebase retry" |
Comment on lines
+2105
to
+2108
| except Exception as exc: # noqa: BLE001 - a lane crash must answer, not hang | ||
| self._send_json(500, {"ok": False, "error": "lane_failed", | ||
| "message": str(exc)[:300]}) | ||
| return |
This was referenced Oct 7, 2026
brettheap
added a commit
that referenced
this pull request
Oct 8, 2026
…entity bound by layer, the single-writer rows and the holder's batch-3 flags (plan 038) (#1263) Lane: openxfactory-4 (openXfactory-4-openDox_extraction) ## T002c: plan 038's third bookkeeping batch (plan 038) Bookkeeping: no `Arc:` line, and no `openspec/changes/` path. It encodes rulings already posted on #656 and landings already merged, each cited by comment id or merge commit, with no new decision. It follows #1251 and #1257 in form, and redoes nothing either did. #1257 landed as `c70bdbd9`, so this PR is not stacked; `origin/main` (`c9dfd4f8`) is merged into the branch, never rebased. **Realizes / Falsifier:** none (bookkeeping). The gates are listed under "Gates" below. ### What changed (specs/038-opendox-document-tool-self-maintenance/) **Ticks, each merge commit read through GraphQL (`pullRequest{mergeCommit{oid}}`) before it was written.** The sweep covered every PR merged since 2026-10-06T23:30Z in openDox-code, openXdox-code, openDox, openXdox, openDox-spec and openxFactory, re-run at 2026-10-08T16:16Z: - openXdox-code: T095 #46 → `e2340bb6`, T101 #48 → `8b0401a1`, T098 #51 → `fc1115d6`, T103 #49 → `6f259156`, T096 #53 → `34e1c1f2`, T100 #54 → `2a3d8c09`, T099 #47 → `4aa3070a`, T102 #52 → `e7815ac5`, T097 #50 → `4dab93fc`, T022 #41 → `aefd1091`. - openDox-code: T104 #94 → `d616da3e`, T072 #95 → `99220883` (the arc's first realization). - Follow-ons recorded on the task they follow: T021's openXdox-code#55 → `da736090`, and T096's openXdox-code#56 → `9720925e`. - T095's Landed line also records Copilot r4201411760 as the holder's READY note did (`6027382308`, accepted limit under `5988818366`; the fix rides T073). - Nothing is ticked whose PR has not merged. T029 and T073 (openXdox-code#44, #45) and T012/T013 (openDox-code#90) stay open. **New task T105** (R2-INV-P5, read-only, lane 3; holder `6027341795`, claimed `6027346843`): ticked on lane 3's DONE line (2026-10-07T00:28:59Z), its summary `6028122920`, the map `lane-coord-034/r2/R2-INV-P5.md`, and the holder's ruling `6028138991`. Verdicts: T041, T042 and T043 READY-WITH-NOTES; T045, T047, T048 and T049 blocked by plan order only. Placed under "Wave 1's readiness" before W1, with a row in the Phase 5 slice table. The task count is 91 and plan.md's two stale "79 tasks" cites now read 91 tasks and T001 to T105 (`6028364555` item 5). **The four slice notes** (`6028138991`; no requirement or falsifier changes), as implementation notes on T042, T043, T045 and T047, refined by the holder's batch-3 flags (`6028364555`) and the Copilot-thread ruling (`6064169640`): - T042: the token `RESET_CONFIRMATION` stays byte-identical, its wording may change; Files gain `docs/runtime.md` (R2-INV-P5 § T042: its two table arrays move with `identity.TABLES`, which `test_deploy_shape.py` holds); `RULED_TABLES` is encoded as the map words it. - T042's SQL column is `full_run` (`6064169640`, fix-now, resolving Copilot 4205521074): the words "quote it or" are gone from T042, and `data-model.md` gains one line saying the SQL column is `full_run` because PostgreSQL 16 reserves `full`. **Files and falsifiers:** - T073: Files gain `tests/test_host_plane.py` and the `opendox-snapshot-*` farm exclusion scoped to the `opendox_spec` owner; the falsifier gains the farm case (Copilot r4201411760, accepted at #46's landing, `6027382308`, reply 4201421102). plan.md's conftest and `test_host_plane.py` rows, and the T020, T026 and T095 Files chains, end with T073. - T015 and T016: Files gain `tests/test_capability_honesty.py` and `tests/test_lens_seed_actions.py` (`6027633398`), with the same-kind enumeration collateral pre-authorized in the minimal way and listed in each PR body, and `tests/test_default_profile.py` (`6023619783` item 1, corrected by `6026622117` item 2), with the chain T015 → T016. plan.md gains two single-writer rows. - T041, T046, T057: the `identity` bound is split by layer (`6027706377` item 1, refining `6018624750`). T041 narrows to the module's own serialized finding shape; T046 gains it on `health list --json`; T057 gains it on the HTTP Health response; FR-011's coverage row cites all three. - T022's falsifier gains the root-`.gitignore` source check (`6026275158` item 2); T102's gains the widened no-bypass scan (`6026275158` item 3); `6028364555` item 4. - T012's Ruled line: `6026275158` item 1 and `6026622117` item 1. - T072's Files name openDox-code#95, and T071's entry names its ratification record, openxFactory#1261 (a DRAFT PR that exists now). T015's PR does not exist yet, so its number is not named. **Qualifiers and counts:** "plan 034's" on spec.md (two places) and clarify-questions.md (one place), found by content, nothing else moved (`6027706377` item 2). tasks.md's header and plan.md each carry a revision paragraph. ### Ruled and Decisions Ruled (all on #656): `6027341795`, `6027346843`, `6027382308`, `6027633398`, `6027706377`, `6026275158`, `6026622117`, `6023619783`, `6028122920`, `6028138991`, `6028364555`, `6064169640`. Decisions: none new. ### Readings, disclosed - T042's Files wording follows R2-INV-P5 § T042 (the `docs/runtime.md` arrays move with `identity.TABLES`); the holder's `6028364555` item 2 words the cause as the `full` rename, and cites the same map section. - plan.md's `tests/test_default_profile.py` row says the chain "follows `default_profile.py`'s", as `6023619783` words it; T046 and T057 are not given the file in their own Files lines. - `6023619783` item 2 (T071's record header) is not in this batch's items and is not encoded here. - Lane 3's other R2-INV-P5 observations (moved #1144 line references, floor and census counts, T015's census line) stay informational and are not encoded (`6028364555` item 7). ### Gates - `python3 scripts/validate-openspec-cli-pin.py --all --strict` at the merged head `b236fa6c`: exit 0 (the one accepted exception is `add-chain-attestation`'s disposition, as on main). - doc-health (`scripts/doc-health.py --single-repo .`) at `b236fa6c` against `origin/main` `c9dfd4f8`, same clone: identical reports, 31 critical, 26 error, 69 warning, 19 info, zero differences after SHA normalization. - Local `python -m pytest tests/ -q -m "not postgres" -n 8` at `3e6feb6b`: 9206 passed, 7 skipped, 1 failed. The failure is `tests/hermes_runtime_contracts/test_validator_cli.py::test_release_mode_field_is_preserved_on_the_real_repository[--require-realization-realization]`, a 30 s subprocess timeout that fails identically on `origin/main` in the same clone. Later commits change only spec text and chain records. - CI at the head `b236fa6c`: every check SUCCESS (rollup SUCCESS, read through GraphQL), including `pytest-suite`, `doc-health-py314`, `openspec-cli-pin` and SonarCloud. The head adds only the merge of `origin/main` `c9dfd4f8` (the archive of amend-worker-input-budget-dispatch-wording, #1269) to `c675894d`, whose rollup was SUCCESS too. - Copilot: at `a9fc7e7b` two threads (4205521074 → fixed in `4263d665` on `6064169640`; 4205521173 → fixed in `c3409c03`). At `3e6feb6b` two threads (4221525148, the PR description, updated; 4221525277, the T020, T026 and T095 chains, fixed in `c675894d`). At `c675894d` and at the head `b236fa6c`: "Approval recommended", 0 open findings. All four threads are answered and resolved. ### NOT done No requirement text, no contract file and no `openspec/changes/` path is touched. No box is ticked in #1144. refs #656 🤖 Generated with [Claude Code](https://claude.com/claude-code) Lane: openxfactory-4 Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Realizes the ratified
add-register-edit-lanechange (Brett's directive: "we need to automate that step 2. we need an update button plus a job that watches", with the two follow-up rulings: the lane does edit+commit+push, and the serve runs the lane behind the button).What ships
scripts/ideation_dashboard/register_edit_lane.py— scans dispatchedcreate-project/edit-projectcommission descriptors, applies them toproject-register.yamlwith surgical block edits (comments preserved; D17 empty-create legal;[]→ list conversion), validates against the pinned schema BEFORE writing, then commits only the register file (explicit pathspec) and pushes with pull-rebase retry. Descriptors flip todelivered(withdelivered_at/delivered_by) only after the push lands; any git failure leaves the file edited and the descriptor dispatched, per ruling. Stale commissions refuse-and-report. CLI:python3 -m ideation_dashboard.register_edit_lane --repo-root . [--watch --interval N] [--no-git].POST /actions/apply-register-edits— loopback + gate-actor guarded; runs the lane once against the serve's checkout root; 409 with the report on failure.Verification
tests/ideation-dashboard/test_register_edit_lane.py): comment-preserving create/add/remove incl. empty form, stale refusal stays dispatched, register-only commit against a bare remote with a dirty unrelated file untouched, git-failure envelope, apply route over real HTTP.openspec validate --all --strictgreen.Tasks 1.1–3.4 ticked; 3.5 (first unattended fulfilment) stays open for Brett.
🤖 Generated with Claude Code