Repository navigation
Conversation
ModeSevenIndustrialSolutions
requested review from
a team
and
a balanced review from Copilot
October 12, 2026 13:37
ModeSevenIndustrialSolutions
force-pushed
the
feat/linting-toolchain-inputs
branch
from
October 12, 2026 13:50
3c15d01 to
ca43e0e
Compare
ModeSevenIndustrialSolutions
force-pushed
the
feat/linting-toolchain-inputs
branch
from
October 12, 2026 13:59
ca43e0e to
8b00819
Compare
ModeSevenIndustrialSolutions
marked this pull request as draft
October 12, 2026 14:08
Hooks declared 'language: system' run the project's own tools: cargo fmt and clippy need the toolchain rust-toolchain.toml pins, and eslint, prettier and tsc need the project's node_modules. Repositories list them under ci.skip because pre-commit.ci cannot prepare them, and this workflow could not either. standalone-linting-action v0.7.0 and v0.8.0 added that preparation. Move the executor pin from v0.6.0 to v0.8.0 and forward its five new inputs (rust_toolchain_setup, rust_components, node_setup, node_version, node_install_scripts) with the executor's defaults, so 'auto' prepares a project that tracks a Cargo.toml or package.json and leaves every other repository as it was. The plan job validates the values to the executor's own rules, so a typo fails once before any hook rather than once per lint job. The rules live in the input_rules region as verdict functions, which tests/test-locate-rules.sh extracts and drives with table fixtures (38 new cases, accepted and hostile forms alike). tests/test-lint-plan.sh adds a wiring check per input: declared with the executor's default, forwarded verbatim to the executor step, and handed to the plan job's validation. Two self-test jobs run fixture projects through the workflow with every toolchain input at its default, selecting each fixture's ci.skip hooks: - tests/fixtures/rust pins toolchain 1.90.0, minimal profile, and its cargo fmt / clippy hooks run with RUSTUP_AUTO_INSTALL=0, so they pass only when the executor installed that toolchain and the forwarded rustfmt and clippy components. - tests/fixtures/node pins prettier in its lockfile, and its hook runs 'npx --no-install prettier', so it passes only after the executor's frozen install. Egress is unchanged here: lfreleng-actions#65 moved block mode onto the organisation allow-list, which already carries the Rust, Node.js and Yarn hosts these steps reach, including for the ci.skip self-test that now runs under 'block'. docs/linting.md gains a Project toolchains section, including the cost split_hooks multiplies (one install per lint job) and the timeout a large project may need. Copilot review: all findings addressed. The validation moved into the extracted region with permanent fixtures; the fixture jobs demonstrate both preparation paths end to end; and because the executor shares the workflow's defaults, so those jobs alone could not see a dropped forwarding line, the wiring check pins the executor's with: block directly. Closes: lfreleng-actions#66 Co-authored-by: Claude <noreply@anthropic.com> Signed-off-by: Matthew Watkins <mwatkins@linuxfoundation.org>
ModeSevenIndustrialSolutions
marked this pull request as ready for review
October 15, 2026 00:52
ModeSevenIndustrialSolutions
force-pushed
the
feat/linting-toolchain-inputs
branch
from
October 15, 2026 00:52
8b00819 to
7998e40
Compare
There was a problem hiding this comment.
🔵 Needs a closer look
Default toolchain preparation changes existing callers’ execution and network behavior, warranting final human review.
0 open findings
Files not reviewed (1)
- tests/fixtures/node/package-lock.json: Generated file
🧠 Review effort: Balanced
askb
approved these changes
Oct 15, 2026
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.
Summary
Moves the linting workflow's executor from standalone-linting-action
v0.6.0 to v0.8.0. It also forwards the new toolchain inputs,
so
language: systemhooks for Rust and Node.js projects run in CI.Closes #66.
rust_toolchain_setupprepares the toolchainrust-toolchain.tomlpins, forcargo fmt/cargo clippyhooks.node_setupselects Node.js and installs theproject's dependencies frozen to its lockfile (npm, Yarn, pnpm or
Bun), for
eslint,prettierandtschooks.Both default to
auto. They act only on a repository that tracks aCargo.tomlorpackage.jsonunderpath_prefix, so every othercaller is unaffected. Between v0.6.0 and v0.8.0, the executor's
action.yamldiff only adds inputs and outputs; no existing input ordefault changed.
Changes
.github/workflows/linting.yamlrust_toolchain_setup,rust_components,node_setup,node_version,node_install_scripts. They usethe executor's names and defaults;
node_install_scriptsis aboolean, rendered to
'true'/'false'likeper_hook_runs.bad value fails once before any hook rather than in every lint
job. The rules are verdict functions in the extracted
input_rulesregion, so the fixture suite reaches them.c63239ab493b3ddb506524143c34a723880d3e3c, not the annotated tagobject
c408a14…. The release-history comment is extended.docs/linting.md: a new Project toolchains section. Itcovers what each language prepares, how to opt out or require
preparation, and the cost
split_hooksmultiplies (one dependencyinstall per lint job). It also notes the timeout a large project
may need. The inputs table gains five rows.
tests/test-locate-rules.sh: 38 table cases for the threeverdicts. They cover accepted forms, ranges, option-shaped values,
shell metacharacters and control characters.
tests/test-lint-plan.sh: a wiring check per input. It isdeclared with the executor's type and default, forwarded verbatim
in the executor step's
with:, and (for the string inputs) handedto the plan validation. The self-test jobs can't catch a dropped
forwarding line by themselves, since the executor shares the
defaults.
linting-action.yaml): two jobsrun fixture projects through the workflow with every toolchain
input at its default, selecting each fixture's
ci.skiphooks.tests/fixtures/rustpins toolchain 1.90.0 with the minimalprofile. Its
cargo fmtandcargo clippyhooks run withRUSTUP_AUTO_INSTALL=0, so they pass only when the executorinstalled that toolchain plus the forwarded
rustfmtandclippycomponents.tests/fixtures/nodepins prettier in its lockfile. Its hookruns
npx --no-install prettier, so it passes only after theexecutor's frozen install.
through a new
REUSE.toml, and build output is git-ignored..-prefixed self-test jobs also prepare the runner'spreinstalled stable toolchain. That is a rustup check, not a
download.
Egress
Not changed here. #65 moved the workflow onto the organisation
allow-list (
.githubv0.17.1), which already carries every hostpreparation reaches:
static.rust-lang.organd the crates.io hosts,nodejs.org,registry.npmjs.org,registry.yarnpkg.comandrepo.yarnpkg.com(added in lfreleng-actions/.github#268). Thatmatters because the
ci.skipself-test now runs underblockand,with Rust detection being recursive, also prepares the stable
toolchain. The default egress policy stays
audit.Validation
tests/test-locate-rules.sh: 150 passed (112 onmain), underboth bash 5 and bash 3.2.
prepared. The Rust fixture fails on a bare minimal toolchain
(
cargo-fmt is not installed), which is what gives its job teeth.scratch cases: defaults pass, and every invalid form fails with
the intended message.
tests/test-lint-plan.sh: 180 passed (175 before). Deletingnode_setupfrom the executorwith:, changing therust_componentsdefault, or rewiringINPUT_NODE_VERSIONeachfails exactly one case, naming the input.
tests/test-relax-matches.sh(52) passes.prekpasses on every file the branch changes.zizmor --persona auditorreports no findings on both workflows.aislop ci --changes --base upstream/mainis clean.markdown-table-fixerreports no issues.