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 cannot resolve patch:xxx including __archiveUrl #6617

Open
indooorsman opened this issue Nov 27, 2024 · 1 comment
Open

[Bug?]: yarn cannot resolve patch:xxx including __archiveUrl #6617

indooorsman opened this issue Nov 27, 2024 · 1 comment

Comments

@indooorsman
Copy link
Contributor

indooorsman commented Nov 27, 2024

Tarball urls that aren't conventional can't be reconstructed from package name + version alone, so instead we must hardcode them inside their locator's references as a special parameter, ie __archiveUrl. Otherwise we wouldn't be able to know where to download the package's tarball from.

I see, but it seems the patch: url is not compatible with __archiveUrl:

// package.json
"resolutions": {
  "@biz-ui-lib/data-grid@npm:^4.0.16": "patch:@biz-ui-lib/data-grid@npm%3A4.0.16%3A%3A__archiveUrl=https%253A%252F%252Farti-cache.my-company.com%253A443%252Fapi%252Fnpm%252Ffw-npm%252F%2540biz-ui-lib%252Fdata-grid%252F-%252F%2540biz-ui-lib%252Fdata-grid-4.0.16.tgz#~/.yarn/patches/@biz-ui-lib-data-grid-npm-4.0.16-38705fc550.patch"
}

run yarn install failed:

➤ YN0000: · Yarn 4.5.1
➤ YN0000: ┌ Resolution step
➤ YN0001: │ Error: @biz-ui-lib/data-grid@npm:4.0.16::__archiveUrl=https%3A%2F%2Farti-cache.my-company.com%3A443%2Fapi%2Fnpm%2Ffw-npm%2F%40biz-ui-lib%2Fdata-grid%2F-%2F%40biz-ui-lib%2Fdata-grid-4.0.16.tgz 
isn't supported by any available resolver

Originally posted by @indooorsman in #6616 (comment)

@indooorsman
Copy link
Contributor Author

@arcanis F.Y.I.

@indooorsman indooorsman changed the title yarn cannot resolve patch:xxx including __archiveUrl [Bug] yarn cannot resolve patch:xxx including __archiveUrl Nov 27, 2024
@indooorsman indooorsman changed the title [Bug] yarn cannot resolve patch:xxx including __archiveUrl [Bug?]: yarn cannot resolve patch:xxx including __archiveUrl Nov 27, 2024
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

No branches or pull requests

1 participant