Skip to content

pnpm 11.15.1 PNPR: catalog: in overrides fails with "No catalog entry … for catalog 'default'" despite entry existing #13232

Closed

Description

@hckhanh

pnpm version

11.15.1 (fails)

Works on 11.2.2 with the same workspace config.

Observed via

Vite+ (vp install) which invokes the packageManager-pinned pnpm. Failure is inside pnpm itself (resolveViaPnprServer), not in Vite+ application code.

Log line immediately before the error:

Resolving dependencies via the pnpr server

Code to reproduce the issue

Minimal pnpm-workspace.yaml:

packages:
  - 'packages/*'

catalog:
  '@tanstack/store': 0.11.0

overrides:
  '@tanstack/store': 'catalog:'

Root package.json:

{
  "name": "repro-root",
  "private": true,
  "packageManager": "[email protected]"
}

packages/a/package.json:

{
  "name": "a",
  "private": true,
  "dependencies": {
    "@tanstack/store": "catalog:"
  }
}

Then:

pnpm install

(In our CI this is triggered as vp install after bumping packageManager from [email protected] → [email protected].)

Expected behavior

Install succeeds. The default catalog defines @tanstack/store, and using catalog: in overrides is documented / catalogs.

Actual behavior

Scope: all 7 workspace projects
Resolving dependencies via the pnpr server
[ERROR] resolution failed: Could not resolve a catalog in the overrides: No catalog entry '@tanstack/store' was found for catalog 'default'.

pnpm: resolution failed: Could not resolve a catalog in the overrides: No catalog entry '@tanstack/store' was found for catalog 'default'.
    at resolveViaPnprServer (.../pnpm/11.15.1/pnpm/dist/pnpm.mjs:190949:11)
    at process.processTicksAndRejections (node:internal/process/task_queues:104:5)

The catalog entry is present in pnpm-workspace.yaml (and duplicated under package.json → workspaces.catalog by our toolchain sync). The same tree installs cleanly on pnpm 11.2.2.

Additional context

Happy to provide a reduced fixture repo or more logs if useful.

Activity

  1. github-actions commented on Jul 23, 2026

    @github-actions
    Contributor

    Oz triage is running now and will classify this issue and apply one pnpm state: label.

    Follow along in Oz: https://app.warp.dev/session/019f8ed3-5ca4-77d1-999d-f8ace97b0ea8

  2. added
    state: accepted
    on Jul 23, 2026
  3. github-actions commented on Jul 23, 2026

    @github-actions
    Contributor

    Triage result

    State: Ready to implement → state: accepted

    Root cause identified. The bug is in pnpm11/installing/deps-installer/src/install/index.ts at line 2697, inside installViaPnprServer:

    overrides: opts.overrides,

    opts.overrides holds the raw override map — values are the literal strings from pnpm-workspace.yaml, e.g. '@tanstack/store': 'catalog:'. These raw values are sent to the pnpr server as-is. The pnpr server (Rust/pacquet) tries to resolve catalog: references in overrides via parse_overrides, but the workspace catalog definitions are never included in the request body — so resolution fails with "No catalog entry '@tanstack/store' was found for catalog 'default'."

    Fix

    Pre-resolve catalog references before sending overrides to the pnpr server. Both utilities are already imported in the file:

    // Before (line 2697):
    overrides: opts.overrides,
    
    // After:
    overrides: createOverridesMapFromParsed(parseOverrides(opts.overrides ?? {}, opts.catalogs ?? {})),

    parseOverrides resolves any catalog: specifiers against opts.catalogs (the workspace catalog map). createOverridesMapFromParsed converts the result back to the Record<string, string> the pnpr wire protocol expects. No protocol changes to the pnpr server are needed — it already handles resolved specifiers correctly.

    Scope

    • Product affected: TypeScript pnpm CLI (pnpm11/ path)
    • No pacquet parity needed: This code is specific to the pnpr server client path, which the Rust pacquet port does not use
    • No protocol changes needed: The pnpr server already accepts and handles fully-resolved override values

    Test coverage

    A regression test should be added to pnpm11/installing/deps-installer/test/install/pnprWorkspaceMetadata.ts verifying that a catalog: specifier in overrides is resolved to its version string before reaching resolveViaPnprServer (using the existing mock).


    Written by an agent (Oz, auto).

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: catalogsproduct: pnpm@11regressionstate: acceptedtype: bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions