Skip to content

turbo prune doesn't understand yarn catalog: #11113

@nickretallack

Description

@nickretallack

Verify canary release

  • I verified that the issue exists in the latest Turborepo canary release.

Link to code that reproduces this issue

https://github.com/nickretallack/turbo-catalogs/tree/main

Which canary version will you have in your reproduction?

2.6.1-canary.3

Environment information

turbo 2.6.1

CLI:
   Version: 2.6.1
   Path to executable: /Users/nicholas.retallack/experiments/turbo-catalogs/node_modules/turbo-darwin-arm64/bin/turbo
   Daemon status: Not running
   Package manager: berry

Platform:
   Architecture: aarch64
   Operating system: macos
   WSL: false
   Available memory (MB): 18144
   Available CPU cores: 14

Environment:
   CI: None
   Terminal (TERM): xterm-256color
   Terminal program (TERM_PROGRAM): vscode
   Terminal program version (TERM_PROGRAM_VERSION): 2.0.69
   Shell (SHELL): /bin/zsh
   stdin: false

Expected behavior

When you run turbo prune and it encounters catalog: in package.json in a yarn workspace it should consult .yarnrc.yml for the catalog versions. https://yarnpkg.com/features/catalogs

Actual behavior

It prints something like this:

  × Unable to find any locator for lodash@catalog:

To Reproduce

  1. Create a turbo project with yarn
  2. Upgrade to [email protected]
  3. Turn any * dependencies into workspace:* (perhaps that is another bug, that it generates a project this way even when you select yarn.
  4. Add a dependency using the yarn catalog feature
  5. Install
  6. Run turbo prune on a package
yarn
yarn turbo prune app-a

Additional context

This is a new yarn feature that was added last week. I already posted this as a feature request #11110 but I figured perhaps I should track it as a bug instead because it doesn't require any design since it should work exactly the same way it does in pnpm, and because it's currently breaking my build, preventing me from using turbo prune, so I hope it gets fixed soon.

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind: bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions