Skip to content

fix(metadata): require dedicated repository settings credential - #1625

Merged
seonghobae merged 7 commits into
mainfrom
fix/metadata-dedicated-settings-credential
Sep 1, 2026
Merged

fix(metadata): require dedicated repository settings credential#1625
seonghobae merged 7 commits into
mainfrom
fix/metadata-dedicated-settings-credential

Conversation

@seonghobae

@seonghobae seonghobae commented Sep 1, 2026

Copy link
Copy Markdown
Contributor

Outcome

Make the protected-main repository metadata reconciliation fail closed unless it receives the dedicated least-privilege settings credential specified by issue #1579.

  • replace the apply lane's reuse of PR_REVIEW_MERGE_TOKEN with CWL_REPOSITORY_METADATA_TOKEN;
  • add an explicit preflight that refuses to enter mutation work when the dedicated credential is absent;
  • add a static regression contract proving the apply job cannot silently regress to the review/merge credential;
  • include that contract in the workflow's path filter so future credential-boundary edits are validated;
  • update ADR-0020 and the operational doctoring so the accepted authority boundary and live integration state agree with executable source.

Current-main reconciliation

Protected main is now ad65125acfe901bf4c4958b6c705ffce17714358, containing the integrated 22-repository metadata desired state and 39-target label taxonomy from #1622/#1634. Concurrent work had already reconciled this branch once after #1622; when #1634 advanced main, I preserved that writer work and appended another ordinary two-parent merge rather than force-pushing.

Current exact head: bc3edee4866ec3a6e224abcd2cc6bb3d51e18329.

The new tree starts from protected main and reapplies only this lane's four owned files:

  • .github/workflows/repository-metadata-reconcile.yml;
  • tests/test_repository_metadata_workflow.py;
  • docs/adr/0020-repository-public-surface-reconciliation.md;
  • docs/doctoring/repository-public-surface-reconciliation.md.

No force update, destructive rebase, or predecessor-evidence transfer was used.

Safety boundary

This PR does not provision or expose the secret, broaden GITHUB_TOKEN, change repository permissions, or claim live metadata/Pages convergence. Scheduled apply fails before either mutation lane when the dedicated credential is absent; the dedicated identity is unavailable to pull-request code/model processes and cannot fall back to review/merge authority.

After source integration, #1579 remains open until a least-privilege GitHub App/token is actually provisioned in the protected repository-metadata-maintenance environment, a trusted-main apply obtains it without disclosure, and a live canary re-read proves the intended repository settings. Source integration is necessary but not sufficient evidence of live convergence.

Verification boundary

All predecessor-head checks/reviews are historical. Fresh review and hosted evidence must bind to unchanged exact head bc3edee4866ec3a6e224abcd2cc6bb3d51e18329. A queue-saturation exception, if used, must be re-proven on this exact head and may not bypass a substantive failure or review objection.

@seonghobae seonghobae added the bug Something isn't working label Sep 1, 2026 — with ChatGPT Codex Connector
devin-ai-integration[bot]

This comment was marked as resolved.

Preserve #1625's least-privilege credential boundary while taking protected main@696852eb as the tree baseline. The current metadata workflow's newer workflow-Pages path contract is retained; only the dedicated settings credential preflight/token switch and its static regression are applied. No force update or history rewrite.
@coderabbitai

coderabbitai Bot commented Sep 1, 2026

Copy link
Copy Markdown

Warning

Review limit reached

Next included review available in 15 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Learn how review limits work.

Review configuration:

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Team

Run ID: a96bdafe-d73f-4cf7-9cd9-6df0f5d47ba9

📥 Commits

Reviewing files that changed from the base of the PR and between ad65125 and bc3edee.

📒 Files selected for processing (4)
  • .github/workflows/repository-metadata-reconcile.yml
  • docs/adr/0020-repository-public-surface-reconciliation.md
  • docs/doctoring/repository-public-surface-reconciliation.md
  • tests/test_repository_metadata_workflow.py

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

devin-ai-integration[bot]

This comment was marked as resolved.

Copy link
Copy Markdown
Contributor Author

QUEUE_SATURATION_CHICKEN_EGG revalidated on exact head 5e3ee2de94efea752d463d1efe55049017c2b8ea against protected main@696852eb44586150a4d9c22cba794b2089a9543a.

The current base-to-head delta is exactly two files and was rebuilt from protected main rather than replaying the stale branch tree: the live metadata workflow keeps the newer Pages-mode contract and PR-stable concurrency, while this head adds only the dedicated CWL_REPOSITORY_METADATA_TOKEN preflight/token boundary plus its static regression. GitHub reports the head mechanically mergeable; all review threads are resolved; current-head Devin Review and CodeRabbit statuses are both success. The nine current-head hosted workflows materialized, but every one is still queued (Repository Metadata Reconcile, SAST, Secret, Security Scan, Scorecard, SBOM, CodeQL, Python Security, OSV) while the repository-wide queued-run inventory is saturated. There is no substantive failing test, security finding, provenance defect, conflict, or meaningful CHANGES_REQUESTED on this head.

This is a fail-closed least-privilege control-plane repair: if the dedicated secret is not provisioned, the trusted apply lane stops before either mutation path. The current tree preserves the full protected-main validation behavior, and the independent semantic reviews explicitly confirm the preflight covers both mutation paths and the static contract matches the current structure. Ordinary admission is therefore blocked only on hosted capacity, not an unresolved source condition. I am using the owner-authorized queue-saturation exception with exact expected-head identity; post-merge live reconciliation remains separately fail-closed until the dedicated credential exists and a main-branch canary verifies settings convergence.

@seonghobae
seonghobae enabled auto-merge (squash) September 1, 2026 19:39
Reconcile #1625 non-destructively with protected main@0b724fff after the mention-router integration. The current-main tree is authoritative; only #1625's two-file dedicated credential boundary is reapplied. No force update or predecessor evidence transfer.
seonghobae added a commit that referenced this pull request Sep 1, 2026
Reconcile PR #1634 non-destructively after #1622 squash-merged to protected main. The tree is rebuilt from main@611feef038ad52d7ee1214d03ea3527289ebf711 and reapplies only the child lane's label taxonomy, exact assignment contract, and operating-evidence paragraph. Parent metadata manifest and metadata-test files now come exclusively from protected main, eliminating the squash-induced duplicate/conflict delta. Update the operating boundary to record that the 22-repository desired state is already protected while #1625 still owns the dedicated settings-credential migration.
… main

Preserve protected main's 22-repository desired-state manifest while retaining only the dedicated repository-settings credential, ADR, and static workflow contract from this writer. No force push or protected-branch mutation.
Reconcile #1625 non-destructively after #1634 advanced protected main. Use current protected main as the tree baseline, preserve the integrated 22-repository metadata and 39-target label taxonomy, and reapply only the dedicated settings-token workflow, its static contract, ADR-0020 authority boundary, and matching operational doctoring. Preserve concurrent branch reconciliation; no force update or predecessor-evidence transfer.

Copy link
Copy Markdown
Contributor Author

QUEUE_SATURATION_CHICKEN_EGG verified for exact head bc3edee4866ec3a6e224abcd2cc6bb3d51e18329 against protected main@ad65125acfe901bf4c4958b6c705ffce17714358.

Before the merge decision, this lane was reconciled non-destructively with current main after two independent metadata integrations. The exact head is mechanically mergeable and its tree starts from protected main, reapplying only four owned credential/contract/documentation files. CodeRabbit and Devin are both success on this exact head; every review thread is resolved and no substantive current-head review/security objection exists. Exact-head Actions inventory contains nine PR workflows, all queued and none failed. The repository-wide queued run count has risen to 971, confirming continued central fleet saturation rather than a source-specific failed check.

This exception does not treat queued checks as success and does not transfer predecessor workflow evidence. It is limited to the verified least-privilege credential repair, pinned to the exact head SHA. Live credential provisioning and metadata convergence are not claimed by this merge and remain tracked by #1579.

@seonghobae
seonghobae merged commit 30f55d1 into main Sep 1, 2026
17 of 34 checks passed
@seonghobae
seonghobae deleted the fix/metadata-dedicated-settings-credential branch September 1, 2026 20:16
seonghobae added a commit that referenced this pull request Sep 1, 2026
Preserve protected main #1625 byte-for-byte in its four owned paths while retaining the solo-maintainer governance writer. No force-push or history rewrite.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant