Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
53fdc62
feat(label-governance): add the locked-files guard and inventory toke…
claude Oct 2, 2026
465c740
docs(changelog): record the locked-files guard and inventory token ch…
claude Oct 2, 2026
cb0e270
feat(label-governance): count approvals only on tagged change-request…
claude Oct 2, 2026
f3e3e87
docs(changelog): reword the inventory token entry for the changelog v…
claude Oct 2, 2026
a599d75
Merge develop into feat/label-governance-guards
Oct 2, 2026
35884df
fix(label-governance): reject unverifiable private repository invento…
coderabbitai[bot] Oct 2, 2026
e261650
fix(guard): fail closed on truncated file lists and untruncated issue…
Oct 2, 2026
5b862f6
Merge remote-tracking branch 'origin/develop' into HEAD
eleshar Oct 4, 2026
e1f8538
Merge branch 'develop' into feat/label-governance-guards
lightspeed-docs-bot[bot] Oct 4, 2026
94df949
Merge branch 'develop' into feat/label-governance-guards
lightspeed-docs-bot[bot] Oct 4, 2026
2cdf923
Merge branch 'develop' into feat/label-governance-guards
lightspeed-docs-bot[bot] Oct 4, 2026
7682eeb
Merge remote-tracking branch 'origin/develop' into feat/label-governa…
eleshar Oct 4, 2026
f5b4b20
Merge branch 'develop' into feat/label-governance-guards
lightspeed-docs-bot[bot] Oct 4, 2026
6d50ebb
Merge branch 'develop' into feat/label-governance-guards
lightspeed-docs-bot[bot] Oct 4, 2026
f8ff96a
Merge branch 'develop' into feat/label-governance-guards
lightspeed-docs-bot[bot] Oct 4, 2026
05937e2
Merge branch 'develop' into feat/label-governance-guards
lightspeed-docs-bot[bot] Oct 4, 2026
e50caf4
Merge branch 'develop' into feat/label-governance-guards
lightspeed-docs-bot[bot] Oct 4, 2026
09f1601
Merge branch 'develop' into feat/label-governance-guards
lightspeed-docs-bot[bot] Oct 4, 2026
18e2144
Merge branch 'develop' into feat/label-governance-guards
lightspeed-docs-bot[bot] Oct 4, 2026
5a81f8e
Keep private repositories out of the public label inventory, drift is…
eleshar Oct 4, 2026
fa95244
Mint the private report token in the workflow from the installed App …
eleshar Oct 4, 2026
e99c0d8
Merge branch 'develop' into feat/label-governance-guards
lightspeed-docs-bot[bot] Oct 5, 2026
3927426
Merge remote-tracking branch 'origin/develop' into feat/label-governa…
eleshar Oct 5, 2026
2e85881
Merge branch 'develop' into feat/label-governance-guards
lightspeed-docs-bot[bot] Oct 5, 2026
f65bae0
Merge remote-tracking branch 'origin/develop' into feat/label-governa…
eleshar Oct 5, 2026
e46de68
Remove the changelog entries duplicated by the develop merge
eleshar Oct 5, 2026
db6e31e
Run the locked files guard from the default branch definition
eleshar Oct 5, 2026
e246073
Record the pull_request_target Actions policy requirement for the loc…
eleshar Oct 5, 2026
daf5cc5
Route private-repository dry-run records and approvals through the pr…
eleshar Oct 5, 2026
e586b83
Fail the locked files guard closed and read it from the default branc…
eleshar Oct 5, 2026
32eaf03
Extract the shared search budget into enrichAllGithubRows and test it
eleshar Oct 5, 2026
0858a3f
Scope the private report token to the owner in PRIVATE_REPORT_REPO an…
eleshar Oct 5, 2026
82be610
Make T080a a repository admin step with the exact Actions policy call
eleshar Oct 5, 2026
3032820
Record that the pull_request_target Actions policy exists
eleshar Oct 5, 2026
ea1774f
Name failed issue lookups in the guard failure; require exactly two s…
eleshar Oct 5, 2026
39a3147
Ignore references in fenced code; confine full inventory output to .p…
eleshar Oct 5, 2026
5042e40
Ignore references in indented code; keep private SC-011 and SC-012 re…
eleshar Oct 5, 2026
d38612a
Find a pull request body's linked issues by rendering it with GitHub'…
eleshar Oct 5, 2026
6fe26a1
Find the repository root from the script location for the full-output…
eleshar Oct 5, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Defines the per-repository deletion dry run that @ashleyshaw approves before any

## Per-repository dry run

Saved as `evidence/dry-run/{repo}.json` and summarised in a comment on the gate issue that replaces #95.
Saved as `evidence/dry-run/{repo}.json` and summarised in a comment on the gate issue that replaces #95. For a private repository the file stays under `.private-evidence/dry-run/` and is neither committed nor summarised in the public gate issue (decision of 2026-10-04).

```json
{
Expand Down
2 changes: 1 addition & 1 deletion .github/specs/008-label-audit-consolidation/plan.md
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,7 @@ Each stage starts only when the previous stage's exit check passes. Validation s
| 0a. Issue types and colours (configuration done in #3534; T040c to do) | PR updating `issue-types.yml` (25 entries with descriptions, Decision replaces Question) and `type:*` label colours in `labels.yml` from `contracts/issue-types-org-settings.md`, together with the Decision template and `issue-fields.yml`; then a manual update of the organisation's issue types page in the order given in the contract | for #3534, which merged on 2026-09-25 before approval, T040n's dated sign-off on #3556 and #3557 (or a revert of any rejected part); for every later locked-file PR, approval before merge (FR-009); configuration validation and `npm test` pass; settings page matches the contract (Test 10b) | FR-009, FR-014, FR-019, FR-020 |
| 0b. Labelling agent guard (done in #3564) | Separate fix PR (`fix/` branch): the agent stops removing labels for being outside `labels.yml`, honours `DRY_RUN`, and applies only `type:*` labels that exist in `labels.yml` | Test 16 passes; the agent's own tests pass | FR-017, FR-022 |
| 0c. Label names on the audit branch (done in #3362) | On `audit/label-consolidation`: replace `ai-ops`/`type:ai-ops` label names with `aiops`/`type:aiops` and `openspec:` with `spec:` in the spec 008 artefacts, the audit's analysis reports and recommendation files, `docs/LABEL_INVENTORY.md` and `docs/LABELING_FAQ.md`; add `target_name` to the four snapshot files (`canonical-labels.json`, `label-families.json`, `label-inventory.json`, `label-inventory.csv`) and a note in `evidence/README.md`; leave `renamed-label-references.json` unchanged. No locked file, script, workflow or test changes | Test 17 passes; the evidence test still passes | FR-011 |
| 0. Evidence | Paginated label inventory for every repository (after the T075 token guard); `evidence/linear-labels.json` with issue counts and proposed mappings (`contracts/label-mapping-schema.md`) | Mapping validation rules pass (Test 9); the inventory lists private repositories | FR-006, FR-010, FR-012, FR-018 |
| 0. Evidence | Paginated label inventory for every repository (after the T075 token guard); `evidence/linear-labels.json` with issue counts and proposed mappings (`contracts/label-mapping-schema.md`) | Mapping validation rules pass (Test 9); the inventory counts every private repository (names withheld, 2026-10-04) | FR-006, FR-010, FR-012, FR-018 |
| 1. Approve | Raise `[LABEL-UPDATE-REQUEST]` (mapping table, referencing #3554 for its five imports), `[ISSUE-TYPE-UPDATE-REQUEST]` and `[TEMPLATE-UPDATE-REQUEST]` (Question → Decision), a `[LABEL-UPDATE-REQUEST]` for the 16 FR-011 prefix renames and the `spec:NNN` → `spec-id:NNN` move, a `[TEMPLATE-UPDATE-REQUEST]` for the six PR templates (`type:ai-ops` → `type:aiops`, `type:documentation` → `type:docs`, `meta:needs-review` removed) that also covers the routing files `branch-labels.yml` (T074) and `PULL_REQUEST_TEMPLATE/config.yml` (T076), locked since constitution v1.4.0, a migration issue for OpenSpec paths, and a new gate issue replacing #95; each waiting request carries `meta:needs-approval` once the label exists | @ashleyshaw approves all requests | FR-009, FR-011, FR-013, FR-014, FR-016, FR-021 |
| 2. Configuration PR | One PR: `labels.yml` (renames, imports including the five #3554 labels with the FR-012 colour rule, the `area:*` → `aiops:*` AI merges), `label-governance-policy.yml` (new gate issue, `enabled: false`), `labeler.yml`, `branch-labels.yml` (one canonical `type:*` label per branch type, matching its routed template: T074), `PULL_REQUEST_TEMPLATE/config.yml` (mirrors `branch-types.yml`: T076), scripts, workflows (including `orchestrate-phase-progression.yml`), validators (`validate-labeling-configs.cjs` prefix list) and tests referencing `ai-ops:` or `openspec:` labels, `pr_aiops.md`, the `spec:NNN` → `spec-id:NNN` move (`prd-combined-agent` plan, `bulk-label-issues.sh` and its test), the six docs files, and the FR-021 policy in `docs/LABEL_STRATEGY.md`. The `type:question` removal, `issue-types.yml`, `06-decision.md` and `issue-fields.yml` belong to Stage 0a; the never-delete list clean-up shipped in #3362 (T055 stays open only for `gated_by_issue`, which waits for the new gate issue) | Merges only after #3564 (Stage 0b), and its label renames are applied in GitHub (Stage 3) in the same session, so no item loses an `ai-ops:*` or `openspec:*` label. CI green; Test 10 and Test 15 pass | FR-011, FR-012, FR-014, FR-021 |
| 2b. Spec Kit rename PR | Separate PR for the OpenSpec → Spec Kit rename in live files and paths, with links updated | Test 11 passes | FR-013 |
Expand Down
4 changes: 4 additions & 0 deletions .github/specs/008-label-audit-consolidation/spec.md
Original file line number Diff line number Diff line change
Expand Up @@ -324,5 +324,9 @@ The audit itself makes no changes to the production label configuration. The app
- Q: FR-018 requires the drift check to authenticate with an App holding only Issues (read/write) and Metadata (read). May the existing `BOT_PR_APP_*` App be reused unchanged? → A: Yes, by decision of Chris on 2026-10-02 (recorded in `evidence/change-requests.json` as `APP-CREDENTIAL-VARIANCE`). The App is shared by `documentation.yml`, `keep-pr-current.yml` and `branch-validation-metrics-aggregator.yml`, so narrowing it would break those; no new App and no new secret values were created. **This is a documented variance from FR-018 and T071a: the App's installed permission set is broader than "only Issues (read/write) and Metadata (read)", and the limit is applied per token instead.** **Amended 2026-10-02 after a failed live dry run:** `BOT_PR_APP_*` has no Issues permission and cannot serve the drift check; the check now uses the installed `lightspeed-project-automation` App (permissions verified and recorded) with downscoped tokens. `LINEAR_API_KEY` was confirmed by Chris and stays repository-level.
- Q: What does the `label-drift-check` GitHub environment actually protect, given it holds no secrets? → A: Branch gating only. The environment exists (created 2026-10-02, admin bypass off, deployment branch policy `develop` only) and the drift job binds to it, so a `workflow_dispatch` from another branch cannot deploy that job. It provides **no secret isolation**: the environment stores no secrets, so every credential remains reachable at repository level by any workflow that runs in the repository. Secret isolation would require moving the three secrets into the environment, which has not been done. The job is therefore gated by branch, not by secret scope.

### Session 2026-10-04

- Q: This repository is public and the organisation has private repositories, some of which may identify clients. Should the label inventory and the drift report name them? → A: No. By decision of Chris on 2026-10-04, the clean-up and the drift check still cover private repositories, but nothing committed to or published in `lightspeedwp/.github` (evidence files, the drift issue, its artifact, Actions logs) names a private repository or lists its labels. The tracked inventory keeps each private repository as a numbered placeholder with its counts (`label_count`, `pages_read`), the drift issue counts them, and the full detail is kept outside this repository: a local `.private-evidence/` directory for the inventory and the per-repository dry runs, and a private report repository for the drift detail (`PRIVATE_REPORT_REPO`). This supersedes the earlier assumption that the inventory and per-repository dry runs are committed in full. Recorded in FR-006, T041, T065a and the dry-run contract.

*This page brought to you by the 🦄 Magic Automation Unicorns of LightSpeedWP.*
[Automation Docs](https://github.com/lightspeedwp/.github/tree/main/instructions)
Loading
Loading