Skip to content

fix(config): honor the runtime setting - #17261

Merged
zkochan merged 4 commits into
mainfrom
fix-runtime-false-setting
Oct 23, 2026
Merged

zkochan merged 4 commits into
mainfrom
fix-runtime-false-setting

Conversation

@zkochan

@zkochan zkochan commented Oct 22, 2026 •

Copy link
Copy Markdown
Member

Summary

pnpm v12 had Config::skip_runtimes but nothing set it from configuration, so runtime: false in pnpm-workspace.yaml was dropped and only --no-runtime skipped the runtimes from devEngines.runtime / engines.runtime. pnpm v11 honors the setting (skipRuntimes: opts.runtime === false in pnpm11/installing/commands/src/installSingleProject.ts and recursive/context.ts).

This PR makes v12 read runtime from the same sources v11 does: pnpm-workspace.yaml, pnpm_config_runtime / PNPM_CONFIG_RUNTIME, and --config.runtime. The global config.yaml is left out, because runtime is in v11's excludedPnpmKeys. Every installing command follows it: install, add, update, remove, deploy, and now dedupe and prune, which used to force runtimes on. pnpm dedupe also accepts --no-runtime, as in v11. updateConfig hooks see runtime the way v11 shows it, and cannot undo --no-runtime.

Intended difference from v11: with engineStrict: true, once runtimes are skipped (by the setting or --no-runtime), v12 checks the root engines.node against the active Node.js. v11 checks it against the devEngines.runtime / engines.runtime version even when that runtime is not installed (finalizeConfig.ts sets nodeVersion from the manifest regardless of runtime). v12 already did this for --no-runtime (#15135, pinned by install_root_engine::no_runtime_checks_the_active_node_instead_of_the_manifest_runtime), and this PR applies the same rule to the setting.

Part of pnpm/tasks#191

Overlap with #16563 (deps-restorer: unify target Node.js version resolution): both PRs add tests to pnpm/crates/cli/tests/suite/install_runtimes/no_runtime.rs, and that PR changes how the target Node.js version is picked when runtimes are skipped. This PR only changes where the skip comes from and which commands honor it. Whichever lands second should rerun install_runtimes::no_runtime and install_root_engine.

Squash Commit Body

pnpm v12 had Config::skip_runtimes but no source set it, so
`runtime: false` was dropped and only `--no-runtime` skipped the
runtimes from devEngines.runtime and engines.runtime. pnpm v11 passes
`skipRuntimes: opts.runtime === false` (installSingleProject.ts,
recursive/context.ts) and reads the setting from pnpm-workspace.yaml,
`pnpm_config_runtime`, and `--config.runtime`, not from the global
config.yaml, where `runtime` is an excluded key.

WorkspaceSettings now has a `runtime` field, read from
pnpm-workspace.yaml and PNPM_CONFIG_RUNTIME (and through it from
`--config.runtime`), cleared from the global config.yaml, and applied
as `skip_runtimes = !runtime`. `pnpm dedupe` and `pnpm prune` no longer
force runtimes on, as in v11, where both go through installDeps.
`pnpm dedupe` accepts `--no-runtime`, since v11 dedupe takes install's
options. v11 prune does not, so v12 prune stays without it.

updateConfig hooks see `runtime` as v11 shows it: absent until a source
sets it, and `false` under `--no-runtime`. The install pipelines record
`--no-runtime` as a CLI-set `runtime: false` before the hooks run, so a
hook cannot turn runtimes back on (v11 restoreCliSettings).

Intended difference from v11: with engineStrict, a skipped runtime
makes the root engine check use the active Node.js, which is v12's
existing `--no-runtime` behavior (pnpm/pnpm#15135). v11 checks against
the manifest runtime version even when it does not install it. dedupe
and prune now pass the configured runtime policy, like add, update, and
remove, and RuntimePolicy::Always is removed.

Tests: config-crate tests for the yaml, env override, and global
config.yaml exclusion; e2e tests in install_runtimes::no_runtime for
the yaml and `--config.runtime` skip, the CLI override, dedupe and
prune under the setting and `dedupe --no-runtime`, the hook view, a
hook unable to undo `--no-runtime`, and a hook setting `runtime: false`;
install_root_engine covers the engine check of dedupe and prune with a
skipped runtime. Each fix fails its test when reverted.

The install docs now spell the setting `runtime: false`, and the dedupe
docs list `--no-runtime`.

Checklist

  • New features are implemented only in the Rust pnpm v12 CLI. Bug fixes
    are implemented in every affected version. (v12 only. v11 already behaves this way, except for the engine-check difference above.)
  • Added a changeset (pnpm changeset) if this PR changes any published
    package. Keep it short and written for pnpm users — it becomes a release note.
  • Added or updated tests.
  • Updated the documentation if needed.

Written by an agent (Claude Code, claude-opus-5-5).

🤖 Generated with Claude Code

Summary by CodeRabbit

  • New Features
    • Added a runtime setting in pnpm-workspace.yaml and support for configuring it through environment variables or CLI options. Set it to false to skip installing runtimes declared in devEngines.runtime and engines.runtime.
    • Added pnpm dedupe --no-runtime to skip runtime installation during deduplication.
  • Bug Fixes
    • pnpm dedupe and pnpm prune now respect the configured runtime setting.

@coderabbitai

coderabbitai Bot commented Oct 22, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
📥 Commits

Reviewing files that changed from the base of the PR and between 52dce0f and eeda050.

📒 Files selected for processing: 19
  • .changeset/runtime-false-setting.md
  • pnpm/crates/cli/src/cli_args/dedupe.rs
  • pnpm/crates/cli/src/cli_args/pipelines.rs
  • pnpm/crates/cli/src/cli_args/pipelines/configuration.rs
  • pnpm/crates/cli/src/cli_args/pipelines/maintenance.rs
  • pnpm/crates/cli/src/cli_args/prune.rs
  • pnpm/crates/cli/tests/suite/install_root_engine.rs
  • pnpm/crates/cli/tests/suite/install_runtimes/no_runtime.rs
  • pnpm/crates/config/src/env_overlay.rs
  • pnpm/crates/config/src/settings.rs
  • pnpm/crates/config/src/tests/workspace_settings_materialization_env_vars_override.rs
  • pnpm/crates/config/src/workspace_yaml/apply.rs
  • pnpm/crates/config/src/workspace_yaml/reset.rs
  • pnpm/crates/config/src/workspace_yaml/resolved.rs
  • pnpm/crates/config/src/workspace_yaml/settings.rs
  • pnpm/crates/config/src/workspace_yaml/tests/configuration_from_resolved_reports_every.rs
  • pnpm/crates/config/src/workspace_yaml/workspace_scope.rs
  • pnpm/docs/cli/dedupe.md
  • pnpm/docs/cli/install.md
💤 Files with no reviewable changes: 1
  • pnpm/crates/cli/src/cli_args/prune.rs

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 3 remain after this review.

📝 Walkthrough

The change adds runtime configuration through workspace YAML and environment settings. Install, dedupe, and prune now use the configured runtime policy. Dedupe also accepts --no-runtime.

Changes: Runtime setting and CLI handling

Layer / File(s) Summary
Workspace runtime setting
pnpm/crates/config/src/workspace_yaml/*, pnpm/crates/config/src/env_overlay.rs, pnpm/crates/config/src/settings.rs, pnpm/crates/config/src/tests/workspace_settings_materialization_env_vars_override.rs
WorkspaceSettings now includes optional runtime, which maps to Config::skip_runtimes. Environment overlays, reset and resolved settings, and workspace-scope clearing handle the setting. Tests cover materialization and environment overrides.
Runtime handling in CLI commands
pnpm/crates/cli/src/cli_args/dedupe.rs, pnpm/crates/cli/src/cli_args/pipelines*, pnpm/crates/cli/src/cli_args/prune.rs, pnpm/crates/cli/tests/suite/install_root_engine.rs, pnpm/crates/cli/tests/suite/install_runtimes/no_runtime.rs, pnpm/docs/cli/dedupe.md, pnpm/docs/cli/install.md, .changeset/runtime-false-setting.md
Dedupe accepts --no-runtime. Dedupe and prune use configurable runtime policies instead of forcing runtime handling on. Tests cover runtime settings, overrides, and installation outcomes. The docs and changeset describe the setting and option.

Priority: ➖ Normal

Estimated code review effort: 3 (Moderate) | ~25 minutes

Change: Bug fix

Sequence Diagram(s)

sequenceDiagram
  participant WorkspaceYAML
  participant Config
  participant pnpmInstall
  participant RuntimeInstallation
  WorkspaceYAML->>Config: Set runtime: false
  Config->>pnpmInstall: Apply skip_runtimes
  pnpmInstall->>RuntimeInstallation: Check configured runtime policy
  RuntimeInstallation-->>pnpmInstall: Skip runtime installation when disabled
Loading

Suggested labels: product: pacquet

Suggested reviewers: altaywtf, ksxgithub

Merge Risk: ⚪ Minimal · up to eeda0

No actionable runtime-setting issue remains; the change is mergeable after normal checks.

✨ Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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.

@github-actions

github-actions Bot commented Oct 22, 2026 •

Copy link
Copy Markdown
Contributor

Micro-Benchmark Results

Linux

group                                            main                                   pr
-----                                            ----                                   --
lockfile/parse_pnpm_lock                         1.00     14.8±0.94ms    25.2 MB/sec    1.54     22.9±2.67ms    16.4 MB/sec
packument/parse                                  1.00     55.9±7.21µs  1187.1 MB/sec    1.19     66.5±9.36µs   997.4 MB/sec
tarball/download_dependency                      1.00  912.6±156.78µs     4.6 MB/sec    1.34  1227.3±161.50µs     3.5 MB/sec
tarball_batch/cold_store_many_medium_tarballs    1.07   289.3±16.77ms 55.3 KElem/sec    1.00   271.3±14.91ms 59.0 KElem/sec
version_pick/repeated_ranges_file                1.00      5.1±0.40ms  6.1 KElem/sec    1.01      5.2±0.42ms  6.0 KElem/sec
version_pick/repeated_ranges_raw                 1.01      5.3±0.44ms  5.9 KElem/sec    1.00      5.2±0.52ms  6.0 KElem/sec
workspace_resolution/hoist_heavy                 1.01   351.5±15.97ms        ? ?/sec    1.00   349.2±19.59ms        ? ?/sec
workspace_sort/chained_projects                  1.00     18.7±3.68ms        ? ?/sec    1.28     24.0±3.85ms        ? ?/sec

@github-actions

github-actions Bot commented Oct 22, 2026 •

Copy link
Copy Markdown
Contributor

Same-run regression check

HEAD and main are measured on the same runner. The tolerance is 5% of the main median or 2 ms, whichever is larger. A regression requires both the median slowdown and the gap between the fastest retained HEAD sample and slowest retained main sample to exceed this tolerance, after trimming up to 10% from each tail. Suspected regressions are rerun once with target order reversed and only fail if reproduced. This conservative noise guard is not a statistical confidence interval.

Inconclusive rows do not fail the check. They remain visible for performance review. Bencher retains absolute minimum timings for historical tracking; historical alerts do not gate this PR. Sequential measurements can still be affected by runner drift.

Scenario Engine main median HEAD median Change Tolerance Result
isolated-fresh-restore-cold-cache-cold-store pacquet 2682.46 ms 2642.08 ms -1.5% 134.12 ms Within tolerance
isolated-fresh-restore-cold-cache-cold-store pnpr 1474.97 ms 1588.47 ms 7.7% 73.75 ms Inconclusive (overlapping samples)
isolated-fresh-restore-hot-cache-hot-store pacquet 320.38 ms 337.70 ms 5.4% 16.02 ms Inconclusive (overlapping samples)
isolated-fresh-restore-hot-cache-hot-store pnpr 416.60 ms 316.50 ms -24.0% 20.83 ms Within tolerance
isolated-repeat-install-hot-cache-hot-store pacquet 10.91 ms 11.23 ms 2.9% 2.00 ms Within tolerance
isolated-repeat-install-hot-cache-hot-store pnpr 10.35 ms 10.94 ms 5.7% 2.00 ms Within tolerance
isolated-repeat-install-cold-cache-hot-store pacquet 18.84 ms 15.07 ms -20.0% 2.00 ms Within tolerance
isolated-repeat-install-cold-cache-hot-store pnpr 15.76 ms 16.39 ms 4.0% 2.00 ms Within tolerance
isolated-fresh-install-cold-cache-cold-store pacquet 2765.36 ms 3008.45 ms 8.8% 138.27 ms Inconclusive (overlapping samples)
isolated-fresh-install-cold-cache-cold-store pnpr 1584.84 ms 1608.54 ms 1.5% 79.24 ms Within tolerance
isolated-fresh-install-hot-cache-hot-store pacquet 595.30 ms 742.30 ms 24.7% 29.76 ms Inconclusive (overlapping samples)
isolated-fresh-install-hot-cache-hot-store pnpr 375.91 ms 349.87 ms -6.9% 18.80 ms Within tolerance
isolated-fresh-install-cold-cache-hot-store pacquet 1761.59 ms 1783.93 ms 1.3% 88.08 ms Within tolerance
isolated-fresh-install-cold-cache-hot-store pnpr 476.45 ms 417.58 ms -12.4% 23.82 ms Within tolerance
isolated-fresh-resolve-hot-cache-offline pacquet 451.53 ms 421.77 ms -6.6% 22.58 ms Within tolerance
isolated-fresh-resolve-hot-cache-offline pnpr 139.45 ms 157.12 ms 12.7% 6.97 ms Inconclusive (overlapping samples)
isolated-peer-heavy-resolve-hot-cache-offline pacquet 300.56 ms 295.63 ms -1.6% 15.03 ms Within tolerance
isolated-linked-workspace-resolve-hot-cache-offline pacquet 118.36 ms 118.41 ms 0.0% 5.92 ms Within tolerance
isolated-injected-workspace-repeat-install-hot-cache-hot-store pacquet 131.70 ms 99.87 ms -24.2% 6.59 ms Within tolerance
isolated-fresh-restore-cold-cache-cold-store-cold-pnpr pacquet 5088.37 ms 4922.02 ms -3.3% 254.42 ms Within tolerance
isolated-fresh-restore-cold-cache-cold-store-cold-pnpr pnpr 5157.43 ms 4558.29 ms -11.6% 257.87 ms Within tolerance
gvs-fresh-restore-hot-cache-hot-store pacquet 163.49 ms 166.11 ms 1.6% 8.17 ms Within tolerance
gvs-fresh-restore-hot-cache-hot-store pnpr 178.75 ms 170.31 ms -4.7% 8.94 ms Within tolerance
store-only-unlocked-direct-deps-cold-cache-hot-store pacquet 1219.81 ms 1334.01 ms 9.4% 60.99 ms Inconclusive (overlapping samples)
cargo-repeat-install-hot-cache-hot-store pacquet 36.92 ms 37.22 ms 0.8% 2.00 ms Within tolerance

Integrated-Benchmark Report (Linux)

Commit: eeda050187b4

Regular scenarios report direct and pnpr installs. The peer-heavy resolver scenario compares current Rust, main Rust, and TypeScript pnpm; the linked, injected, and Cargo workspace scenarios compare current Rust against main Rust. Bencher consumes pacquet@HEAD and pnpr@HEAD.

The tables below show mean ± σ. Bencher tracks absolute minimum latency; PR regression checks compare HEAD and main samples from the same runner. Historical timing alerts do not gate PRs.

Scenario: Isolated linker: fresh restore, cold cache + cold store

Command Mean [s] Min [s] Max [s] Relative
pacquet@HEAD 2.619 ± 0.098 2.440 2.758 1.76 ± 0.14
pacquet@main 2.693 ± 0.145 2.488 3.048 1.81 ± 0.16
pnpr@HEAD 1.592 ± 0.108 1.382 1.728 1.07 ± 0.11
pnpr@main 1.489 ± 0.108 1.370 1.697 1.00
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 2.6194408288999993,
      "stddev": 0.09788626916765912,
      "median": 2.6420804465999996,
      "user": 2.21308008,
      "system": 1.646391,
      "min": 2.4397354261,
      "max": 2.7578664781
    },
    {
      "command": "pacquet@main",
      "mean": 2.6928011533,
      "stddev": 0.1453928231364261,
      "median": 2.6824644176,
      "user": 2.44580748,
      "system": 1.7468042999999998,
      "min": 2.4881258671,
      "max": 3.0477006181
    },
    {
      "command": "pnpr@HEAD",
      "mean": 1.5921662488000003,
      "stddev": 0.10831504344189721,
      "median": 1.5884748941000002,
      "user": 2.0649907799999996,
      "system": 1.7231481,
      "min": 1.3815912771,
      "max": 1.7279035911000002
    },
    {
      "command": "pnpr@main",
      "mean": 1.4889082866999999,
      "stddev": 0.10801116744908162,
      "median": 1.4749739691000001,
      "user": 2.1821278800000004,
      "system": 1.6254607999999997,
      "min": 1.3703229981,
      "max": 1.6971424711
    }
  ]
}

Scenario: Isolated linker: fresh restore, hot cache + hot store

Command Mean [ms] Min [ms] Max [ms] Relative
pacquet@HEAD 337.6 ± 37.1 284.7 389.0 1.08 ± 0.13
pacquet@main 319.5 ± 27.7 281.0 381.0 1.02 ± 0.10
pnpr@HEAD 313.9 ± 17.3 290.4 336.3 1.00
pnpr@main 398.0 ± 70.1 290.7 475.7 1.27 ± 0.23
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 0.33756452278000004,
      "stddev": 0.03708596251998413,
      "median": 0.33770444818,
      "user": 0.39207998,
      "system": 0.74808648,
      "min": 0.28472974168,
      "max": 0.38904482368000004
    },
    {
      "command": "pacquet@main",
      "mean": 0.31954231368,
      "stddev": 0.027738789174447446,
      "median": 0.32038332067999997,
      "user": 0.37163717999999996,
      "system": 0.7221140800000001,
      "min": 0.28102472468,
      "max": 0.38100875268
    },
    {
      "command": "pnpr@HEAD",
      "mean": 0.31387734968000003,
      "stddev": 0.01727014493009107,
      "median": 0.31650331568,
      "user": 0.34908427999999997,
      "system": 0.6750622799999999,
      "min": 0.29036794668,
      "max": 0.33627954868
    },
    {
      "command": "pnpr@main",
      "mean": 0.39798695668,
      "stddev": 0.07011097359296092,
      "median": 0.41659815418,
      "user": 0.4341948799999999,
      "system": 0.82088178,
      "min": 0.29071077168000004,
      "max": 0.47571451068000004
    }
  ]
}

Scenario: Isolated linker: repeat install, hot cache + hot store

Command Mean [ms] Min [ms] Max [ms] Relative
pacquet@HEAD 13.3 ± 4.9 8.5 33.1 1.26 ± 0.48
pacquet@main 11.1 ± 1.3 8.5 16.0 1.05 ± 0.17
pnpr@HEAD 11.1 ± 1.5 8.5 18.0 1.06 ± 0.18
pnpr@main 10.5 ± 1.1 8.3 14.6 1.00
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 0.013284815480000003,
      "stddev": 0.004882956583010056,
      "median": 0.01123331428,
      "user": 0.007704046666666665,
      "system": 0.006768678400000002,
      "min": 0.00846279978,
      "max": 0.033066121780000006
    },
    {
      "command": "pacquet@main",
      "mean": 0.011067240346820275,
      "stddev": 0.0013235616298402002,
      "median": 0.010913880780000001,
      "user": 0.006539452718894009,
      "system": 0.005638879078341011,
      "min": 0.00853347278,
      "max": 0.01596469878
    },
    {
      "command": "pnpr@HEAD",
      "mean": 0.011103373755490198,
      "stddev": 0.001496504098127486,
      "median": 0.01093848728,
      "user": 0.00675972980392157,
      "system": 0.0053908586274509784,
      "min": 0.00846765078,
      "max": 0.018014886780000003
    },
    {
      "command": "pnpr@main",
      "mean": 0.010506292285976097,
      "stddev": 0.0010678361841671646,
      "median": 0.01035144778,
      "user": 0.006220281752988047,
      "system": 0.005282711792828683,
      "min": 0.00826178478,
      "max": 0.014618857780000001
    }
  ]
}

Scenario: Isolated linker: repeat install, cold cache + hot store

Command Mean [ms] Min [ms] Max [ms] Relative
pacquet@HEAD 15.2 ± 2.2 10.6 21.9 1.00
pacquet@main 19.0 ± 4.8 11.6 36.5 1.24 ± 0.36
pnpr@HEAD 17.6 ± 4.4 12.2 32.4 1.16 ± 0.33
pnpr@main 16.3 ± 3.1 11.7 32.2 1.07 ± 0.26
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 0.01524938700364781,
      "stddev": 0.0021959654028752816,
      "median": 0.015072020620000003,
      "user": 0.00809075031446541,
      "system": 0.008338662138364778,
      "min": 0.010643957620000002,
      "max": 0.02191980662
    },
    {
      "command": "pacquet@main",
      "mean": 0.018967750799190743,
      "stddev": 0.004798109704566569,
      "median": 0.01883645362,
      "user": 0.009596422543352596,
      "system": 0.010423514913294797,
      "min": 0.01163932062,
      "max": 0.03646753262
    },
    {
      "command": "pnpr@HEAD",
      "mean": 0.017628634965794393,
      "stddev": 0.0044228532054203795,
      "median": 0.01638753562,
      "user": 0.010288597196261677,
      "system": 0.008643382429906539,
      "min": 0.012172643620000001,
      "max": 0.03236568262
    },
    {
      "command": "pnpr@main",
      "mean": 0.01629009595522727,
      "stddev": 0.0031370632962942255,
      "median": 0.01575587162,
      "user": 0.009256944318181817,
      "system": 0.008375761136363636,
      "min": 0.01171419062,
      "max": 0.03216589662
    }
  ]
}

Scenario: Isolated linker: fresh install, cold cache + cold store

Command Mean [s] Min [s] Max [s] Relative
pacquet@HEAD 3.013 ± 0.149 2.785 3.236 1.86 ± 0.13
pacquet@main 2.772 ± 0.100 2.642 2.944 1.72 ± 0.10
pnpr@HEAD 1.656 ± 0.137 1.528 1.952 1.02 ± 0.10
pnpr@main 1.616 ± 0.077 1.541 1.757 1.00
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 3.0127547569200006,
      "stddev": 0.14908464983518954,
      "median": 3.00845341612,
      "user": 3.6740495399999995,
      "system": 2.5141883600000003,
      "min": 2.7852155336199997,
      "max": 3.2363649826199996
    },
    {
      "command": "pacquet@main",
      "mean": 2.77184414772,
      "stddev": 0.09962869465968356,
      "median": 2.7653588011199997,
      "user": 3.1350846399999996,
      "system": 2.0206248600000003,
      "min": 2.6416621186199998,
      "max": 2.94441404762
    },
    {
      "command": "pnpr@HEAD",
      "mean": 1.6557577359200004,
      "stddev": 0.13685111736657782,
      "median": 1.6085362541200001,
      "user": 2.16976494,
      "system": 1.8818951600000002,
      "min": 1.5281938666200001,
      "max": 1.9524463086200001
    },
    {
      "command": "pnpr@main",
      "mean": 1.6156417029200003,
      "stddev": 0.07731685751866595,
      "median": 1.5848383686200003,
      "user": 2.0990292399999997,
      "system": 1.6914432599999998,
      "min": 1.54093470562,
      "max": 1.75738486462
    }
  ]
}

Scenario: Isolated linker: fresh install, hot cache + hot store

Command Mean [ms] Min [ms] Max [ms] Relative
pacquet@HEAD 734.7 ± 28.7 690.9 786.8 2.10 ± 0.10
pacquet@main 614.9 ± 52.7 548.3 713.9 1.76 ± 0.16
pnpr@HEAD 349.9 ± 10.9 335.7 364.8 1.00
pnpr@main 387.3 ± 46.6 357.2 515.0 1.11 ± 0.14
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 0.734735181,
      "stddev": 0.028713037634870587,
      "median": 0.7423018706000001,
      "user": 1.09344012,
      "system": 1.0989139800000003,
      "min": 0.6909322591000001,
      "max": 0.7868055761000001
    },
    {
      "command": "pacquet@main",
      "mean": 0.6148964420000002,
      "stddev": 0.052728683669068056,
      "median": 0.5952962231000001,
      "user": 0.9041542199999999,
      "system": 0.9548993799999999,
      "min": 0.5482904971000001,
      "max": 0.7138778431
    },
    {
      "command": "pnpr@HEAD",
      "mean": 0.34987331279999995,
      "stddev": 0.01091102663164613,
      "median": 0.3498749216,
      "user": 0.30843982,
      "system": 0.67314348,
      "min": 0.3357115041,
      "max": 0.3647849811
    },
    {
      "command": "pnpr@main",
      "mean": 0.38726380219999995,
      "stddev": 0.046615117143232486,
      "median": 0.3759063486,
      "user": 0.3610147199999999,
      "system": 0.69820308,
      "min": 0.3572108561,
      "max": 0.5150080911
    }
  ]
}

Scenario: Isolated linker: fresh install, cold cache + hot store

Command Mean [s] Min [s] Max [s] Relative
pacquet@HEAD 1.793 ± 0.077 1.702 1.949 4.09 ± 0.68
pacquet@main 1.775 ± 0.036 1.740 1.846 4.05 ± 0.66
pnpr@HEAD 0.438 ± 0.071 0.382 0.614 1.00
pnpr@main 0.475 ± 0.033 0.433 0.526 1.08 ± 0.19
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 1.79334719304,
      "stddev": 0.07749768840332402,
      "median": 1.78393368984,
      "user": 1.22723746,
      "system": 1.10443254,
      "min": 1.7023720723400002,
      "max": 1.9485914433400002
    },
    {
      "command": "pacquet@main",
      "mean": 1.7746236601400003,
      "stddev": 0.035898623412508344,
      "median": 1.76158518584,
      "user": 1.20069416,
      "system": 1.06969804,
      "min": 1.73995234734,
      "max": 1.84580213334
    },
    {
      "command": "pnpr@HEAD",
      "mean": 0.43843072304,
      "stddev": 0.07073188128378541,
      "median": 0.41757965784000006,
      "user": 0.41633036,
      "system": 0.78060614,
      "min": 0.38249138834,
      "max": 0.61432946334
    },
    {
      "command": "pnpr@main",
      "mean": 0.47484720174,
      "stddev": 0.03254730730323559,
      "median": 0.47644885434000006,
      "user": 0.44503536000000005,
      "system": 0.8408292399999999,
      "min": 0.43262469334000003,
      "max": 0.5256271893400001
    }
  ]
}

Scenario: Isolated linker: fresh resolve, hot cache, offline

Command Mean [ms] Min [ms] Max [ms] Relative
pacquet@HEAD 433.3 ± 75.5 355.5 613.2 3.05 ± 0.64
pacquet@main 457.1 ± 52.4 376.4 561.9 3.22 ± 0.53
pnpr@HEAD 154.9 ± 13.6 137.5 176.9 1.09 ± 0.16
pnpr@main 142.0 ± 17.0 119.1 183.1 1.00
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 0.43334277698,
      "stddev": 0.07552712956187226,
      "median": 0.42176525318,
      "user": 0.45358526,
      "system": 0.17779304,
      "min": 0.35551177868,
      "max": 0.6132456116800001
    },
    {
      "command": "pacquet@main",
      "mean": 0.45706018198000004,
      "stddev": 0.052416506682070055,
      "median": 0.45152959618,
      "user": 0.48014636,
      "system": 0.20241994000000002,
      "min": 0.37635988568,
      "max": 0.56189163068
    },
    {
      "command": "pnpr@HEAD",
      "mean": 0.1549342017425,
      "stddev": 0.013611803754784619,
      "median": 0.15711714568000001,
      "user": 0.07364474749999998,
      "system": 0.0382235275,
      "min": 0.13753940868,
      "max": 0.17691302368
    },
    {
      "command": "pnpr@main",
      "mean": 0.14199674034666668,
      "stddev": 0.016975562391276275,
      "median": 0.13945021568,
      "user": 0.07065726,
      "system": 0.028496906666666665,
      "min": 0.11912031468,
      "max": 0.18307365868
    }
  ]
}

Scenario: Isolated linker: peer-heavy resolve, hot cache, offline

Command Mean [ms] Min [ms] Max [ms] Relative
pacquet@HEAD 298.8 ± 20.0 274.5 330.5 1.00
pacquet@main 307.7 ± 27.5 279.6 357.3 1.03 ± 0.11
pnpm@HEAD 5109.5 ± 368.7 4626.9 5704.4 17.10 ± 1.68
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 0.2987700151422223,
      "stddev": 0.01998862113895848,
      "median": 0.29562706792000004,
      "user": 0.32602935555555557,
      "system": 0.06316733333333333,
      "min": 0.27453953792,
      "max": 0.33050444792000006
    },
    {
      "command": "pacquet@main",
      "mean": 0.3077316323644445,
      "stddev": 0.02750252405020122,
      "median": 0.30055998692,
      "user": 0.33022413333333334,
      "system": 0.07451077777777777,
      "min": 0.27960821592,
      "max": 0.35725717392000006
    },
    {
      "command": "pnpm@HEAD",
      "mean": 5.109481120586667,
      "stddev": 0.3687451996893138,
      "median": 5.0630153579199995,
      "user": 8.109369577777777,
      "system": 0.4837901111111111,
      "min": 4.62688003492,
      "max": 5.704355823919999
    }
  ]
}

Scenario: Isolated linker: linked-workspace resolve, hot cache, offline

Command Mean [ms] Min [ms] Max [ms] Relative
pacquet@HEAD 119.9 ± 7.1 105.7 143.0 1.01 ± 0.09
pacquet@main 119.3 ± 7.4 103.8 137.4 1.00
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 0.11986186007833333,
      "stddev": 0.007140046378816795,
      "median": 0.11841187562000001,
      "user": 0.11523857833333333,
      "system": 0.05617456499999999,
      "min": 0.10574799212000001,
      "max": 0.14295642512
    },
    {
      "command": "pacquet@main",
      "mean": 0.11925471629391302,
      "stddev": 0.007430440616444068,
      "median": 0.11836169612,
      "user": 0.1136731852173913,
      "system": 0.05429870086956521,
      "min": 0.10383976612000001,
      "max": 0.13738767112
    }
  ]
}

Scenario: Isolated linker: injected workspace repeat install, hot cache + hot store

Command Mean [ms] Min [ms] Max [ms] Relative
pacquet@HEAD 101.7 ± 10.5 88.3 142.1 1.00
pacquet@main 130.7 ± 13.4 108.4 152.2 1.29 ± 0.19
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 0.10170758484962959,
      "stddev": 0.010545627710304555,
      "median": 0.09987097922000002,
      "user": 0.03524978814814814,
      "system": 0.0744115688888889,
      "min": 0.08831002522,
      "max": 0.14207934322000002
    },
    {
      "command": "pacquet@main",
      "mean": 0.13070767047,
      "stddev": 0.013412789791181452,
      "median": 0.13170012022,
      "user": 0.051064515,
      "system": 0.08942455500000002,
      "min": 0.10841502122,
      "max": 0.15223152822000002
    }
  ]
}

Scenario: Isolated linker: fresh restore, cold cache + cold store + cold pnpr

Command Mean [s] Min [s] Max [s] Relative
pacquet@HEAD 4.978 ± 0.237 4.629 5.320 1.10 ± 0.11
pacquet@main 5.228 ± 0.315 4.918 5.755 1.15 ± 0.13
pnpr@HEAD 4.541 ± 0.422 3.805 5.114 1.00
pnpr@main 5.365 ± 0.633 4.751 6.870 1.18 ± 0.18
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 4.978375636860001,
      "stddev": 0.2366368553475107,
      "median": 4.92202455396,
      "user": 2.9530366799999994,
      "system": 2.15988028,
      "min": 4.628944934960001,
      "max": 5.32025064996
    },
    {
      "command": "pacquet@main",
      "mean": 5.2281211259600004,
      "stddev": 0.3147196855753119,
      "median": 5.08836597646,
      "user": 3.37534068,
      "system": 2.3442752799999997,
      "min": 4.91792146696,
      "max": 5.75533935196
    },
    {
      "command": "pnpr@HEAD",
      "mean": 4.54128390196,
      "stddev": 0.421766871654131,
      "median": 4.55828828196,
      "user": 3.1628615799999995,
      "system": 2.40740018,
      "min": 3.80521975396,
      "max": 5.11386608996
    },
    {
      "command": "pnpr@main",
      "mean": 5.36523323616,
      "stddev": 0.6333222891058473,
      "median": 5.15743227196,
      "user": 3.5081991799999996,
      "system": 2.75473778,
      "min": 4.75136064796,
      "max": 6.87003750996
    }
  ]
}

Scenario: GVS linker: fresh restore, hot cache + hot store

Same install as the isolated fresh-restore hot/hot scenario, into the shared virtual store, the layout pnpm 12 installs into by default. Scenarios run on separate machines, so compare main and branch within each table.

Command Mean [ms] Min [ms] Max [ms] Relative
pacquet@HEAD 177.5 ± 26.2 154.2 229.4 1.07 ± 0.18
pacquet@main 166.4 ± 12.9 148.7 191.7 1.00
pnpr@HEAD 170.6 ± 6.9 161.8 181.8 1.03 ± 0.09
pnpr@main 180.0 ± 6.5 168.9 189.2 1.08 ± 0.09
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 0.1775029082575,
      "stddev": 0.02616447220741543,
      "median": 0.16611250432000002,
      "user": 0.2177151725,
      "system": 0.17676912249999996,
      "min": 0.15415709382,
      "max": 0.22940404682
    },
    {
      "command": "pacquet@main",
      "mean": 0.1663902456866667,
      "stddev": 0.012935310619234183,
      "median": 0.16348798982,
      "user": 0.20725079333333335,
      "system": 0.16872979333333332,
      "min": 0.14873519982,
      "max": 0.19174843082
    },
    {
      "command": "pnpr@HEAD",
      "mean": 0.17062756324857142,
      "stddev": 0.006896758154522032,
      "median": 0.17030900532,
      "user": 0.1945552885714286,
      "system": 0.17671198857142859,
      "min": 0.16181134882,
      "max": 0.18183292382000002
    },
    {
      "command": "pnpr@main",
      "mean": 0.17995580882,
      "stddev": 0.006521774291414739,
      "median": 0.17875109132,
      "user": 0.21671314571428568,
      "system": 0.17125434571428572,
      "min": 0.16887755482,
      "max": 0.18920233882
    }
  ]
}

Scenario: Store only: unlocked direct deps, cold cache + hot store

Store-only install (enableModulesDir: false, per-file store index, trusted lockfile) against a lockfile missing the direct dependencies that have peers, with the metadata cache wiped per iteration: the install resolves those from the registry, reuses their subtrees from the lockfile and checks the store, linking nothing. Direct installs only.

Command Mean [s] Min [s] Max [s] Relative
pacquet@HEAD 1.317 ± 0.078 1.191 1.429 1.08 ± 0.07
pacquet@main 1.224 ± 0.020 1.190 1.266 1.00
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 1.3165769989999998,
      "stddev": 0.07782120683015703,
      "median": 1.3340087636,
      "user": 0.8477788399999999,
      "system": 0.34047426,
      "min": 1.1911118151,
      "max": 1.4286653451
    },
    {
      "command": "pacquet@main",
      "mean": 1.2238044759,
      "stddev": 0.02027967013765481,
      "median": 1.2198145716000002,
      "user": 0.67130654,
      "system": 0.27679635999999996,
      "min": 1.1899625381,
      "max": 1.2659779451
    }
  ]
}

Scenario: Cargo: repeat install, hot cache + hot store

Frozen repeat install of a Cargo workspace (cargo.enabled: true) whose crates are already materialized in <storeDir>/v11/crates/ and linked into .pnpm/crates/crates-io. Direct installs only.

Command Mean [ms] Min [ms] Max [ms] Relative
pacquet@HEAD 39.1 ± 5.7 33.4 61.0 1.03 ± 0.18
pacquet@main 38.0 ± 3.5 33.5 49.1 1.00
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 0.039108070826470574,
      "stddev": 0.005713166605012544,
      "median": 0.037217133900000005,
      "user": 0.027646413529411766,
      "system": 0.02112833,
      "min": 0.033440087900000005,
      "max": 0.061048355900000004
    },
    {
      "command": "pacquet@main",
      "mean": 0.037997048737500004,
      "stddev": 0.0034648243385062365,
      "median": 0.03691979890000001,
      "user": 0.028226639999999997,
      "system": 0.018900442500000003,
      "min": 0.0334753339,
      "max": 0.049122880900000006
    }
  ]
}

@codecov-commenter

codecov-commenter commented Oct 22, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 92.54%. Comparing base (30f6d58) to head (eeda050).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #17261      +/-   ##
==========================================
- Coverage   92.54%   92.54%   -0.01%     
==========================================
  Files        1864     1864              
  Lines      241552   241568      +16     
==========================================
+ Hits       223550   223554       +4     
- Misses      18002    18014      +12     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

zkochan and others added 4 commits October 23, 2026 01:50
pnpm v11 skips installing the runtimes from devEngines.runtime and
engines.runtime when the `runtime` setting is false
(pnpm11/installing/commands/src/installSingleProject.ts and
recursive/context.ts pass `skipRuntimes: opts.runtime === false`). It
reads the setting from pnpm-workspace.yaml, `pnpm_config_runtime`, and
`--config.runtime`, and not from the global config.yaml, where
`runtime` is an excluded key. v12 had `Config::skip_runtimes` but no
source ever set it, so `runtime: false` was dropped and only
`--no-runtime` skipped runtimes.

`WorkspaceSettings` now has a `runtime` field. It is read from
pnpm-workspace.yaml and the `PNPM_CONFIG_RUNTIME` env var (and through
it from `--config.runtime`), cleared from the global config.yaml, and
applied as `skip_runtimes = !runtime`. It is also reported to and reset
by updateConfig hooks. `--no-runtime` still forces the skip on top.
`pnpm dedupe` and `pnpm prune` no longer force `skip_runtimes` to
false, so they follow the setting as they do in v11, where both go
through installDeps.

Tested by config-crate tests (yaml sets it, env overrides yaml, global
config.yaml ignores it) and by e2e tests in install_runtimes::no_runtime
(`runtime: false` and `--config.runtime=false` skip the runtime fetch,
`--config.runtime=true` overrides the yaml). The yaml and CLI e2e cases
fail with the apply line removed.

Part of pnpm/tasks#191.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
pnpm v11 hands updateConfig hooks the merged config, so `runtime` is
absent until a source sets it, and `--no-runtime` arrives as
`runtime: false` (install.ts lists `runtime` among its CLI options). The
first commit reported the resolved value instead, so every hook saw
`runtime: true` by default and never saw `--no-runtime`.

`from_resolved` now reports `runtime` only as a source set it, like the
other presence-read settings. Before the hooks run, the install
pipelines record `--no-runtime` as the CLI-set `runtime: false`, which
also keeps a hook from turning it back on, matching v11's
restoreCliSettings.

Tested by install_runtimes::no_runtime::update_config_sees_runtime_only_when_set
(absent by default, false from the yaml and from --no-runtime, true from
--config.runtime=true). Each half of the fix, reverted on its own, fails
that test.

Part of pnpm/tasks#191.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
`pnpm dedupe` and `pnpm prune` follow the `runtime` setting since the
previous commits, but still passed `RuntimePolicy::Always`, so the
engineStrict root check compared `engines.node` with the
`devEngines.runtime` version they no longer install. Both now pass the
configured policy, as `add`, `update`, and `remove` do, and
`RuntimePolicy::Always` is gone. A skipped runtime therefore means the
check uses the active Node.js, as `install --no-runtime` already does.
v11 keeps checking against the manifest runtime there. That difference
is v12's existing `--no-runtime` behavior, now also applied to the
setting.

pnpm v11 dedupe takes install's options, `runtime` included
(dedupe.ts, install.ts), so `pnpm dedupe --no-runtime` now works too.
v11 prune does not accept the flag, so v12 prune stays without it.

Tests: dedupe and prune skip the runtime under `runtime: false` and
`dedupe --no-runtime` (fails with the removed `skip_runtimes = false`
lines restored); with engineStrict they check the active Node.js (fails
when the policy ignores the skip); an updateConfig hook cannot undo
`--no-runtime` on install or dedupe (fails without recording the flag in
cli_settings); a hook setting `runtime: false` skips the runtime.

The install docs now spell the setting `runtime: false`, and the dedupe
docs list `--no-runtime`.

Part of pnpm/tasks#191.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
no_runtime_checks_the_active_node_instead_of_the_manifest_runtime used a
`>=1.0.0` devEngines.runtime range. A range yields no configured Node.js
version, so the root engine check used the active Node.js whether or not
`--no-runtime` was given, and the test could not fail. With an exact
`1.0.0` the manifest runtime does not satisfy `engines.node`, so the
test now fails with ERR_PNPM_UNSUPPORTED_ENGINE when the check ignores
the skip.

Part of pnpm/tasks#191.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@zkochan
zkochan force-pushed the fix-runtime-false-setting branch from d1d1c4f to eeda050 Compare October 22, 2026 23:57
@zkochan
zkochan marked this pull request as ready for review October 23, 2026 00:19
Copilot AI balanced review requested due to automatic review settings October 23, 2026 00:19
@zkochan

zkochan commented Oct 23, 2026

Copy link
Copy Markdown
Member Author

@coderabbitai review

@greptile-apps greptile-apps Bot left a comment

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.

Your trial has ended. Reactivate Greptile to resume code reviews.

Copilot AI left a comment

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.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@qodo-code-review

Copy link
Copy Markdown

PR Summary by Qodo

Honor runtime settings across installing commands

🐞 Bug fix 🧪 Tests 📝 Documentation 🕐 40+ Minutes

Grey Divider

AI Description

• Honor runtime: false from workspace, environment, and command-line settings when installing
 runtimes.
• Make dedupe and prune follow the setting; add --no-runtime to dedupe.
• Preserve --no-runtime through configuration hooks and validate skipped-runtime engine checks.
Diagram

graph TD
  A["Runtime sources"] --> B["WorkspaceSettings"] --> C["Config skip flag"] --> D["updateConfig hooks"] --> E["Installing commands"] --> F{"Skip runtime?"}
  F -->|No| G["Fetch and link"]
  F -->|Yes| H["Skip installation"]
Loading
High-Level Assessment

Keep runtime precedence in the existing configuration pipeline and reuse the shared install-family policy. Per-command overrides would duplicate behavior and risk leaving another installing command inconsistent.

Files changed (19) +291 / -11

Bug fix (11) +32 / -6
dedupe.rsAccept '--no-runtime' in dedupe +4/-1

Accept '--no-runtime' in dedupe

• Adds the dedupe flag and stops forcing runtime installation in its install plan.

pnpm/crates/cli/src/cli_args/dedupe.rs

pipelines.rsApply runtime policy during root preparation +3/-2

Apply runtime policy during root preparation

• Records '--no-runtime' before configuration hooks and removes the policy that always used manifest runtimes. Root engine checks now follow the effective skip decision.

pnpm/crates/cli/src/cli_args/pipelines.rs

configuration.rsPreserve CLI runtime precedence through hooks +8/-0

Preserve CLI runtime precedence through hooks

• Records '--no-runtime' as an explicit CLI setting so hooks see 'runtime: false' but cannot override the flag.

pnpm/crates/cli/src/cli_args/pipelines/configuration.rs

maintenance.rsUse configured runtime policy in maintenance commands +6/-2

Use configured runtime policy in maintenance commands

• Makes dedupe use its runtime flag and makes dedupe and prune respect the configured skip policy during root preparation.

pnpm/crates/cli/src/cli_args/pipelines/maintenance.rs

prune.rsStop forcing runtimes on in prune +0/-1

Stop forcing runtimes on in prune

• Removes prune's override of the configured runtime-skip setting.

pnpm/crates/cli/src/cli_args/prune.rs

env_overlay.rsRead runtime from the environment +1/-0

Read runtime from the environment

• Adds 'PNPM_CONFIG_RUNTIME' to the workspace-settings environment overlay.

pnpm/crates/config/src/env_overlay.rs

apply.rsApply runtime setting to skip policy +3/-0

Apply runtime setting to skip policy

• Maps an explicitly set 'runtime' value to the inverse 'Config::skip_runtimes' value.

pnpm/crates/config/src/workspace_yaml/apply.rs

reset.rsReset runtime policy when the setting is removed +1/-0

Reset runtime policy when the setting is removed

• Restores the default runtime-skip value when configuration resolution resets 'runtime'.

pnpm/crates/config/src/workspace_yaml/reset.rs

resolved.rsReport explicitly set runtime values to hooks +1/-0

Report explicitly set runtime values to hooks

• Includes 'runtime' in resolved settings only when a source explicitly set it.

pnpm/crates/config/src/workspace_yaml/resolved.rs

settings.rsRepresent runtime in workspace settings +4/-0

Represent runtime in workspace settings

• Adds an optional boolean runtime field to 'WorkspaceSettings'.

pnpm/crates/config/src/workspace_yaml/settings.rs

workspace_scope.rsExclude runtime from global configuration +1/-0

Exclude runtime from global configuration

• Clears 'runtime' when loading workspace-only settings from global 'config.yaml'.

pnpm/crates/config/src/workspace_yaml/workspace_scope.rs

Tests (4) +247 / -2
install_root_engine.rsCover engine checks when maintenance skips runtimes +44/-2

Cover engine checks when maintenance skips runtimes

• Tests that dedupe and prune check the active Node.js when runtimes are skipped. Tightens the existing '--no-runtime' fixture's manifest runtime version.

pnpm/crates/cli/tests/suite/install_root_engine.rs

no_runtime.rsExercise runtime-setting precedence end to end +149/-0

Exercise runtime-setting precedence end to end

• Tests workspace and CLI settings, dedupe and prune, and configuration-hook behavior. Verifies skipped runtimes are neither fetched nor installed.

pnpm/crates/cli/tests/suite/install_runtimes/no_runtime.rs

workspace_settings_materialization_env_vars_override.rsTest runtime-setting sources and precedence +53/-0

Test runtime-setting sources and precedence

• Covers workspace YAML, an overriding environment value, and exclusion of runtime from global 'config.yaml'.

pnpm/crates/config/src/tests/workspace_settings_materialization_env_vars_override.rs

configuration_from_resolved_reports_every.rsCover runtime in resolved-settings reporting +1/-0

Cover runtime in resolved-settings reporting

• Extends the resolved-settings test to include an explicitly set runtime value.

pnpm/crates/config/src/workspace_yaml/tests/configuration_from_resolved_reports_every.rs

Documentation (4) +12 / -3
runtime-false-setting.mdAnnounce runtime-setting support +5/-0

Announce runtime-setting support

• Adds a patch changeset describing runtime-skip settings and dedupe's new flag.

.changeset/runtime-false-setting.md

settings.rsDocument sources of the runtime-skip flag +2/-2

Document sources of the runtime-skip flag

• Clarifies that both 'runtime: false' and '--no-runtime' set 'Config::skip_runtimes'.

pnpm/crates/config/src/settings.rs

dedupe.mdDocument dedupe's runtime flag +4/-0

Document dedupe's runtime flag

• Explains that 'pnpm dedupe --no-runtime' skips installing manifest runtimes.

pnpm/docs/cli/dedupe.md

install.mdClarify workspace runtime syntax +1/-1

Clarify workspace runtime syntax

• Shows the YAML form 'runtime: false' alongside install's '--no-runtime' option.

pnpm/docs/cli/install.md

@qodo-code-review

Copy link
Copy Markdown

Code Review by Qodo

🐞 Bugs (0) 📘 Rule violations (1) 📎 Requirement gaps (0) 🔗 Cross-repo conflicts (0) 📜 Skill insights (0)

Grey Divider


Remediation recommended

1. Changeset lead omits the runtime effect 📘 Rule violation ⚙ Maintainability
Description
The first sentence of .changeset/runtime-false-setting.md says only that the runtime setting is
read, without stating what users observe when it is false. It also uses passive wording, so readers
must reach the second sentence to learn that installs skip devEngines.runtime and
engines.runtime.
Code

.changeset/runtime-false-setting.md[5]

+The `runtime` setting is now read. Setting `runtime: false` in `pnpm-workspace.yaml`, `pnpm_config_runtime=false`, or `--config.runtime=false` stops `pnpm install`, `pnpm add`, `pnpm dedupe`, and the other installing commands from installing the runtimes in `devEngines.runtime` and `engines.runtime`. `pnpm dedupe` now also accepts `--no-runtime`.
Relevance

●●● Strong

Recent changeset precedents accept rewriting leads to state the user-visible behavior directly.

PR-#17220
PR-#17186

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The changeset's first sentence uses passive implementation-focused wording and does not state the
user-visible effect required by the changeset conventions. The second sentence contains the actual
behavior, but the lead sentence must itself identify the observable setting change.

Rule 3058297: Format changeset entry first sentence as user-visible command/setting/behavior change
Rule 3058332: Use plain, direct, and quantifiable language in changeset entries
.changeset/runtime-false-setting.md[5-5]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
The changeset lead says that the `runtime` setting is read, which describes implementation rather than the user-visible behavior and uses passive wording. The first sentence should state that the relevant commands now skip runtime installation when `runtime: false` is configured.

## Fix Focus Areas
- .changeset/runtime-false-setting.md[5-5]

## Recommended Fix
Rewrite the first sentence as an active, user-facing behavior statement, such as: `pnpm now skips installing declared runtimes when the runtime setting is false.` Keep the configuration sources and command details in the following sentence.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools

Dismiss ↗ | View ↗


Grey Divider

Context sources
✅ Compliance rules (platform): 62 rules
✅ Cross-repo context — repo relationships
  Explored: repo: pnpm/update (sha: 2457663d) — View relationship
  Explored: repo: pnpm/setup (sha: a0881977) — View relationship
  Explored: repo: pnpm/pnpm.io (sha: 0aab2bac) — View relationship
Review mode: Auto: 🧠 Deep: Multiple config, CLI, hook, and command paths create independent subtle risks.

Grey Divider

Tip of the day
💡 Did you know, you can reply 'qodo' on any finding to push back, ask questions, or dig deeper

More tips ↗ | Customize Qodo ↗ | Qodo docs ↗

Grey Divider

Qodo Logo

@qodo-code-review

Copy link
Copy Markdown

PR Code Suggestions ✨

Warning

/improve is deprecated. Use /agentic_review instead (removal date not yet scheduled).

No code suggestions found for the PR.

@github-actions github-actions Bot added the reviewed: coderabbit CodeRabbit submitted an approving review label Oct 23, 2026
@coderabbitai

coderabbitai Bot commented Oct 23, 2026

Copy link
Copy Markdown
Contributor

Rate Limit Exceeded

@zkochan have exceeded the limit for the number of chat messages per hour. Please wait 19 minutes and 17 seconds before sending another message.

@zkochan
zkochan merged commit 6ab3c27 into main Oct 23, 2026
63 checks passed
@zkochan
zkochan deleted the fix-runtime-false-setting branch October 23, 2026 09:10
zkochan added a commit that referenced this pull request Oct 24, 2026
…#17269)

The v12 settings reference (the index in pnpm/docs/settings.md and the
sections of pnpm/docs/settings/*.md with their imported partials) had
drifted from the keys pnpm reads from config files: settings with no
section, sections missing from the index, and sections for settings no
code reads. Nothing caught it.

A unit test in pnpm-config now compares the reference with the camelCase
field names of WorkspaceSettings (the list the unknown-setting check
already reads off the struct). It extracts setting names from headings
(dotted names count for their top-level key; headings listing several
names split on `,` and `/`; prose headings and CLI flags are skipped),
computes Docusaurus anchors, and checks every index link resolves. Index
entries linking to other pages document a setting when the anchor exists;
a link without an anchor documents none.

The runtime setting, read since #17261, gets a section in
settings/cli.md and an index entry. The remaining gaps sit in per-kind
allowlists, each entry noting where the setting is documented or that
it is not. A new gap fails the test, and so does an allowlist entry that
is no longer a gap.

Part of the Prevention section of pnpm/tasks#191.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

product: pacquet reviewed: coderabbit CodeRabbit submitted an approving review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants