Repository navigation
feat(source-control): read the trusted list from standards for opted-in repos - #18697
Conversation
…in repos A repository whose docs/conventions/source-control.yaml sets `trusted_actors_source: standards` has the babysit merge gate, the pr-verify evidence reader, the skip-unchanged key and the ready hold check read the trusted-actors list and the Dependabot policy from melodic-software/standards at one commit per process, through the contents API. Unset or `repository` reads the .github/standards copies as before; any other value reads neither, so the lane adopts nothing and the hold check leaves the label holding. This repository opts in. Owner decision row 382 (architecture docs/owner-decisions.md), D2-F1 (a) with the opt-in. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
The standards readers named the publishing organization's standards repository in shipped code, which check-org-repo-tokens refuses and the plugin philosophy forbids for a runtime fetch. A new `standards_repository` key in docs/conventions/source-control.yaml names it; `trusted_actors_source: standards` without a valid owner/repo pair fails closed like an unknown value. This repository sets it to melodic-software/standards. Also lowers four stale allow-list counts. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
claude-security-review reviewed Security review: 4ba6f9d (incremental, blocking only)No security issues found. I found no CRITICAL or IMPORTANT findings in the new commit, so this review posts nothing inline. This lane already reviewed an earlier head of this pull request, so this pass reported only CRITICAL and IMPORTANT findings. Scope. I read every hunk of the one file this commit changes since What changed. The commit adds two test cases. Each one stubs a 502 response for the team YAML (
Security effect. These tests lock in the fail-closed behaviour the previous review traced. When the team YAML read fails with anything other than a 404, the code neither adopts a trusted list nor falls back to the repository copy. The commit changes no code, token scope, workflow, Prior findings. The earlier IMPORTANT finding was that a tag named critical-findings: 0 |
|
claude-review reviewed Code review (incremental, blocking only): head
|
|
The pr-verify verifier failed head What it wrote (34 lines)This pull request leaves the merge queue, and ci-status holds it out while it carries |
|
PR lane (desk): this is over 2 h old with pr-verify-failed and 3 open review threads (last push 05:16Z). Still on it? Reply here with an ETA, or post 'Owner: PR lane may take over' and the desk PR lane finishes it. |
…sed in merge.md - Every standards commit read resolves `git/ref/heads/main` (merge policy through `base_tip`, the ready hold check, the merge.md snippet), so a tag named main cannot stand in for the branch. - The merge.md snippet parses `source-control.yaml` with the shared reader and holds on a failed read, a rejected or non-scalar value and an unknown source, as config-resolution.md says. - Tests: the full-ref read, and a failed standards read, a repository source and an unknown source for each reader (trusted list, Dependabot policy, verify evidence, skip key, ready hold check). Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
Still on it (hub session, cross-repo-dup-track-main). The three threads are resolved and the pr-verify findings are fixed at 0c91209; waiting on pr-verify's re-judge, then merging. ETA within the hour. |
Main landed #18732 (part 1 of this spec, split off as #18698), a parallel standards reader with the standards repository fixed in code. Keep this branch's reader, which names the repository in config, and drop main's trusted_actors_source, _standards_file and _list_text with their test class. The test cases main's class had that this branch lacked (a mixed-case value, an empty value, a block list and a quoted key) move into this branch's subtests; the quoted key exposed a fallback to the repository copy, now refused as a non-scalar value. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
The pr-unblock lane stopped
When a retry on this head can change the outcome, the lane runs one on its own, up to its per-head cap, and edits this comment if it stops again; a run that does not stop clears the status. When no retry can (a review thread the lane does not take or settle, or a failing check after the retries are spent), a person resolves the threads or gets the checks green, then dispatches the workflow below: that run finds the cause gone and clears the status. On a pull request the lanes App opened, the dispatchers start that run once per stop; on any other, a person does. A new commit to the branch starts clean. To run it again on this head now, dispatch the gh workflow run pr-unblock.yml -R melodic-software/claude-code-plugins -f pr-number=18697 -f activity=resolve-conflicts |
Resolve the standards_repository overlap with #18695: one schema property and one config-resolution entry naming both the source-control readers and the guardrails and review readers, and one line in source-control.yaml. Both source-control changelog fragments stay: they describe different readers. Co-Authored-By: Claude Opus 5.5 <[email protected]>
The earlier merge of main dropped the case that a failed read of the team YAML reads neither the trusted-actors list nor the Dependabot policy, from the standards repository or the copy. Both cases fail when team_yaml_at returns None on a failed read. Co-Authored-By: Claude Opus 5.5 <[email protected]>
No linked issue: resync from ccp fbaa789 ## Summary Brings every `scripts/lanes/check-sync.sh` SYNCED path to claude-code-plugins main at `fbaa789fc3d4dd4c13b94d46841a11926b928733`, from `ac4f20988f97481085e38d05d563ccc00a2bc888`, the source of #406. The source carries the D2 pull requests (melodic-software/claude-code-plugins#18649, melodic-software/claude-code-plugins#18715, melodic-software/claude-code-plugins#18719, melodic-software/claude-code-plugins#18712, melodic-software/claude-code-plugins#18695, melodic-software/claude-code-plugins#18697), which repoint the lane files to read trusted-actors, vocabulary, runner-policy and the Dependabot policy from a standards-main checkout instead of the synced `.github/standards/` copies. This one is large: 821 files (816 byte copies, 5 sandbox-own files), against #406's 46. Expect both review lanes to report `failure-class=partial`. Upstream also switched its ci-workflows references from SHA pins (#406: 141 on v0.78.0) to `@main` throughout the synced workflows; the copy carries that change as is. ## Fix - SYNCED, byte copy from `fbaa789f` with the ADAPTED, LEFT_OUT and PINNED paths excluded: 91 added, 15 deleted, 707 modified, 3 renamed (`babysit_risk*.py` to `diff_risk*.py`). Deleted upstream: the local actions `scan-upload`, `setup-pinned-node` and `upload-lane-transcript`, `.github/scripts/pr-review-main/split-diff.py` and `plugins/discovery/scripts/check-hook-registration.test.sh`. - The copy drops the stale repin literal `[".github/workflows/maintenance-repin-ci-workflows.yml", "gate"]` from `.github/scripts/pr-merge/merge-holds.mjs` (line 492 on main). - ADAPTED and PINNED: no edit. `.github/standards/` is untouched; phase F removes it. Sandbox-own edits, each mirroring claude-code-plugins at `fbaa789f`: 1. `.github/workflows/pr-require-checks.yml`: the merge-queue Set up Node step uses `melodic-software/ci-workflows/.github/actions/setup-pinned-node@main`, and `/.github/actions/setup-pinned-node/` leaves its sparse checkout, as claude-code-plugins' own `pr-require-checks.yml` does. The local action it used is gone upstream, so without this every merge-queue run fails. 2. `scripts/lanes/check-sync.sh`: four paths join SYNCED under the existing "Modules the synced scripts and tests import from outside those folders" rule, since copied code now reads them: - `.github/scripts/pr-dispatch-feedback/rerun-ci-status.sh`, which `pr-dispatch-feedback.yml` runs. - `.github/scripts/intake-triage/size-split.mjs` and `issue-spec.mjs`, imported by `admit.mjs`, `work-resolve-issue/check-blockers.mjs`, `write-issue.mjs` and `pr-verify/resolve-pr.mjs`. - `.github/lane-registry.json`, read when `lib/lane-registry.mjs` loads (imported by `pr-merge/refire-refused.mjs`). 3. `docs/conventions/source-control.yaml`: adds `trusted_actors_source: standards` and `standards_repository: melodic-software/standards`, as claude-code-plugins' file sets them. 4. Lint config for the copied files, taken from claude-code-plugins' own configs: `.shellcheckrc` with its `shell=bash`, `external-sources=true` and `source-path=SCRIPTDIR` lines (shellcheck follows sourced files, which clears the SC2034 and SC2154 warnings on the copied `check-hook-registration.sh`, `fetch-docs.sh` and `provision-prerequisites.test.sh`), and `_typos.toml` with its `abd` identifier, which `.github/scripts/lib/gate-expression.test.mjs` uses. No check is disabled. ## Verification - `scripts/lanes/check-sync.sh fbaa789fc3d4dd4c13b94d46841a11926b928733 --repo <claude-code-plugins clone>` exits 1 with only the four PINNED lines, as in #406: ```text check-sync: .github/standards/dependabot-policy/policy.json differs from add8219a557d432d9f4dbd1cac98b0e8a2114b10 (100644 0763ab8, want 100644 a3fa7c3) check-sync: .github/standards/runner-policy/package-lock.json differs from 4ac70b2c402920d9c42b9a9f00e86c14d7f785ea (100644 d84d4e7, want 100644 53bb20a) check-sync: .github/standards/runner-policy/policy.json differs from 9329c4cd64765267e43aef0ceef58c40961cd676 (100644 0eec702, want 100644 b8c22e8) check-sync: .github/standards/runner-policy/runner-policy.mjs differs from c277271481af37c9761bcf802a3bc692540bb53a (100755 4d632ca, want 100755 105e36d) ``` - Local paths the workflows name (`.base/...`, `./.github/...`): none newly missing. Three were already missing on main and stay so: `.base/.github/verify-legacy-fails.json` in `pr-dispatch-feedback.yml`, `pr-merge.yml` and `pr-unblock-dispatch.yml`, and `.base/lib/cdn-pins`, read behind an `[ -f ]` guard. - Relative imports and `new URL(..., import.meta.url)` targets in every non-test `.github/**/*.mjs`: all resolve but two, both read guarded or already on main (`scripts/upstream-drift-vendored-report.sh` inside a try/catch, `docs/upstream/` in `resolve-pr.mjs`). - `actionlint` over the 9 changed workflows: no findings. - `node --test --test-concurrency=4` over the 90 changed `.github/scripts/**/*.test.mjs`: 2795 tests, 2709 pass, 84 fail. The failures read workflows, scripts or packages this repository does not carry or install here (`ajv`, `yaml`, `scripts/selection-audit.sh`, `scripts/affected-tests.sh`, `scripts/plan-test-lanes.sh`, `security-outside-actor/flag.mjs`, `pr-review-comment-relay.yml`, `intake-triage.yml` and others), plus two that test this repository's own `pr-require-checks.yml` concurrency groups. Not compared against main, since most of these files are new. `merge-holds.test.mjs` alone: 77 of 78 pass; the one failure imports `security-outside-actor/flag.mjs`. No workflow here runs `node --test`. - Pre-commit and pre-push hooks pass, none skipped. Added lines scanned for machine paths and secrets: none. Not verified: no lane run has exercised this head here. ## Related - Previous resyncs: #406, #403 and #402. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
Closes #18696
Closes #18699
Closes #18700
Closes #18701
Closes #18702
Closes #18703
Summary
Reader move for the source-control plugin's scripts on user machines and in the babysit (pr-merge) lane, ahead of deleting the synced
.github/standards/copies. A repository whosedocs/conventions/source-control.yamlsetstrusted_actors_source: standardshas the trusted-actors list and the Dependabot policy read through the contents API from the repository itsstandards_repositorykey names (owner/repo; absent or malformed fails closed like an unknown source), at one commit per process. A repository without the key reads its copies exactly as today. This repository opts in withstandards_repository: melodic-software/standards; the plugin code names no repository (docs/plugin-philosophy.md "Hardcoded consumer specifics", enforced byscripts/check-org-repo-tokens.sh).Basis: owner decision row 382 in
docs/owner-decisions.md(architecture#220), option (a) "read melodic-software/standards through the contents API at a SHA resolved once per process, only for repositories that opt in by config"; owner, verbatim: "/session-flow:go-with-recommendations".Intake split #18696 into #18698 to #18703. #18732 landed part 1 (#18698) on main with the standards repository fixed in code; this PR's merge of main replaces that reader (
trusted_actors_source,_standards_file,_list_textand its test class) with the config-named one, keeping its extra test cases. Parts 2 to 6 are delivered here and close on merge.Fix
babysit_merge_policy.py:opts_in_to_standards(the key through the shared YAML reader; an unknown or non-scalar value, a quoted key included, raises),team_yaml_at,reads_standards(cached per repo and ref),standards_sha(the standards repository'smainby its full ref,git/ref/heads/main, once per process),standards_file(once per path per process), andsynced_file.trusted_listingand_dependabot_policyread throughsynced_file, so lane adoption, the issue-status setters and the Dependabot review-only check follow the opt-in. A failed read adopts nothing, as an unreadable list does today.babysit_verify_evidence.py_read_trusted_list: the same choice at the branch tip; a failed read isverify:unreadable.babysit_merge_skip.py: the skip key gains a digest of the standards list when the.baseclone's team YAML opts in (unreadotherwise); a failed read skips nothing.check-ready-holds.sh: reads the key from the default branch, and when it isstandards, the list at the commit standardsmainnames; an unreadable source leaves the label holding.trusted_actors_sourceandstandards_repositoryinsource-control.schema.jsonandreference/config-resolution.md;merge.mdandready-for-review.mdsay where the list is read;docs/conventions/source-control.yamlopts in.Hold
The babysit scripts are hold-floor paths, but this repository sets
merge.diff-check.path-holdsfalse, so the path hold applies only to Dependabot PRs (owner decision Q21).CI Statusshould not hold this PR for an approval.Verification
python3 -m unittestper file at the merge head:test_babysit_merge_policy(623),test_babysit_verify_evidence(486),test_babysit_merge_skip(24): all OK. Earlier heads: the spec-trust suites (own_agent,triage_verdict,split_child,drift,incident,recurring) OK.test_babysit_issue_status(1 failure) andtest_babysit_merge_unattended(11 failures) fail on origin/main code on this machine too; this branch adds no failure to either.check-ready-holds.test.sh: 89 pass.repositoryread the copy and never standards; an unknown, mixed-case, empty, list or quoted-key value and a failed standards read adopt nothing or hold; two repositories in one process share one standards commit and one list read; the skip key changes with the standards list.scripts/run-ruff.sh check,scripts/check-org-repo-tokens.sh,shellcheck,shfmt -i 2,scripts/sync-hold-floor.py --check,scripts/check-convention-yaml.shandscripts/check-changelog-fragments.sh --checkpass.Related
diff_risk.py,CARRY_REFUSES) are separate PRs.trusted_actors_source: standardsandstandards_repositorybefore its copies go.🤖 Generated with Claude Code