Skip to content

fix(outdated): preserve all distinct workspace dependency entries in json output (pnpm/pnpm#7693) - #15418

Merged
zkochan merged 4 commits into
mainfrom
fix-7693
Sep 24, 2026
Merged

zkochan merged 4 commits into
mainfrom
fix-7693

Conversation

@zkochan

@zkochan zkochan commented Sep 23, 2026 •

Copy link
Copy Markdown
Member

Summary

When multiple packages across a workspace depend on different versions or dependency types of the same package, pnpm -r outdated --json previously indexed the JSON output map strictly by package name (acc[outdatedPkg.packageName]). Earlier entries were overwritten, causing dependencies to be silently omitted from the JSON output.

This PR ensures distinct outdated workspace entries are preserved in both TypeScript (pnpm v11) and Rust (pacquet, pnpm v12). When a package has multiple outdated entries in the workspace report, its key in the JSON output is disambiguated as ${packageName}@${current}${typeSuffix} (e.g. [email protected], [email protected] (dev)). Single-entry packages retain their standard package name key for backwards compatibility. The same keying applies to non-recursive pnpm outdated --json when a name repeats there, such as one package listed in two dependency groups of the same manifest. Both stacks derive the key suffix from the same dependency-type label the table output uses.

Closes #7693

Squash Commit Body

When multiple workspace packages depend on different versions or dependency
types of the same package, `pnpm -r outdated --json` previously overwrote
earlier entries keyed solely by package name.

Key entries uniquely as `${packageName}@${current}${typeSuffix}` when a
package has multiple outdated entries across the workspace. Distinct
dependencies are now preserved in both TypeScript and Rust CLI
implementations.

Closes pnpm/pnpm#7693

Checklist

  • I checked the referenced issue and verified that none of the PRs already linked to it solves it.
  • New features are implemented only in the Rust pnpm v12 CLI. Bug fixes are implemented in every affected version.
  • 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.

View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.

@coderabbitai

coderabbitai Bot commented Sep 23, 2026 •

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

Next included review available in 1 minute.

Check out review usage here.

View limit details

Limit details: You’ve used all 10 included reviews 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: Repository: pnpm/pnpm/.coderabbit.yaml

Review profile: CHILL

Plan: Advanced

Run ID: e9365e1f-0f2a-49ca-9be8-bd869d0aef34

📥 Commits

Reviewing files that changed from the base of the PR and between 9e8d04e and 629eb94.

📒 Files selected for processing (8)
  • .changeset/outdated-recursive-json-all-deps.md
  • pnpm/crates/cli/src/cli_args/outdated/render.rs
  • pnpm/crates/cli/src/cli_args/outdated/render/json.rs
  • pnpm/crates/cli/src/cli_args/outdated/tests.rs
  • pnpm/crates/cli/tests/suite/outdated.rs
  • pnpm11/deps/inspection/commands/src/outdated/outdated.ts
  • pnpm11/deps/inspection/commands/src/outdated/recursive.ts
  • pnpm11/deps/inspection/commands/test/outdated/recursive.ts

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 Sep 23, 2026 •

Copy link
Copy Markdown
Contributor

Micro-Benchmark Results

Linux

group                                            main                                   pr
-----                                            ----                                   --
lockfile/parse_pnpm_lock                         1.00     14.7±1.04ms    25.4 MB/sec    1.06     15.6±1.36ms    24.0 MB/sec
packument/parse                                  1.00     45.0±2.91µs  1475.1 MB/sec    1.01     45.3±4.12µs  1465.5 MB/sec
tarball/download_dependency                      1.13      5.9±1.36ms   732.7 KB/sec    1.00      5.2±0.81ms   830.8 KB/sec
tarball_batch/cold_store_many_medium_tarballs    1.08    271.0±8.52ms 59.0 KElem/sec    1.00   252.1±12.80ms 63.5 KElem/sec
workspace_resolution/hoist_heavy                 1.01   394.2±33.15ms        ? ?/sec    1.00   388.8±34.75ms        ? ?/sec
workspace_sort/chained_projects                  1.37     24.2±5.77ms        ? ?/sec    1.00     17.7±3.20ms        ? ?/sec

@codecov-commenter

codecov-commenter commented Sep 23, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 89.41176% with 9 lines in your changes missing coverage. Please review.
✅ Project coverage is 91.80%. Comparing base (cd81e68) to head (629eb94).
⚠️ Report is 4 commits behind head on main.

Files with missing lines Patch % Lines
...pm/crates/cli/src/cli_args/outdated/render/json.rs 92.00% 6 Missing ⚠️
pnpm/crates/cli/src/cli_args/outdated/render.rs 70.00% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main   #15418      +/-   ##
==========================================
- Coverage   91.82%   91.80%   -0.02%     
==========================================
  Files        1428     1431       +3     
  Lines      192970   193332     +362     
==========================================
+ Hits       177192   177497     +305     
- Misses      15778    15835      +57     

☔ 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.

@github-actions

github-actions Bot commented Sep 23, 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 2487.33 ms 2525.28 ms 1.5% 124.37 ms Within tolerance
isolated-fresh-restore-cold-cache-cold-store pnpr 1543.90 ms 1512.79 ms -2.0% 77.20 ms Within tolerance
isolated-fresh-restore-hot-cache-hot-store pacquet 289.72 ms 310.19 ms 7.1% 14.49 ms Inconclusive (overlapping samples)
isolated-fresh-restore-hot-cache-hot-store pnpr 345.95 ms 323.04 ms -6.6% 17.30 ms Within tolerance
isolated-repeat-install-hot-cache-hot-store pacquet 11.73 ms 11.61 ms -1.1% 2.00 ms Within tolerance
isolated-repeat-install-hot-cache-hot-store pnpr 11.37 ms 11.50 ms 1.1% 2.00 ms Within tolerance
isolated-repeat-install-cold-cache-hot-store pacquet 17.32 ms 20.03 ms 15.6% 2.00 ms Inconclusive (overlapping samples)
isolated-repeat-install-cold-cache-hot-store pnpr 14.04 ms 18.57 ms 32.3% 2.00 ms Inconclusive (overlapping samples)
isolated-fresh-install-cold-cache-cold-store pacquet 2598.29 ms 2639.17 ms 1.6% 129.91 ms Within tolerance
isolated-fresh-install-cold-cache-cold-store pnpr 1496.12 ms 1498.13 ms 0.1% 74.81 ms Within tolerance
isolated-fresh-install-hot-cache-hot-store pacquet 435.95 ms 451.16 ms 3.5% 21.80 ms Within tolerance
isolated-fresh-install-hot-cache-hot-store pnpr 317.00 ms 333.79 ms 5.3% 15.85 ms Inconclusive (overlapping samples)
isolated-fresh-install-cold-cache-hot-store pacquet 1783.74 ms 1830.37 ms 2.6% 89.19 ms Within tolerance
isolated-fresh-install-cold-cache-hot-store pnpr 358.12 ms 363.88 ms 1.6% 17.91 ms Within tolerance
isolated-fresh-resolve-hot-cache-offline pacquet 300.37 ms 258.20 ms -14.0% 15.02 ms Within tolerance
isolated-fresh-resolve-hot-cache-offline pnpr 118.56 ms 115.00 ms -3.0% 5.93 ms Within tolerance
isolated-peer-heavy-resolve-hot-cache-offline pacquet 746.10 ms 819.07 ms 9.8% 37.30 ms Inconclusive (overlapping samples)
isolated-linked-workspace-resolve-hot-cache-offline pacquet 188.60 ms 188.20 ms -0.2% 9.43 ms Within tolerance
isolated-fresh-restore-cold-cache-cold-store-cold-pnpr pacquet 4860.50 ms 4590.39 ms -5.6% 243.02 ms Within tolerance
isolated-fresh-restore-cold-cache-cold-store-cold-pnpr pnpr 3444.86 ms 3479.85 ms 1.0% 172.24 ms Within tolerance
gvs-fresh-restore-hot-cache-hot-store pacquet 181.60 ms 228.32 ms 25.7% 9.08 ms Inconclusive (not reproduced)
gvs-fresh-restore-hot-cache-hot-store pnpr 183.64 ms 193.51 ms 5.4% 9.18 ms Inconclusive (overlapping samples)

Integrated-Benchmark Report (Linux)

Commit: 629eb949f205

Regular scenarios report direct and pnpr installs. The peer-heavy resolver scenario compares current Rust, main Rust, and TypeScript pnpm; the linked-workspace scenario compares 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.509 ± 0.136 2.327 2.710 1.66 ± 0.14
pacquet@main 2.520 ± 0.131 2.385 2.737 1.67 ± 0.14
pnpr@HEAD 1.510 ± 0.101 1.377 1.692 1.00
pnpr@main 1.566 ± 0.104 1.411 1.719 1.04 ± 0.10
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 2.50862836154,
      "stddev": 0.13612952770925824,
      "median": 2.52527893094,
      "user": 1.9798724399999998,
      "system": 1.7808581799999996,
      "min": 2.32702667644,
      "max": 2.70989904344
    },
    {
      "command": "pacquet@main",
      "mean": 2.5197529233399996,
      "stddev": 0.13116900860032965,
      "median": 2.48733320044,
      "user": 2.25328264,
      "system": 1.97111728,
      "min": 2.38482494444,
      "max": 2.73747511944
    },
    {
      "command": "pnpr@HEAD",
      "mean": 1.51035324634,
      "stddev": 0.10094517239076174,
      "median": 1.51279311994,
      "user": 2.1104514400000003,
      "system": 1.92180468,
      "min": 1.37668904044,
      "max": 1.6917048344399999
    },
    {
      "command": "pnpr@main",
      "mean": 1.5655609854399999,
      "stddev": 0.10441469244288029,
      "median": 1.54390387444,
      "user": 2.16036064,
      "system": 2.03272258,
      "min": 1.41110544144,
      "max": 1.71930371344
    }
  ]
}

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

Command Mean [ms] Min [ms] Max [ms] Relative
pacquet@HEAD 312.4 ± 30.1 275.1 384.6 1.08 ± 0.12
pacquet@main 290.0 ± 17.6 262.3 309.8 1.00
pnpr@HEAD 322.8 ± 27.8 282.9 381.7 1.11 ± 0.12
pnpr@main 355.2 ± 34.6 303.9 421.7 1.22 ± 0.14
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 0.31237641569999997,
      "stddev": 0.03007463806676164,
      "median": 0.31018506440000004,
      "user": 0.34777326000000003,
      "system": 0.689522,
      "min": 0.27506243890000004,
      "max": 0.3845568139
    },
    {
      "command": "pacquet@main",
      "mean": 0.29002295530000005,
      "stddev": 0.017640744471769602,
      "median": 0.2897214199,
      "user": 0.33981176,
      "system": 0.6389131000000001,
      "min": 0.2622639989,
      "max": 0.3098397149
    },
    {
      "command": "pnpr@HEAD",
      "mean": 0.3228327126,
      "stddev": 0.02781352371390983,
      "median": 0.32304373890000004,
      "user": 0.33798165999999996,
      "system": 0.6826026000000001,
      "min": 0.2829464049,
      "max": 0.38171093790000005
    },
    {
      "command": "pnpr@main",
      "mean": 0.3552009801,
      "stddev": 0.0345701051003781,
      "median": 0.3459485094,
      "user": 0.38214446,
      "system": 0.7311696000000001,
      "min": 0.3039367009,
      "max": 0.4216727959
    }
  ]
}

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

Command Mean [ms] Min [ms] Max [ms] Relative
pacquet@HEAD 11.9 ± 1.9 8.6 19.4 1.02 ± 0.23
pacquet@main 12.1 ± 2.0 8.6 22.2 1.04 ± 0.24
pnpr@HEAD 11.7 ± 1.9 8.5 19.3 1.00
pnpr@main 11.7 ± 2.5 7.3 21.7 1.00 ± 0.27
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 0.01192095130222222,
      "stddev": 0.0018870963397986393,
      "median": 0.011608703440000001,
      "user": 0.006790042222222223,
      "system": 0.005860728355555554,
      "min": 0.00855579044,
      "max": 0.01942334044
    },
    {
      "command": "pacquet@main",
      "mean": 0.012146662331774893,
      "stddev": 0.0020386377355876067,
      "median": 0.011733178440000002,
      "user": 0.006662702077922077,
      "system": 0.006245262683982683,
      "min": 0.008647984440000001,
      "max": 0.02222638144
    },
    {
      "command": "pnpr@HEAD",
      "mean": 0.01171699629650224,
      "stddev": 0.0019202483691920212,
      "median": 0.01149525944,
      "user": 0.006836327085201788,
      "system": 0.005600270313901347,
      "min": 0.008460460440000001,
      "max": 0.01934856844
    },
    {
      "command": "pnpr@main",
      "mean": 0.011725028360168071,
      "stddev": 0.0024806671151217153,
      "median": 0.011374471940000002,
      "user": 0.00700478420168067,
      "system": 0.005373819327731093,
      "min": 0.007307438440000001,
      "max": 0.02170826544
    }
  ]
}

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

Command Mean [ms] Min [ms] Max [ms] Relative
pacquet@HEAD 20.6 ± 4.5 13.7 36.8 1.43 ± 0.43
pacquet@main 17.4 ± 3.2 10.6 24.7 1.21 ± 0.33
pnpr@HEAD 18.3 ± 5.0 8.6 30.2 1.27 ± 0.43
pnpr@main 14.4 ± 2.9 9.7 24.5 1.00
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 0.020626382655145627,
      "stddev": 0.004525136405352266,
      "median": 0.020028911160000003,
      "user": 0.011420441941747572,
      "system": 0.010183500970873787,
      "min": 0.01369778116,
      "max": 0.03677784516
    },
    {
      "command": "pacquet@main",
      "mean": 0.01743321086666667,
      "stddev": 0.003181232374995746,
      "median": 0.01732124016,
      "user": 0.009887673333333336,
      "system": 0.008486361333333334,
      "min": 0.01055017016,
      "max": 0.024666480160000004
    },
    {
      "command": "pnpr@HEAD",
      "mean": 0.018299053505679005,
      "stddev": 0.004995162510980906,
      "median": 0.01857283666,
      "user": 0.010104988148148147,
      "system": 0.009090908641975308,
      "min": 0.00861363416,
      "max": 0.030163414160000002
    },
    {
      "command": "pnpr@main",
      "mean": 0.014399360660000004,
      "stddev": 0.0029247179010315257,
      "median": 0.01403686316,
      "user": 0.007596365800000005,
      "system": 0.007588110999999997,
      "min": 0.00970215716,
      "max": 0.02452516416
    }
  ]
}

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

Command Mean [s] Min [s] Max [s] Relative
pacquet@HEAD 2.656 ± 0.109 2.535 2.842 1.74 ± 0.14
pacquet@main 2.601 ± 0.066 2.517 2.752 1.70 ± 0.13
pnpr@HEAD 1.529 ± 0.106 1.411 1.764 1.00
pnpr@main 1.544 ± 0.129 1.414 1.798 1.01 ± 0.11
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 2.6558391487199993,
      "stddev": 0.10882752336969169,
      "median": 2.6391717015199996,
      "user": 2.2503237599999997,
      "system": 1.7307063399999998,
      "min": 2.5350076755199997,
      "max": 2.84163218352
    },
    {
      "command": "pacquet@main",
      "mean": 2.60078828832,
      "stddev": 0.06555371449646477,
      "median": 2.59829423452,
      "user": 2.15346386,
      "system": 1.6663471399999996,
      "min": 2.51743466452,
      "max": 2.75219272552
    },
    {
      "command": "pnpr@HEAD",
      "mean": 1.5287418474199999,
      "stddev": 0.10560953510257816,
      "median": 1.49813342702,
      "user": 1.28857486,
      "system": 1.3373960399999996,
      "min": 1.41112082152,
      "max": 1.76404572652
    },
    {
      "command": "pnpr@main",
      "mean": 1.5440269948199998,
      "stddev": 0.1285855266847568,
      "median": 1.49612003102,
      "user": 1.1638823600000001,
      "system": 1.26446244,
      "min": 1.41383679152,
      "max": 1.7981835755200002
    }
  ]
}

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

Command Mean [ms] Min [ms] Max [ms] Relative
pacquet@HEAD 457.6 ± 35.8 414.9 520.0 1.41 ± 0.16
pacquet@main 464.0 ± 63.5 388.3 596.2 1.43 ± 0.23
pnpr@HEAD 335.2 ± 17.7 302.5 365.2 1.03 ± 0.10
pnpr@main 324.3 ± 26.4 296.6 387.2 1.00
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 0.45756270366,
      "stddev": 0.03582121875274016,
      "median": 0.45116371326000004,
      "user": 0.65850338,
      "system": 0.71416724,
      "min": 0.41487356926,
      "max": 0.51996602526
    },
    {
      "command": "pacquet@main",
      "mean": 0.4640153647600001,
      "stddev": 0.06351285993728958,
      "median": 0.43595010176000004,
      "user": 0.6493419800000001,
      "system": 0.74410364,
      "min": 0.38827009326,
      "max": 0.59622960126
    },
    {
      "command": "pnpr@HEAD",
      "mean": 0.33523717646000006,
      "stddev": 0.017702379755028686,
      "median": 0.33378582126,
      "user": 0.29844738,
      "system": 0.5988022399999999,
      "min": 0.30245953526,
      "max": 0.36519648726000004
    },
    {
      "command": "pnpr@main",
      "mean": 0.32433099746000005,
      "stddev": 0.026424143027348277,
      "median": 0.31700476276,
      "user": 0.25555248,
      "system": 0.58473194,
      "min": 0.29664804526000005,
      "max": 0.38721898126000004
    }
  ]
}

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

Command Mean [s] Min [s] Max [s] Relative
pacquet@HEAD 1.821 ± 0.058 1.699 1.895 5.08 ± 0.28
pacquet@main 1.781 ± 0.040 1.714 1.851 4.96 ± 0.24
pnpr@HEAD 0.376 ± 0.057 0.326 0.514 1.05 ± 0.16
pnpr@main 0.359 ± 0.016 0.343 0.393 1.00
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 1.8214522900400003,
      "stddev": 0.05816109216332685,
      "median": 1.83036933504,
      "user": 1.20648836,
      "system": 1.07508656,
      "min": 1.69917094404,
      "max": 1.8950788840400001
    },
    {
      "command": "pacquet@main",
      "mean": 1.78071749104,
      "stddev": 0.04001709639061017,
      "median": 1.78374208704,
      "user": 1.16918356,
      "system": 1.0225908599999998,
      "min": 1.71421090004,
      "max": 1.8508854750400001
    },
    {
      "command": "pnpr@HEAD",
      "mean": 0.37554722184,
      "stddev": 0.05682610857073479,
      "median": 0.36388255954000004,
      "user": 0.34249606,
      "system": 0.7155104599999998,
      "min": 0.32579104504000006,
      "max": 0.51446091604
    },
    {
      "command": "pnpr@main",
      "mean": 0.35871803334,
      "stddev": 0.015724096249416817,
      "median": 0.35812182654,
      "user": 0.3055006599999999,
      "system": 0.6673259599999999,
      "min": 0.34271422004,
      "max": 0.39340765704
    }
  ]
}

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

Command Mean [ms] Min [ms] Max [ms] Relative
pacquet@HEAD 263.6 ± 38.3 224.0 342.5 2.17 ± 0.43
pacquet@main 308.8 ± 57.2 233.3 405.1 2.54 ± 0.58
pnpr@HEAD 121.7 ± 16.2 105.9 158.3 1.00
pnpr@main 122.2 ± 16.5 103.6 174.0 1.00 ± 0.19
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 0.26362952324,
      "stddev": 0.03827518487810054,
      "median": 0.25820031784,
      "user": 0.28574851999999995,
      "system": 0.07980968,
      "min": 0.22403081634000002,
      "max": 0.34247638834000005
    },
    {
      "command": "pacquet@main",
      "mean": 0.3087905666127273,
      "stddev": 0.057200096282666264,
      "median": 0.30036841134000003,
      "user": 0.3296620927272727,
      "system": 0.11083536181818182,
      "min": 0.23334328534,
      "max": 0.40508272134
    },
    {
      "command": "pnpr@HEAD",
      "mean": 0.12167468949789477,
      "stddev": 0.016187623440677004,
      "median": 0.11499991534000001,
      "user": 0.05496824105263159,
      "system": 0.023682548421052628,
      "min": 0.10589107834000001,
      "max": 0.15827988134
    },
    {
      "command": "pnpr@main",
      "mean": 0.12222190610923081,
      "stddev": 0.01645169250793713,
      "median": 0.11856366034000002,
      "user": 0.05594181999999999,
      "system": 0.024864872307692305,
      "min": 0.10358503934,
      "max": 0.17400252334000002
    }
  ]
}

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

Command Mean [ms] Min [ms] Max [ms] Relative
pacquet@HEAD 864.5 ± 170.6 644.9 1218.8 1.13 ± 0.28
pacquet@main 765.2 ± 112.4 575.9 939.5 1.00
pnpm@HEAD 3566.3 ± 220.9 3329.6 4052.8 4.66 ± 0.74
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 0.8645406468622223,
      "stddev": 0.170575618153155,
      "median": 0.8190667506400001,
      "user": 0.8880855733333332,
      "system": 0.18184779777777776,
      "min": 0.6449044096400001,
      "max": 1.21875462264
    },
    {
      "command": "pacquet@main",
      "mean": 0.7652158849733334,
      "stddev": 0.11243368454446163,
      "median": 0.7460956776400001,
      "user": 0.7909595733333333,
      "system": 0.18167279777777778,
      "min": 0.5758882876400001,
      "max": 0.9394648126400001
    },
    {
      "command": "pnpm@HEAD",
      "mean": 3.5662551553066666,
      "stddev": 0.22085982609562854,
      "median": 3.49129070664,
      "user": 5.521166795555555,
      "system": 0.25944357555555553,
      "min": 3.32957376964,
      "max": 4.05276057864
    }
  ]
}

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

Command Mean [ms] Min [ms] Max [ms] Relative
pacquet@HEAD 188.7 ± 5.0 179.2 197.5 1.00
pacquet@main 196.1 ± 20.1 178.2 255.7 1.04 ± 0.11
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 0.18868219341428574,
      "stddev": 0.0049965549406561695,
      "median": 0.1882012912,
      "user": 0.14668899142857142,
      "system": 0.08693931999999997,
      "min": 0.17917661220000003,
      "max": 0.19746049820000003
    },
    {
      "command": "pacquet@main",
      "mean": 0.1961111328,
      "stddev": 0.02010697592679023,
      "median": 0.18859680120000002,
      "user": 0.1453303533333333,
      "system": 0.09790898666666668,
      "min": 0.17822760020000003,
      "max": 0.25567191720000004
    }
  ]
}

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

Command Mean [s] Min [s] Max [s] Relative
pacquet@HEAD 4.615 ± 0.148 4.462 4.986 1.31 ± 0.08
pacquet@main 4.905 ± 0.278 4.599 5.397 1.39 ± 0.11
pnpr@HEAD 3.538 ± 0.111 3.438 3.793 1.00 ± 0.06
pnpr@main 3.534 ± 0.199 3.391 4.039 1.00
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 4.61485173452,
      "stddev": 0.14831823987176598,
      "median": 4.59039321052,
      "user": 2.00117624,
      "system": 1.85947584,
      "min": 4.46247483102,
      "max": 4.98570817602
    },
    {
      "command": "pacquet@main",
      "mean": 4.905044114920001,
      "stddev": 0.2776435289265451,
      "median": 4.86049551102,
      "user": 2.31284374,
      "system": 2.0558299399999997,
      "min": 4.59888670902,
      "max": 5.39738256702
    },
    {
      "command": "pnpr@HEAD",
      "mean": 3.53796457702,
      "stddev": 0.11144251045642979,
      "median": 3.4798535470200003,
      "user": 1.70040084,
      "system": 1.58227144,
      "min": 3.4377465050200002,
      "max": 3.79273688302
    },
    {
      "command": "pnpr@main",
      "mean": 3.53383603252,
      "stddev": 0.19911474862823714,
      "median": 3.4448586260200003,
      "user": 1.7642787399999995,
      "system": 1.6124825400000002,
      "min": 3.39066046602,
      "max": 4.03865734402
    }
  ]
}

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 233.3 ± 22.5 194.8 278.1 1.27 ± 0.22
pacquet@main 184.0 ± 26.0 160.0 248.1 1.00
pnpr@HEAD 189.7 ± 10.8 173.4 206.1 1.03 ± 0.16
pnpr@main 186.0 ± 14.3 171.1 225.6 1.01 ± 0.16

Confirmation (reversed target order)

Command Mean [ms] Min [ms] Max [ms] Relative
pnpr@main 185.8 ± 15.8 164.9 210.3 1.08 ± 0.12
pnpr@HEAD 186.3 ± 22.1 147.3 215.7 1.08 ± 0.15
pacquet@main 171.9 ± 11.1 151.3 195.3 1.00
pacquet@HEAD 182.4 ± 19.4 165.6 236.7 1.06 ± 0.13
BENCHMARK_REPORT.json
{
  "results": [
    {
      "command": "pacquet@HEAD",
      "mean": 0.23334620624181818,
      "stddev": 0.022506887464347345,
      "median": 0.22831759706,
      "user": 0.21287112181818185,
      "system": 0.19441646727272727,
      "min": 0.19482691606,
      "max": 0.27805387806
    },
    {
      "command": "pacquet@main",
      "mean": 0.18402778226,
      "stddev": 0.025975416090178054,
      "median": 0.18159956856,
      "user": 0.22633853999999992,
      "system": 0.19531874,
      "min": 0.15996783106,
      "max": 0.24813877706
    },
    {
      "command": "pnpr@HEAD",
      "mean": 0.18970140505999994,
      "stddev": 0.010809656492951965,
      "median": 0.19351466006,
      "user": 0.22572940153846155,
      "system": 0.20930973999999997,
      "min": 0.17338926306,
      "max": 0.20611895606
    },
    {
      "command": "pnpr@main",
      "mean": 0.18597868491714284,
      "stddev": 0.014269332454175946,
      "median": 0.18363518606,
      "user": 0.20460701142857146,
      "system": 0.21040645428571425,
      "min": 0.17112454906,
      "max": 0.22564906706
    }
  ],
  "confirmation": {
    "results": [
      {
        "command": "pnpr@main",
        "mean": 0.1857696563430769,
        "stddev": 0.015784607219137138,
        "median": 0.18768548142000002,
        "user": 0.23179141846153842,
        "system": 0.1734151123076923,
        "min": 0.16486948242000002,
        "max": 0.21027011142000002
      },
      {
        "command": "pnpr@HEAD",
        "mean": 0.18634031626615383,
        "stddev": 0.022103420312145627,
        "median": 0.18601595742000002,
        "user": 0.21896057230769225,
        "system": 0.20122503538461536,
        "min": 0.14730463542000002,
        "max": 0.21567728042000003
      },
      {
        "command": "pacquet@main",
        "mean": 0.17186950562,
        "stddev": 0.01109229101744008,
        "median": 0.17136441842000003,
        "user": 0.20842968,
        "system": 0.20232475333333333,
        "min": 0.15127874042000003,
        "max": 0.19530822342
      },
      {
        "command": "pacquet@HEAD",
        "mean": 0.18243077192,
        "stddev": 0.019359033423147345,
        "median": 0.17566423942000003,
        "user": 0.23477580857142852,
        "system": 0.20582784857142858,
        "min": 0.16555141942,
        "max": 0.23666241742000002
      }
    ]
  }
}

@zkochan
zkochan marked this pull request as ready for review September 23, 2026 21:20
@qodo-code-review

Copy link
Copy Markdown

PR Summary by Qodo

Preserve distinct workspace dependencies in outdated JSON

🐞 Bug fix 🧪 Tests 📝 Documentation 🕐 20-40 Minutes

Grey Divider

AI Description

• Preserve distinct outdated entries using version- and dependency-type-qualified JSON keys.
• Retain package-name keys for single entries to maintain backward compatibility.
• Cover TypeScript and Rust renderers with unit, integration, and release-note updates.
Diagram

graph TD
  A["Workspace entries"] --> B["TypeScript renderer"] --> D["Name counts"] --> E{"Multiple entries?"}
  A --> C["Rust renderer"] --> D
  E -- No --> F["Package name key"] --> H["JSON object"]
  E -- Yes --> G["Version type key"] --> H
Loading
High-Level Assessment

The following are alternative approaches to this PR:

1. Return a JSON array
  • ➕ Naturally represents repeated package names without synthesized keys.
  • ➕ Avoids future collisions if additional entry dimensions are introduced.
  • ➖ Breaks consumers expecting an object indexed by package name.
  • ➖ Requires a broader output schema migration across pnpm versions.
2. Group entries by package name
  • ➕ Keeps package names as stable top-level keys.
  • ➕ Makes multiple versions and dependency types explicit as nested entries.
  • ➖ Changes each value from an entry into a collection for duplicate packages.
  • ➖ Creates inconsistent value shapes unless all package values become arrays.

Recommendation: Use the PR's conditional composite-key approach. It preserves the established object schema and exact legacy keys for the common single-entry case while preventing distinct workspace dependencies from overwriting each other. Array or nested representations are structurally cleaner but would impose unnecessary breaking changes for a targeted bug fix.

Files changed (8) +325 / -68

Bug fix (3) +156 / -5
json.rsDisambiguate duplicate outdated entries in Rust JSON +121/-0

Disambiguate duplicate outdated entries in Rust JSON

• Introduces shared composite-key generation for regular and recursive reports, qualifying repeated package names by current version and dependency type. Single entries keep legacy keys, and recursive output now reports the package's actual wanted version.

pnpm/crates/cli/src/cli_args/outdated/render/json.rs

outdated.tsGenerate collision-resistant outdated JSON keys in pnpm v11 +27/-3

Generate collision-resistant outdated JSON keys in pnpm v11

• Counts entries by package name and generates qualified keys only when duplicates exist. Shared helpers add current versions and dependency-type suffixes while preserving legacy keys for unique packages.

pnpm11/deps/inspection/commands/src/outdated/outdated.ts

recursive.tsPreserve duplicate recursive entries in pnpm v11 JSON +8/-2

Preserve duplicate recursive entries in pnpm v11 JSON

• Applies the shared key-generation logic to recursive workspace output. Long-format manifest data is now assigned through the computed key rather than the potentially colliding package name.

pnpm11/deps/inspection/commands/src/outdated/recursive.ts

Refactor (1) +6 / -58
render.rsExtract Rust JSON rendering into a dedicated module +6/-58

Extract Rust JSON rendering into a dedicated module

• Moves outdated JSON rendering behind the new render::json module and re-exports its entry points. It also renders peer dependency markers explicitly in package names.

pnpm/crates/cli/src/cli_args/outdated/render.rs

Tests (3) +156 / -5
tests.rsTest duplicate package preservation in Rust rendering +66/-3

Test duplicate package preservation in Rust rendering

• Adds unit coverage for duplicate package names across versions and dependency groups. Assertions verify qualified keys and backward-compatible keys for unique packages.

pnpm/crates/cli/src/cli_args/outdated/tests.rs

outdated.rsVerify recursive JSON behavior through the Rust CLI +58/-0

Verify recursive JSON behavior through the Rust CLI

• Adds an end-to-end workspace test with production and development dependencies on the same package. It verifies distinct keys, dependency types, and associated dependent projects.

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

recursive.tsUpdate pnpm v11 recursive JSON expectations +32/-2

Update pnpm v11 recursive JSON expectations

• Expands expected output to retain packages sharing names but differing by version or dependency type. The test now validates production, development, and multi-version composite keys.

pnpm11/deps/inspection/commands/test/outdated/recursive.ts

Documentation (1) +7 / -0
outdated-recursive-json-all-deps.mdDocument the complete recursive outdated JSON output +7/-0

Document the complete recursive outdated JSON output

• Adds patch release notes for pnpm, pacquet, and the dependency inspection commands package. The note explains that all distinct workspace dependencies are now included.

.changeset/outdated-recursive-json-all-deps.md

@greptile-apps

greptile-apps Bot commented Sep 23, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 4/5

The PR is not yet safe to merge because distinct aliases can still generate the same JSON key and silently overwrite one another.

Reviews (2) · Last reviewed commit: "style(outdated): declare getDependencyTy..."

@qodo-code-review

qodo-code-review Bot commented Sep 23, 2026 •

Copy link
Copy Markdown

Code Review by Qodo

🐞 Bugs (1) 📘 Rule violations (2) 🔗 Cross-repo conflicts (1) 📜 Skill insights (1)

Grey Divider


Action required

1. Repeated workflow actions still vanish ✗ Dismissed 🐞 Bug ≡ Correctness ⭐ New
Description
JsonKeys::new counts only the action records it receives, but to_outdated first collapses those
records in a map keyed solely by action name. When workflows pin the same action at multiple
outdated refs, only the last record reaches either recursive or non-recursive JSON rendering, so the
newly added disambiguation never preserves the earlier refs.
Code

pnpm/crates/cli/src/cli_args/outdated/render/json.rs[R18-20]

+        for pkg in packages {
+            *counts.entry(pkg.package_name.as_str()).or_default() += 1;
+        }
Relevance

●●● Strong

The upstream map drops duplicate action names before rendering, making the new duplicate-key logic
ineffective.

PR-#14639

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
Workflow discovery emits each owner/repository@ref reference separately and planning retains each
resolved reference, but to_outdated inserts results into a BTreeMap using only
plan.action.name, causing later refs to replace earlier ones. The changed renderer then counts
duplicates only in this already-collapsed slice, even though the PR explicitly adds key
disambiguation for repeated action names.

pnpm/crates/cli/src/cli_args/outdated/render/json.rs[16-20]
pnpm/crates/cli/src/cli_args/outdated/render/json.rs[38-43]
pnpm/crates/github-actions/src/lib.rs[363-382]
pnpm/crates/github-actions/src/workflow.rs[95-121]
pnpm/crates/cli/src/cli_args/outdated.rs[208-219]

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

## Issue description
Repeated GitHub Action references are collapsed by action name before the new JSON key generator receives them, so references pinned at different outdated versions are still omitted.

## Fix Focus Areas
- pnpm/crates/cli/src/cli_args/outdated/render/json.rs[16-20]
- pnpm/crates/github-actions/src/lib.rs[363-382]

## Recommended Fix
Change `to_outdated` to retain every outdated action record rather than inserting records into a `BTreeMap` keyed only by action name. Preserve deterministic ordering if required, then add a regression test with the same action pinned at two outdated versions and verify both records reach JSON rendering with disambiguated keys.

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


2. Uninstalled dependencies still vanish ✗ Dismissed 📜 Skill insight ≡ Correctness
Description
getOutdatedJSONKey and Rust's json_key fall back to only the package name and dependency type
when current is absent, while recursive aggregation also groups by that absent value. If workspace
projects request different versions of the same uninstalled dependency in the same dependency group,
one record is merged or overwritten, contradicting the changeset's promise that every such
dependency is included.
Code

pnpm11/deps/inspection/commands/src/outdated/outdated.ts[R464-467]

+  if (outdatedPkg.current) {
+    return `${outdatedPkg.packageName}@${outdatedPkg.current}${suffix}`
+  }
+  return `${outdatedPkg.packageName}${suffix}`
Relevance

●●● Strong

Omitting requested versions can still merge uninstalled dependencies, violating the stated
preservation objective.

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The changeset promises every outdated workspace dependency for different versions, but both
implementations omit the requested version from keys when current is absent and their recursive
collectors group on the same incomplete identity.

.changeset/outdated-recursive-json-all-deps.md[7-7]
pnpm11/deps/inspection/commands/src/outdated/outdated.ts[461-468]
pnpm11/deps/inspection/commands/src/outdated/recursive.ts[81-98]
pnpm/crates/cli/src/cli_args/outdated/render/json.rs[3-27]
pnpm/crates/cli/src/cli_args/outdated/workspace.rs[225-238]
Skill: review-code

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

## Issue description
Entries with the same package and dependency type still collide when `current` is absent, and recursive aggregation can merge them before JSON rendering.

## Fix Focus Areas
- pnpm11/deps/inspection/commands/src/outdated/outdated.ts[461-468]
- pnpm11/deps/inspection/commands/src/outdated/recursive.ts[81-98]
- pnpm/crates/cli/src/cli_args/outdated/render/json.rs[3-27]
- pnpm/crates/cli/src/cli_args/outdated/workspace.rs[225-238]

## Recommended Fix
Include a stable entry discriminator such as the wanted version or dependency alias whenever `current` cannot distinguish entries. Apply the same identity to recursive grouping and final JSON keys in both implementations, then add regressions with two uninstalled same-name dependencies from the same dependency group but different requested versions.

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


3. Version 11 drops aliased dependencies ✗ Dismissed 🐞 Bug ≡ Correctness
Description
getOutdatedJSONKey and json_key derive keys from the resolved package name, current version, and
dependency type while omitting the distinct alias and wanted fields retained by each
outdated-package record. When two aliases target the same real package at the same installed version
and dependency group, assignment to the JavaScript accumulator or Rust JSON map replaces the earlier
entry, affecting both recursive version 11 output and version 12 rendering.
Code

pnpm11/deps/inspection/commands/src/outdated/outdated.ts[R463-466]

+  const suffix = getDependencyTypeSuffix(outdatedPkg)
+  if (outdatedPkg.current) {
+    return `${outdatedPkg.packageName}@${outdatedPkg.current}${suffix}`
+  }
Relevance

●●● Strong

Omitting aliases can overwrite distinct dependencies, directly contradicting the PR’s preservation
goal.

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The collectors process each manifest dependency alias independently, normalize npm aliases to the
real registry package name, and retain both the alias and resolved package data in the
outdated-package record. The renderers then generate keys from the resolved package name without the
alias and insert each result into a single JSON object or map, where equal keys cause the later
value to replace the earlier one.

pnpm11/deps/inspection/outdated/src/outdated.ts[34-43]
pnpm11/deps/inspection/outdated/src/outdated.ts[116-130]
pnpm11/deps/inspection/outdated/src/outdated.ts[157-205]
pnpm11/deps/inspection/commands/src/outdated/outdated.ts[390-404]
pnpm11/deps/inspection/commands/src/outdated/outdated.ts[461-468]
pnpm/crates/cli/src/cli_args/outdated/query.rs[70-84]
pnpm/crates/cli/src/cli_args/outdated/query.rs[218-269]
pnpm/crates/cli/src/cli_args/outdated/render/json.rs[3-27]
pnpm/crates/cli/src/cli_args/outdated/render/json.rs[54-65]

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

## Issue description
Versions 11 and 12 overwrite distinct aliased dependencies when their generated package, current-version, and dependency-type keys are equal because the JSON keys omit the retained alias.

## Fix Focus Areas
- pnpm11/deps/inspection/commands/src/outdated/outdated.ts[385-404]
- pnpm11/deps/inspection/commands/src/outdated/outdated.ts[451-468]
- pnpm11/deps/inspection/commands/src/outdated/recursive.ts[84-91]
- pnpm/crates/cli/src/cli_args/outdated/render/json.rs[3-65]
- pnpm/crates/cli/src/cli_args/outdated/query.rs[70-84]

## Recommended Fix
Preserve the existing documented base key for non-colliding entries, but detect duplicate generated keys and append a deterministic alias discriminator before insertion. Ensure recursive grouping retains every field needed to distinguish entries before rendering, and add regression tests with two manifest aliases resolving to the same real package, current version, and dependency group.

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



Remediation recommended

4. Version 11 command wiring stays untested 📜 Skill insight ▣ Testability
Description
The updated TypeScript regression assertion calls outdated.handler directly rather than invoking
the pnpm v11 executable. Argument parsing, recursive dispatch, and JSON format propagation therefore
remain outside the regression coverage even though the changed behavior is CLI output.
Code

pnpm11/deps/inspection/commands/test/outdated/recursive.ts[167]

Relevance

●●● Strong

Explicit CLI-output compliance rule requires executable-path coverage; direct handler testing leaves
parsing and dispatch untested.

PR-#15073
PR-#14027

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
Compliance rule 3365266 requires a CLI output change to have at least one test invoking the real CLI
path. The changed expectation belongs to a test that imports outdated and calls outdated.handler
directly, so the pnpm v11 executable path is not exercised.

pnpm11/deps/inspection/commands/test/outdated/recursive.ts[3-6]
pnpm11/deps/inspection/commands/test/outdated/recursive.ts[153-167]
Skill: review-code

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 pnpm v11 regression test verifies the changed JSON through `outdated.handler` only, so it does not cover the real CLI wiring required for a CLI output change.

## Fix Focus Areas
- pnpm11/deps/inspection/commands/test/outdated/recursive.ts[153-230]

## Recommended Fix
Add an end-to-end pnpm v11 test that runs the actual CLI with `-r outdated --json` against the duplicate-package workspace fixture, then parse stdout and assert that both disambiguated entries and their dependency types are present.

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


5. A valid package name loses duplicates 🐞 Bug ≡ Correctness
Description
packageCounts is initialized as a normal object, so indexing it with constructor reads the
inherited Object constructor instead of an absent numeric count. For multiple outdated entries
bearing that valid package name, count calculation becomes nonnumeric, the disambiguation test
remains false, and repeated assignments overwrite all but one entry.
Code

pnpm11/deps/inspection/commands/src/outdated/outdated.ts[R386-388]

+  const packageCounts: Record<string, number> = {}
+  for (const pkg of outdatedPackages) {
+    packageCounts[pkg.packageName] = (packageCounts[pkg.packageName] ?? 0) + 1
Relevance

●●● Strong

Inherited object properties can corrupt counts for valid package names; this is a concrete
correctness bug.

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
Dependency names originate from manifest or lockfile keys and flow into packageName. Both changed
renderers count those names through inherited-property-aware ordinary objects, and the resulting
count controls whether the helper creates a distinct key.

pnpm11/deps/inspection/outdated/src/outdated.ts[116-123]
pnpm11/deps/inspection/outdated/src/outdated.ts[157-163]
pnpm11/deps/inspection/commands/src/outdated/outdated.ts[385-393]
pnpm11/deps/inspection/commands/src/outdated/recursive.ts[215-222]
pnpm11/deps/inspection/commands/src/outdated/outdated.ts[461-468]

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

## Issue description
Manifest-controlled package names inherited from `Object.prototype` corrupt the new duplicate counters and prevent key disambiguation.

## Fix Focus Areas
- pnpm11/deps/inspection/commands/src/outdated/outdated.ts[385-404]
- pnpm11/deps/inspection/commands/src/outdated/recursive.ts[215-231]

## Recommended Fix
Replace both package-count records with `Map<string, number>` or null-prototype objects, and use prototype-free JSON accumulators as well. Add regression coverage using multiple entries whose package name is `constructor`.

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


6. Peer labels change outside the JSON fix 📘 Rule violation ⚙ Maintainability
Description
render_package_name now appends (peer) for peer dependencies even though the defect and
regression tests concern JSON-map key collisions. The helper feeds list and table renderers, so
users of those formats receive an undocumented output change unrelated to the bug fix.
Code

pnpm/crates/cli/src/cli_args/outdated/render.rs[R238-239]

+        DependencyGroup::Peer => format!("{} {}", pkg.package_name, dimmed("(peer)")),
+        DependencyGroup::Prod => pkg.package_name.clone(),
Relevance

●●● Strong

Reviewer-visible output changes unrelated to the JSON fix are likely removed.

PR-#14639

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The changed match arm alters human-readable output, while duplicate preservation is implemented
separately in the new JSON renderer and does not depend on this branch.

Rule 2255067: Bug fix changes must not include unrelated refactors or reformatting
pnpm/crates/cli/src/cli_args/outdated/render.rs[231-240]
pnpm/crates/cli/src/cli_args/outdated/render/json.rs[97-119]

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 Rust renderer changes peer-dependency labels in human-readable list and table formats even though this PR fixes duplicate JSON keys.

## Fix Focus Areas
- pnpm/crates/cli/src/cli_args/outdated/render.rs[235-240]

## Recommended Fix
Restore the previous peer-dependency label behavior by returning the plain package name for both peer and production dependencies. Keep peer suffix handling only in the JSON-key helper where it is required for disambiguation.

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


View medium (2)
7. Suffix helper precedes its first use ✓ Resolved 📘 Rule violation ⚙ Maintainability
Description
getDependencyTypeSuffix is declared at line 451 before its first same-file call from
getOutdatedJSONKey at line 463. A later reader encounters the helper implementation before the
calling function, contrary to the required TypeScript declaration order.
Code

pnpm11/deps/inspection/commands/src/outdated/outdated.ts[451]

+export function getDependencyTypeSuffix (outdatedPkg: OutdatedItem): string {
Relevance

●● Moderate

Declaration order is a repository rule, but no closely matching acceptance precedent was found.

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The added declaration appears at line 451, and repository search shows its first call in the same
file at line 463.

Rule 713432: Declare TypeScript functions only after their first usage
pnpm11/deps/inspection/commands/src/outdated/outdated.ts[451-468]

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 newly added TypeScript suffix helper is declared before its first usage in the same file.

## Fix Focus Areas
- pnpm11/deps/inspection/commands/src/outdated/outdated.ts[451-468]

## Recommended Fix
Move `getDependencyTypeSuffix` below `getOutdatedJSONKey`. Function declaration hoisting keeps the call valid while placing each helper after its first same-file usage.

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


8. Users cannot predict JSON keys 🔗 Cross-repo conflict ⚙ Maintainability
Description
getOutdatedJSONKey and its Rust counterpart change package-name keys to conditional
name/version/type composites without a corresponding pnpm.io contract update. When a package has
multiple workspace entries, both pnpm 11 and 12 emit keys that the canonical current and versioned
command references do not explain.
Code

pnpm11/deps/inspection/commands/src/outdated/outdated.ts[R462-465]

+  if (!hasMultiple) return outdatedPkg.packageName
+  const suffix = getDependencyTypeSuffix(outdatedPkg)
+  if (outdatedPkg.current) {
+    return `${outdatedPkg.packageName}@${outdatedPkg.current}${suffix}`
Relevance

●● Moderate

Undocumented JSON key semantics are plausible, but contract expectations and reviewer behavior are
subjective.

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The PR introduces conditional composite keys in both supported implementations, while pnpm.io's
current and version 11 references only state that JSON is an available format and provide no schema
or key-generation rule.

pnpm11/deps/inspection/commands/src/outdated/outdated.ts[461-467]
pnpm/crates/cli/src/cli_args/outdated/render/json.rs[3-27]
External repo: pnpm/pnpm.io, docs/cli/outdated.md [34-39]
External repo: pnpm/pnpm.io, versioned_docs/version-11.x/cli/outdated.md [34-39]

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 public JSON output now uses composite keys for packages with multiple workspace entries, but pnpm.io only lists JSON as an available format and does not document how those keys are formed. Coordinate a pnpm.io update for both current and version 11 documentation, including the version and dependency-type suffix rules and an example.

## Fix Focus Areas
- pnpm11/deps/inspection/commands/src/outdated/outdated.ts[461-467]
- pnpm/crates/cli/src/cli_args/outdated/render/json.rs[3-27]
- /cross_repos/pnpm.io/docs/cli/outdated.md[34-39]
- /cross_repos/pnpm.io/versioned_docs/version-11.x/cli/outdated.md[34-39]

## Recommended Fix
Add a coordinated pnpm.io documentation change describing the JSON object schema: single entries retain the package-name key, while duplicate package entries use `package@current` plus the applicable dependency-type suffix. Include examples for production, development, optional, peer, and GitHub Action entries.

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



Informational

9. Version lines share one changeset 📘 Rule violation § Compliance ⭐ New
Description
The new changeset places the TypeScript pnpm targets and Rust pacquet target in the same front
matter. Because this bug fix changes both release lines, their package bumps and release notes
cannot be managed through independently targeted changeset files.
Code

.changeset/outdated-recursive-json-all-deps.md[R2-4]

+"@pnpm/deps.inspection.commands": patch
+"pnpm": patch
+"pacquet": patch
Relevance

● Weak

Recent same-rule precedents reject splitting coordinated pnpm and pacquet bumps into separate
changesets.

PR-#15459
PR-#15503
PR-#15564

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
Compliance rule 713436 requires separate changesets when one PR changes both the TypeScript v11 CLI
and Rust v12 CLI. The new changeset lists pnpm, its TypeScript command package, and pacquet
together instead.

Rule 713436: Changesets for pnpm v11 vs v12 (pacquet) must target the correct package and bump type
.changeset/outdated-recursive-json-all-deps.md[1-7]

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 shared changeset combines the pnpm v11 TypeScript packages and the pnpm v12 Rust package, although cross-stack CLI changes must use separate changeset files targeting their respective release lines.

## Fix Focus Areas
- .changeset/outdated-recursive-json-all-deps.md[1-7]

## Recommended Fix
Keep the existing user-visible description, but split it into two changeset files. Target `@pnpm/deps.inspection.commands` and `pnpm` with patch bumps in the v11 changeset, and target only `pacquet` with a patch bump in the v12 changeset.

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


Grey Divider

Context sources
✅ Compliance rules (platform): 64 rules
✅ Skills: review-code
✅ Cross-repo context — repo relationships
  Explored: repo: pnpm/pnpm.io (sha: e3bc12c9) — View relationship
  Explored: repo: pnpm/ramda (sha: 50c6b571) — View relationship
Review mode: ⚖️ Balanced: Downgraded extended -> standard: change is below the extended eligibility bar (hunks 17/18, lines 399/200; both must reach the floor). Router rationale: This changes JSON keying across independent TypeScript and Rust CLI paths, with multiple subtle collision and compatibility risks requiring redundant review passes.

Grey Divider

Tip of the day
💡 Did you know, you can choose which labels appear on a finding, and whether they show icons or text

More tips ↗ | Customize Qodo ↗ | Qodo docs ↗

Grey Divider

Previous reviews

Review updated until commit 629eb94

Results up to commit 165e4ea ⚖️ Balanced


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


Action required
1. Version 11 drops aliased dependencies ✗ Dismissed 🐞 Bug ≡ Correctness
Description
getOutdatedJSONKey and json_key derive keys from the resolved package name, current version, and
dependency type while omitting the distinct alias and wanted fields retained by each
outdated-package record. When two aliases target the same real package at the same installed version
and dependency group, assignment to the JavaScript accumulator or Rust JSON map replaces the earlier
entry, affecting both recursive version 11 output and version 12 rendering.
Code

pnpm11/deps/inspection/commands/src/outdated/outdated.ts[R463-466]

+  const suffix = getDependencyTypeSuffix(outdatedPkg)
+  if (outdatedPkg.current) {
+    return `${outdatedPkg.packageName}@${outdatedPkg.current}${suffix}`
+  }
Relevance

●●● Strong

Omitting aliases can overwrite distinct dependencies, directly contradicting the PR’s preservation
goal.

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The collectors process each manifest dependency alias independently, normalize npm aliases to the
real registry package name, and retain both the alias and resolved package data in the
outdated-package record. The renderers then generate keys from the resolved package name without the
alias and insert each result into a single JSON object or map, where equal keys cause the later
value to replace the earlier one.

pnpm11/deps/inspection/outdated/src/outdated.ts[34-43]
pnpm11/deps/inspection/outdated/src/outdated.ts[116-130]
pnpm11/deps/inspection/outdated/src/outdated.ts[157-205]
pnpm11/deps/inspection/commands/src/outdated/outdated.ts[390-404]
pnpm11/deps/inspection/commands/src/outdated/outdated.ts[461-468]
pnpm/crates/cli/src/cli_args/outdated/query.rs[70-84]
pnpm/crates/cli/src/cli_args/outdated/query.rs[218-269]
pnpm/crates/cli/src/cli_args/outdated/render/json.rs[3-27]
pnpm/crates/cli/src/cli_args/outdated/render/json.rs[54-65]

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

## Issue description
Versions 11 and 12 overwrite distinct aliased dependencies when their generated package, current-version, and dependency-type keys are equal because the JSON keys omit the retained alias.

## Fix Focus Areas
- pnpm11/deps/inspection/commands/src/outdated/outdated.ts[385-404]
- pnpm11/deps/inspection/commands/src/outdated/outdated.ts[451-468]
- pnpm11/deps/inspection/commands/src/outdated/recursive.ts[84-91]
- pnpm/crates/cli/src/cli_args/outdated/render/json.rs[3-65]
- pnpm/crates/cli/src/cli_args/outdated/query.rs[70-84]

## Recommended Fix
Preserve the existing documented base key for non-colliding entries, but detect duplicate generated keys and append a deterministic alias discriminator before insertion. Ensure recursive grouping retains every field needed to distinguish entries before rendering, and add regression tests with two manifest aliases resolving to the same real package, current version, and dependency group.

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


2. Uninstalled dependencies still vanish ✗ Dismissed 📜 Skill insight ≡ Correctness
Description
getOutdatedJSONKey and Rust's json_key fall back to only the package name and dependency type
when current is absent, while recursive aggregation also groups by that absent value. If workspace
projects request different versions of the same uninstalled dependency in the same dependency group,
one record is merged or overwritten, contradicting the changeset's promise that every such
dependency is included.
Code

pnpm11/deps/inspection/commands/src/outdated/outdated.ts[R464-467]

+  if (outdatedPkg.current) {
+    return `${outdatedPkg.packageName}@${outdatedPkg.current}${suffix}`
+  }
+  return `${outdatedPkg.packageName}${suffix}`
Relevance

●●● Strong

Omitting requested versions can still merge uninstalled dependencies, violating the stated
preservation objective.

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The changeset promises every outdated workspace dependency for different versions, but both
implementations omit the requested version from keys when current is absent and their recursive
collectors group on the same incomplete identity.

.changeset/outdated-recursive-json-all-deps.md[7-7]
pnpm11/deps/inspection/commands/src/outdated/outdated.ts[461-468]
pnpm11/deps/inspection/commands/src/outdated/recursive.ts[81-98]
pnpm/crates/cli/src/cli_args/outdated/render/json.rs[3-27]
pnpm/crates/cli/src/cli_args/outdated/workspace.rs[225-238]
Skill: review-code

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

## Issue description
Entries with the same package and dependency type still collide when `current` is absent, and recursive aggregation can merge them before JSON rendering.

## Fix Focus Areas
- pnpm11/deps/inspection/commands/src/outdated/outdated.ts[461-468]
- pnpm11/deps/inspection/commands/src/outdated/recursive.ts[81-98]
- pnpm/crates/cli/src/cli_args/outdated/render/json.rs[3-27]
- pnpm/crates/cli/src/cli_args/outdated/workspace.rs[225-238]

## Recommended Fix
Include a stable entry discriminator such as the wanted version or dependency alias whenever `current` cannot distinguish entries. Apply the same identity to recursive grouping and final JSON keys in both implementations, then add regressions with two uninstalled same-name dependencies from the same dependency group but different requested versions.

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



Remediation recommended
3. Peer labels change outside the JSON fix 📘 Rule violation ⚙ Maintainability
Description
render_package_name now appends (peer) for peer dependencies even though the defect and
regression tests concern JSON-map key collisions. The helper feeds list and table renderers, so
users of those formats receive an undocumented output change unrelated to the bug fix.
Code

pnpm/crates/cli/src/cli_args/outdated/render.rs[R238-239]

+        DependencyGroup::Peer => format!("{} {}", pkg.package_name, dimmed("(peer)")),
+        DependencyGroup::Prod => pkg.package_name.clone(),
Relevance

●●● Strong

Reviewer-visible output changes unrelated to the JSON fix are likely removed.

PR-#14639

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The changed match arm alters human-readable output, while duplicate preservation is implemented
separately in the new JSON renderer and does not depend on this branch.

Rule 2255067: Bug fix changes must not include unrelated refactors or reformatting
pnpm/crates/cli/src/cli_args/outdated/render.rs[231-240]
pnpm/crates/cli/src/cli_args/outdated/render/json.rs[97-119]

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 Rust renderer changes peer-dependency labels in human-readable list and table formats even though this PR fixes duplicate JSON keys.

## Fix Focus Areas
- pnpm/crates/cli/src/cli_args/outdated/render.rs[235-240]

## Recommended Fix
Restore the previous peer-dependency label behavior by returning the plain package name for both peer and production dependencies. Keep peer suffix handling only in the JSON-key helper where it is required for disambiguation.

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


4. A valid package name loses duplicates 🐞 Bug ≡ Correctness
Description
packageCounts is initialized as a normal object, so indexing it with constructor reads the
inherited Object constructor instead of an absent numeric count. For multiple outdated entries
bearing that valid package name, count calculation becomes nonnumeric, the disambiguation test
remains false, and repeated assignments overwrite all but one entry.
Code

pnpm11/deps/inspection/commands/src/outdated/outdated.ts[R386-388]

+  const packageCounts: Record<string, number> = {}
+  for (const pkg of outdatedPackages) {
+    packageCounts[pkg.packageName] = (packageCounts[pkg.packageName] ?? 0) + 1
Relevance

●●● Strong

Inherited object properties can corrupt counts for valid package names; this is a concrete
correctness bug.

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
Dependency names originate from manifest or lockfile keys and flow into packageName. Both changed
renderers count those names through inherited-property-aware ordinary objects, and the resulting
count controls whether the helper creates a distinct key.

pnpm11/deps/inspection/outdated/src/outdated.ts[116-123]
pnpm11/deps/inspection/outdated/src/outdated.ts[157-163]
pnpm11/deps/inspection/commands/src/outdated/outdated.ts[385-393]
pnpm11/deps/inspection/commands/src/outdated/recursive.ts[215-222]
pnpm11/deps/inspection/commands/src/outdated/outdated.ts[461-468]

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

## Issue description
Manifest-controlled package names inherited from `Object.prototype` corrupt the new duplicate counters and prevent key disambiguation.

## Fix Focus Areas
- pnpm11/deps/inspection/commands/src/outdated/outdated.ts[385-404]
- pnpm11/deps/inspection/commands/src/outdated/recursive.ts[215-231]

## Recommended Fix
Replace both package-count records with `Map<string, number>` or null-prototype objects, and use prototype-free JSON accumulators as well. Add regression coverage using multiple entries whose package name is `constructor`.

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


5. Users cannot predict JSON keys 🔗 Cross-repo conflict ⚙ Maintainability
Description
getOutdatedJSONKey and its Rust counterpart change package-name keys to conditional
name/version/type composites without a corresponding pnpm.io contract update. When a package has
multiple workspace entries, both pnpm 11 and 12 emit keys that the canonical current and versioned
command references do not explain.
Code

pnpm11/deps/inspection/commands/src/outdated/outdated.ts[R462-465]

+  if (!hasMultiple) return outdatedPkg.packageName
+  const suffix = getDependencyTypeSuffix(outdatedPkg)
+  if (outdatedPkg.current) {
+    return `${outdatedPkg.packageName}@${outdatedPkg.current}${suffix}`
Relevance

●● Moderate

Undocumented JSON key semantics are plausible, but contract expectations and reviewer behavior are
subjective.

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The PR introduces conditional composite keys in both supported implementations, while pnpm.io's
current and version 11 references only state that JSON is an available format and provide no schema
or key-generation rule.

pnpm11/deps/inspection/commands/src/outdated/outdated.ts[461-467]
pnpm/crates/cli/src/cli_args/outdated/render/json.rs[3-27]
External repo: pnpm/pnpm.io, docs/cli/outdated.md [34-39]
External repo: pnpm/pnpm.io, versioned_docs/version-11.x/cli/outdated.md [34-39]

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 public JSON output now uses composite keys for packages with multiple workspace entries, but pnpm.io only lists JSON as an available format and does not document how those keys are formed. Coordinate a pnpm.io update for both current and version 11 documentation, including the version and dependency-type suffix rules and an example.

## Fix Focus Areas
- pnpm11/deps/inspection/commands/src/outdated/outdated.ts[461-467]
- pnpm/crates/cli/src/cli_args/outdated/render/json.rs[3-27]
- /cross_repos/pnpm.io/docs/cli/outdated.md[34-39]
- /cross_repos/pnpm.io/versioned_docs/version-11.x/cli/outdated.md[34-39]

## Recommended Fix
Add a coordinated pnpm.io documentation change describing the JSON object schema: single entries retain the package-name key, while duplicate package entries use `package@current` plus the applicable dependency-type suffix. Include examples for production, development, optional, peer, and GitHub Action entries.

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


View medium (1)
6. Suffix helper precedes its first use ✓ Resolved 📘 Rule violation ⚙ Maintainability
Description
getDependencyTypeSuffix is declared at line 451 before its first same-file call from
getOutdatedJSONKey at line 463. A later reader encounters the helper implementation before the
calling function, contrary to the required TypeScript declaration order.
Code

pnpm11/deps/inspection/commands/src/outdated/outdated.ts[451]

+export function getDependencyTypeSuffix (outdatedPkg: OutdatedItem): string {
Relevance

●● Moderate

Declaration order is a repository rule, but no closely matching acceptance precedent was found.

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The added declaration appears at line 451, and repository search shows its first call in the same
file at line 463.

Rule 713432: Declare TypeScript functions only after their first usage
pnpm11/deps/inspection/commands/src/outdated/outdated.ts[451-468]

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 newly added TypeScript suffix helper is declared before its first usage in the same file.

## Fix Focus Areas
- pnpm11/deps/inspection/commands/src/outdated/outdated.ts[451-468]

## Recommended Fix
Move `getDependencyTypeSuffix` below `getOutdatedJSONKey`. Function declaration hoisting keeps the call valid while placing each helper after its first same-file usage.

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


Results up to commit d51ffce 🧠 Deep


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


Remediation recommended
1. Version 11 command wiring stays untested 📜 Skill insight ▣ Testability
Description
The updated TypeScript regression assertion calls outdated.handler directly rather than invoking
the pnpm v11 executable. Argument parsing, recursive dispatch, and JSON format propagation therefore
remain outside the regression coverage even though the changed behavior is CLI output.
Code

pnpm11/deps/inspection/commands/test/outdated/recursive.ts[167]

Relevance

●●● Strong

Explicit CLI-output compliance rule requires executable-path coverage; direct handler testing leaves
parsing and dispatch untested.

PR-#15073
PR-#14027

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
Compliance rule 3365266 requires a CLI output change to have at least one test invoking the real CLI
path. The changed expectation belongs to a test that imports outdated and calls outdated.handler
directly, so the pnpm v11 executable path is not exercised.

pnpm11/deps/inspection/commands/test/outdated/recursive.ts[3-6]
pnpm11/deps/inspection/commands/test/outdated/recursive.ts[153-167]
Skill: review-code

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 pnpm v11 regression test verifies the changed JSON through `outdated.handler` only, so it does not cover the real CLI wiring required for a CLI output change.

## Fix Focus Areas
- pnpm11/deps/inspection/commands/test/outdated/recursive.ts[153-230]

## Recommended Fix
Add an end-to-end pnpm v11 test that runs the actual CLI with `-r outdated --json` against the duplicate-package workspace fixture, then parse stdout and assert that both disambiguated entries and their dependency types are present.

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


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.

@qodo-code-review

Copy link
Copy Markdown

Code review by qodo was updated up to the latest commit d51ffce

@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.

zkochan and others added 4 commits September 24, 2026 19:27
…json output (#7693)

When multiple workspace packages depend on different versions or dependency
types of the same package, `pnpm -r outdated --json` previously overwrote
earlier entries keyed solely by package name.

Key entries uniquely as `${packageName}@${current}${typeSuffix}` when a
package has multiple outdated entries across the workspace. Distinct
dependencies are now preserved in both TypeScript and Rust CLI
implementations.

Fixes #7693
… JSON keys

The JSON key helper repeated the table's dependency-type switch in both
stacks. Derive both from one label function, build the key getter once
per report instead of counting names at each call site, and drop the
Rust branch for an empty current version, which a semver Version cannot
have. The changeset now names the key format consumers will see.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
@qodo-code-review

Copy link
Copy Markdown

Code review by qodo was updated up to the latest commit 629eb94

@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.

@zkochan

zkochan commented Sep 24, 2026

Copy link
Copy Markdown
Member Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor
⚠️ Action not completed

Review rate limited.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@zkochan

zkochan commented Sep 24, 2026

Copy link
Copy Markdown
Member Author

Review-and-fix pass on head 629eb94 (rebased onto main, no conflicts).

Changes pushed:

  • efcff0f: the JSON key's dependency-type suffix now comes from the same label function the table uses, in both stacks. Before this, each stack had two copies of that switch. The name-count bookkeeping now lives in one key getter per report instead of being repeated at each call site. The Rust key has no branch for an empty current anymore, because a semver Version is never empty. The changeset now shows the key format consumers will see ([email protected] (dev)).
  • 629eb94: collapsed the JSON renderer's super imports, as dylint requires.

Validation: pnpm test:rust -p pnpm-cli -E 'test(outdated)' passed 48 of 48. The @pnpm/deps.inspection.commands jest suite test/outdated passed 33 of 33. tsgo --build, eslint, and dylint on pnpm-cli are clean. CI on 629eb94 is green: 64 passed, 2 skipped.

Review status:

The PR stays ready for review. Nothing is left in scope except the missing Greptile and CodeRabbit rounds on the current head.


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

@zkochan
zkochan merged commit 22ad270 into main Sep 24, 2026
67 checks passed
@zkochan
zkochan deleted the fix-7693 branch September 24, 2026 18:54
u9g pushed a commit to u9g/pnpm that referenced this pull request Sep 25, 2026
…json output (pnpm#7693) (pnpm#15418)

When multiple workspace packages depend on different versions or dependency
types of the same package, `pnpm -r outdated --json` previously overwrote
earlier entries keyed solely by package name.

Key entries uniquely as `${packageName}@${current}${typeSuffix}` when a
package has multiple outdated entries across the workspace. Distinct
dependencies are now preserved in both TypeScript and Rust CLI
implementations.

Closes pnpm#7693
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

pnpm outdated [-r] --json does not return all dependencies in workspace

2 participants