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] Cannot apply hunk #1 #886

Closed
dzintars opened this issue Feb 3, 2020 · 3 comments
Closed

[Bug] Cannot apply hunk #1 #886

dzintars opened this issue Feb 3, 2020 · 3 comments
Labels
bug Something isn't working

Comments

@dzintars
Copy link

dzintars commented Feb 3, 2020

Describe the bug

I see several required packages failing to install. There is one of them. Not sure how should i address this issue.

To Reproduce

Remove Yarn 1

sudo dnf remove yarn

Install Yarn 2

sudo npm install -g yarn@berry

Init project

mkdir yarn2-test && cd yarn2-test
yarn init                                     
{
  name: 'yarn2-test'
}

Install packages

yarn add -D rollup                            
➤ YN0000: ┌ Resolution step
➤ YN0000: └ Completed in 0.59s
➤ YN0000: ┌ Fetch step
➤ YN0000: └ Completed in 0.06s
➤ YN0000: ┌ Link step
➤ YN0000: └ Completed in 0.04s
➤ YN0000: Done in 0.69s
yarn add -D rollup-plugin-minify-html-literals
➤ YN0000: ┌ Resolution step
➤ YN0002: │ yarn2-test@workspace:. doesn't provide rollup@^0.65.2 || ^1.0.0 requested by rollup-plugin-minify-html-literals@npm:1.2.2
➤ YN0000: └ Completed in 1.95s
➤ YN0000: ┌ Fetch step
➤ YN0013: │ typescript@patch:typescript@npm%3A2.9.2#builtin<compat/typescript>::version=2.9.2&hash=226bd1 can't be found in the cache and will be fetched from the disk
➤ YN0001: │ Error: typescript@patch:typescript@npm%3A2.9.2#builtin<compat/typescript>::version=2.9.2&hash=226bd1: Cannot apply hunk #1
    at c (/usr/local/lib/node_modules/yarn/bin/yarn.js:58:888149)
    at processTicksAndRejections (internal/process/task_queues.js:94:5)
    at async /usr/local/lib/node_modules/yarn/bin/yarn.js:58:890280
    at async o (/usr/local/lib/node_modules/yarn/bin/yarn.js:58:887432)
    at async Object.t.applyPatchFile (/usr/local/lib/node_modules/yarn/bin/yarn.js:58:890253)
    at async t.PatchFetcher.patchPackage (/usr/local/lib/node_modules/yarn/bin/yarn.js:58:887187)
    at async /usr/local/lib/node_modules/yarn/bin/yarn.js:58:886444
    at async /usr/local/lib/node_modules/yarn/bin/yarn.js:36:569449
    at async /usr/local/lib/node_modules/yarn/bin/yarn.js:36:569392
    at async /usr/local/lib/node_modules/yarn/bin/yarn.js:36:570734
➤ YN0000: └ Completed in 7.89s
➤ YN0000: Failed with errors in 9.84s

Environment if relevant (please complete the following information):

  • OS: [Linux (Fedora 31)]
  • Node version [v12.14.1]
  • Yarn version [2.0.0-rc.27]
@TareqElMasriDev
Copy link

I have the same issue

@arcanis
Copy link
Member

arcanis commented Feb 3, 2020

Duplicate of #719 - the fix is in master 🙂

@AArnott
Copy link

AArnott commented Mar 1, 2021

@arcanis I can confirm that master fixes it. But when will yarn set version latest include the fix so we don't have to take whatever happens to be at the tip of master?

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

No branches or pull requests

4 participants