Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: yarn create doesn't work with @scope #4626

Closed
1 task
alan-agius4 opened this issue Jul 15, 2022 · 4 comments · Fixed by #4627
Closed
1 task

[Bug]: yarn create doesn't work with @scope #4626

alan-agius4 opened this issue Jul 15, 2022 · 4 comments · Fixed by #4627
Labels
bug Something isn't working

Comments

@alan-agius4
Copy link

Self-service

  • I'd be willing to implement a fix

Describe the bug

When using yarn create the version specifier doesn't work when the package is scoped. Example yarn create @angular@next.

 YN0000: ┌ Resolution step
➤ YN0001: │ Error: create-@angular@next isn't supported by any available resolver
    at Bd.getResolverByDescriptor (/.node/corepack/yarn/3.2.1/yarn.js:396:1664)
    at Bd.bindDescriptor (/.node/corepack/yarn/3.2.1/yarn.js:396:1053)
    at ee (/.node/corepack/yarn/3.2.1/yarn.js:442:6954)

To reproduce

yarn create @angular@next

Environment

System:
    OS: Linux 5.17 Debian GNU/Linux rodete 12 (rodete)
    CPU: (48) x64 AMD EPYC 7B12
  Binaries:
    Node: 16.15.1 - /tmp/xfs-cbdcc8f4/node
    Yarn: 3.2.1 - /tmp/xfs-cbdcc8f4/yarn
    npm: 8.11.0 - ~/.nvm/versions/node/v16.15.1/bin/npm

Additional context

No response

@alan-agius4 alan-agius4 added the bug Something isn't working label Jul 15, 2022
@merceyz

This comment was marked as outdated.

@merceyz merceyz closed this as not planned Won't fix, can't repro, duplicate, stale Jul 15, 2022
@alan-agius4

This comment was marked as outdated.

@alan-agius4 alan-agius4 changed the title [Bug]: version specifier doesn't work with scoped packages in yarn create [Bug]: version specifier doesn't work with scoped packages in yarn create Jul 15, 2022
@merceyz merceyz changed the title [Bug]: version specifier doesn't work with scoped packages in yarn create [Bug]: yarn create doesn't work with @scope Jul 15, 2022
@merceyz
Copy link
Member

merceyz commented Jul 15, 2022

I see npm documents

npm init <@scope> (same as `npx <@scope>/create`)

so I'll add support for that as well.

Though note it doesn't actually work with npm

$ npm init @angular@next
npm ERR! code EINVALIDPACKAGENAME
npm ERR! Invalid package name "@angular" of package "@angular@next/create": name can only contain URL-friendly characters.

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2022-07-15T16_07_31_388Z-debug-0.log

@merceyz merceyz reopened this Jul 15, 2022
@alan-agius4
Copy link
Author

@merceyz, yeah I am aware of that. I have a separate issue for that npm/cli#5175

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants