Open RodrigoTomeES opened 1 year ago
It seems to be an issue with the node version. With Node 16 did not have the problem.
I also tried it in node 19 and it also throw the error, maybe is it broken for node > v16?
I am having this problem too while patching anything in a yarn project. I see the same output buffer hex:
<Buffer 1b 5b 33 31 6d 1b 5b 31 6d 55 6e 6b 6e 6f 77 6e 20 53 79 6e 74 61 78 20 45 72 72 6f 72 1b 5b 32 32 6d 1b 5b 33 39 6d 3a 20 55 6e 73 75 70 70 6f 72 74 ... 142 more bytes>,
Stepping through the patch-package code I was able to get the whole error when it tries to spawn yarn install --ignore-engines --ignore-scripts
:
Syntax Error[22m[39m: Unsupported option name ("--ignore-scripts").
$ yarn install [--json] [--immutable] [--immutable-cache] [--check-cache] [--inline-builds] [--mode #0]
I'm also seeing the error below when it does yarn install --ignore-engines
:
�� YN0050: The --ignore-engines option is deprecated; engine checking isn't a core feature anymore
I am on Node v16.19.1 and yarn 3.3.0 (although it uses yarn 3.4.1 in the temp folder that is created)
Edit: In my case I got it working by downgrading my globally installed yarn from 3.4.1 to 1.22.19
When trying to patch this package it gives an error