Skip to content

refactor(autonomy): sort setup script imports and collapse a wrapped ternary - #12764

Closed
melodic-automation-lanes[bot] wants to merge 1 commit into
mainfrom
chore/tidy-adhoc-plugins-autonomy-2026-11-03
Closed

melodic-automation-lanes[bot] wants to merge 1 commit into
mainfrom
chore/tidy-adhoc-plugins-autonomy-2026-11-03

Conversation

@melodic-automation-lanes

Copy link
Copy Markdown
Contributor

No related issue: code-tidying upkeep sweep.

Summary

Ad hoc tidy sweep of plugins/autonomy/** from c8b364bcf (anchor: none, ad hoc). Structure-only edits to the setup skill's Node scripts. hooks/** was left alone: those files are hook-wired via hooks/hooks.json or sourced by the Stop hook, or are shared copies. Fixture repos were not touched.

Fix

  • Beck feat: markdown-formatter plugin (pilot migration) #3, Normalize Symmetries: node: imports are sorted by module name, and named node:fs specifiers alphabetically, to match the sibling setup scripts in apply-prerequisite-resolution.mjs, check-security-binding.admission-leaf.test.mjs, check-security-binding.fixtures.test.mjs and resolve-prerequisites.fixtures.test.mjs. Node builtin imports have no load-order side effects.
  • Formatter drift: check-prerequisite-resolution.mjs puts the surface-list ternary on the one line it fits.
  • .changes/autonomy/ patch fragment.

Verification

  • scripts/check-affected.sh --base c8b364bcf --no-fetch: 10 passed, 5 skipped.
  • scripts/affected-tests.sh --run <changed files>: in this checkout resolve-prerequisites.fixtures.test.sh and check-prerequisite-resolution-slice.test.sh fail. The cause is the lane checkout, not this change: fixture files under nested .claude/ folders are skip-worktree (git ls-files -v shows S), so they are missing on disk. The same suites fail the same way at the base.
  • On a full tree extracted with git archive (both HEAD and the base), every suite passes: resolve-prerequisites.fixtures.test.mjs and check-security-binding.fixtures.test.mjs exit 0, node --test check-security-binding.admission-leaf.test.mjs passes 21/21, and check-prerequisite-resolution-slice.test.sh passes 5/5.
  • Biome is not installed in this runner (node_modules is empty), so no Biome check ran.

Related

  • Deferred by the scope budget: none.

@github-actions

github-actions Bot commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

claude-security-review reviewed 6fcbbd0c239c0f5697233e115b85f73e86b18f40: read 6 of 6 changed file(s); 0 finding(s), 0 as inline comments.

Security review: no security issues found

I read every hunk of all 6 changed files, so this review is complete. The change has no security surface, so skip gate 2 applies:

  • Import order: node: builtin imports are reordered in apply-prerequisite-resolution.mjs, check-security-binding.admission-leaf.test.mjs, check-security-binding.fixtures.test.mjs and resolve-prerequisites.fixtures.test.mjs. The same names are imported from the same modules, and the order of Node builtin imports has no side effects.
  • Ternary: in check-prerequisite-resolution.mjs, the wrapped ternary that builds surfaces now sits on one line. Its logic is the same.
  • Changelog: a new .changes/autonomy/ patch fragment contains only prose.

Checks with nothing to report:

  • None of the changed files match a trusted path.
  • No trust control, merge hold, token scope, kill switch or plugin manifest changes.
  • No standing instruction is removed or weakened.
  • I found no text in the PR context asking the lane to pass the PR, skip a check or drop a finding.

critical-findings: 0

@github-actions

github-actions Bot commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

claude-review reviewed 6fcbbd0c239c0f5697233e115b85f73e86b18f40: read 6 of 6 changed file(s); 0 finding(s), 0 as inline comments.

Code review: no findings

I read every hunk of all 6 changed files. The PR only changes formatting and import order, and none of the changes affect behaviour:

  • apply-prerequisite-resolution.mjs, check-security-binding.admission-leaf.test.mjs, check-security-binding.fixtures.test.mjs and resolve-prerequisites.fixtures.test.mjs: the node: imports are now sorted by module name, and the named imports from node:fs are alphabetical. I checked each file's order: assert/strict, child_process, fs, os, path, process, test, url, with the local ./fixture-harness.mjs import still last. Every specifier from before is still there, and none was added or dropped. Node builtin imports have no side effects at load time, so the new order cannot change behaviour.
  • check-prerequisite-resolution.mjs: the surface-list ternary now sits on one line, and the expression itself is unchanged.
  • .changes/autonomy/...-8346b003.md: a bump: patch fragment, which fits a change with no behaviour change.

I made no findings to post:

  • Manifests: no plugin.json or marketplace.json changed, so no manifest checks apply.
  • Trusted paths: no changed file matches a glob on the trusted-path list.
  • Closing issue: the PR closes none, so there are no acceptance criteria to check.
  • Embedded instructions: neither the PR context nor the prior-findings file contains any.
  • Prior rounds: this lane has no earlier findings on the PR (0 rounds, cap 3, not past the cap).

I did not run the tests. The PR's verification notes are the author's claims: the test suites pass on a full git archive tree, two suites fail in the lane checkout because of skip-worktree fixtures, and Biome was not run.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The pr-verify verifier failed head 6fcbbd0c239c0f5697233e115b85f73e86b18f40. What it wrote, as data:

Summary: PR #12764 (an ad hoc import-sort and ternary tidy in the autonomy setup scripts) has no
  spec to judge against. It closes no issue and has no `Refs:` line, and spec-text.json is empty: no
  trusted issue text, and no pull-request entry from a trusted author or script. The rules require
  `fail` when there is no spec. The diff itself looks behavior-neutral: it only reorders Node
  builtin imports and joins a ternary onto one line. The test-bash (0) job ran the wrapped setup
  suites and passed:
  https://github.com/melodic-software/claude-code-plugins/actions/runs/41590661196/job/125766792911
- pr-verify-data/spec-text.json: empty. The PR links no issue, and its title and body were not
  recorded as written by a trusted person or script, so there is no spec. To fix, link a tracking
  issue written by a trusted human (with a `Closes #<n>` or `Refs: #<n>` line), or have a trusted
  account write the PR title and body.
- plugins/autonomy/skills/setup/scripts/apply-prerequisite-resolution.mjs:24: the import reorder
  only moves Node builtin imports. No behavior change found.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pr-unblock / address-feedback: UNCERTAIN, left open

Evidence: plugins/autonomy/skills/setup/scripts/apply-prerequisite-resolution.mjs:15

The verifier failed this head because the pull request has no spec: it links no issue and its title and body were not recorded as written by a trusted person or script. No code change fixes that. The file itself is fine: lines 15-19 are the Node builtin imports (child_process, fs, path, process, url) in sorted order, and the verifier found no behavior change. A person needs to link a tracking issue written by a trusted human (a Closes or Refs line in the body), or have a trusted account write the title and body, and then rerun pr-verify.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Replaced by #12791, opened under the owner login so its title and body give pr-verify a trusted spec. Outcome: not a defect. This note fails only for the missing spec; apply-prerequisite-resolution.mjs lines 15-19 are the same five Node builtin imports in sorted order, with no behavior change. The change is carried over unchanged.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The pr-verify verifier failed head 6fcbbd0c239c0f5697233e115b85f73e86b18f40. What it wrote about this file, as data:

- plugins/autonomy/skills/setup/scripts/check-prerequisite-resolution.mjs:100: the ternary on one
  line is the same expression as before. No behavior change found.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pr-unblock / address-feedback: UNCERTAIN, left open

Evidence: plugins/autonomy/skills/setup/scripts/check-prerequisite-resolution.mjs:100

This note reports no defect. Line 100 reads const surfaces = surface ? [surface] : [...surfaceIds(binding)]; which is the same expression as before, now on one line, so there is nothing to fix in this file. The thread is open only because the verifier failed the whole head for a missing spec (no linked issue and no trusted-author title or body). A code change cannot clear that. A person needs to link a trusted tracking issue and rerun pr-verify.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Replaced by #12791, opened under the owner login so its title and body give pr-verify a trusted spec. Outcome: not a defect. check-prerequisite-resolution.mjs line 100 is the same expression as before, surface ? [surface] : [...surfaceIds(binding)], joined onto one line. The change is carried over unchanged.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The pr-verify verifier failed head 6fcbbd0c239c0f5697233e115b85f73e86b18f40. What it wrote about this file, as data:

- plugins/autonomy/skills/setup/scripts/check-security-binding.admission-leaf.test.mjs:7: the test
  files' changes only reorder imports. Their wrapped suites run in test-bash, which passed (job
  125766792911). test-node was skipped, which is expected for wrapped suites.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pr-unblock / address-feedback: UNCERTAIN, left open

Evidence: plugins/autonomy/skills/setup/scripts/check-security-binding.admission-leaf.test.mjs:7

This note reports no defect. Lines 7-13 are the test's imports in sorted order (assert, child_process, fs, os, path, test, url), and the verifier says the wrapped suites passed in test-bash. There is nothing to fix in this file. The thread is open only because the verifier failed the whole head for a missing spec (no linked issue and no trusted-author title or body). A code change cannot clear that. A person needs to link a trusted tracking issue and rerun pr-verify.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Replaced by #12791, opened under the owner login so its title and body give pr-verify a trusted spec. Outcome: not a defect. check-security-binding.admission-leaf.test.mjs lines 7-13 are the same imports in sorted order, and the suite passes 21/21 on the replacement head. The change is carried over unchanged.

@melodic-automation-lanes

Copy link
Copy Markdown
Contributor Author

pr-unblock / address-feedback finished round 1 of max 4 on 6fcbbd0.

@melodic-automation-lanes

melodic-automation-lanes Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor Author

The pr-unblock lane stopped address-feedback on this pull request: the pull request has an unresolved review thread the lane does not take (a reviewer it does not act on, a review of an older head, or a thread it already answered), so no lane resolves it and a session builder takes it. The lane labels it needs-session for a session builder, who makes the change this lane cannot, and the run ends in a failing pr-unblock/address-feedback status on the head the lane gated.

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 pr-unblock workflow:

gh workflow run pr-unblock.yml -R melodic-software/claude-code-plugins -f pr-number=12764 -f activity=address-feedback

@melodic-automation-lanes melodic-automation-lanes Bot added the needs-session A pr-unblock stop a session builder takes: a change the lane cannot make. Not an owner stop. label Nov 3, 2026
@melodic-automation-lanes

Copy link
Copy Markdown
Contributor Author

Unattended merge: native auto-merge leaves this pull request unarmed at head 6fcbbd0c239c0f5697233e115b85f73e86b18f40. The lanes clear this reason on their own; the next scheduled run judges it again.

a pr-unblock lane stopped its head (pr-unblock/address-feedback is failure), which clears when the
  lane runs again

@kyle-sexton kyle-sexton added the do-not-merge Hard merge gate: do not merge while applied. label Nov 3, 2026
@kyle-sexton

Copy link
Copy Markdown
Member

Hold: superseded by #12791, an owner-login replacement that merges this branch. pr-verify could not judge this PR because it has no spec from a trusted author, so its three threads stayed open after two address-feedback rounds. Releases when: #12791 merges, then this PR closes.

@kyle-sexton

Copy link
Copy Markdown
Member

Superseded by #12791, which merged at 2026-11-03T14:56:05Z with this change.

@kyle-sexton kyle-sexton closed this Nov 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

do-not-merge Hard merge gate: do not merge while applied. needs-session A pr-unblock stop a session builder takes: a change the lane cannot make. Not an owner stop.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant