berry icon indicating copy to clipboard operation
berry copied to clipboard

[Bug?]: Running `yarn explain peer-requirements` results in error: "Not enough positional arguments."

Open dclowd9901 opened this issue 1 year ago • 2 comments

Self-service

  • [x] I'd be willing to implement a fix

Describe the bug

According to yarn docs: https://yarnpkg.com/cli/explain/peer-requirements

Screenshot 2024-07-18 at 11 28 12 AM

However, when trying to run this command, we see this error:

$ yarn explain peer-requirements
Unknown Syntax Error: Not enough positional arguments.

$ yarn explain peer-requirements <hash>

To reproduce

  1. Install Yarn 4.3.1
  2. Initialize a package
  3. Run command yarn explain peer-dependencies

Environment

System:
  OS: MacOS Sonoma 14.5
  CPU: Apple M1 Max
Binaries:
  Node: 20.13.1
  Yarn: 4.3.1
  npm: 10.5.2

Additional context

No response

dclowd9901 avatar Jul 18 '24 18:07 dclowd9901

Looking at the source, it's possible this is an issue with Clipanion. Digging in a bit more.

dclowd9901 avatar Jul 18 '24 20:07 dclowd9901

OK, it looks like upgrading clipanion to 4.0.0-rc.3 fixes this issue. Is there already work started on this? I could open a PR...

dclowd9901 avatar Jul 18 '24 22:07 dclowd9901