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

Failed to apply patch for package react-native-agora #504

Open
Khubaib-Sarfraz opened this issue Dec 15, 2023 · 3 comments
Open

Failed to apply patch for package react-native-agora #504

Khubaib-Sarfraz opened this issue Dec 15, 2023 · 3 comments

Comments

@Khubaib-Sarfraz
Copy link

Im using [email protected] and because of some issue in in agora i used [email protected]

so i'm getting this issue only with 'yarn' not with the npm another solution with for this issue is to deprecate the patch-package to 7.0.2

the point where this error occurs is that when i try to install a new library in my project then this error appears and delete all my changes for the node-modules

hope you guy'z resolved this with new version '8.0.0'

ERROR Failed to apply patch for package react-native-agora at path

node_modules/react-native-agora

This error was caused because patch-package cannot apply the following patch file:

patches/react-native-agora+4.2.0.patch

Try removing node_modules and trying again. If that doesn't work, maybe there was
an accidental change made to the patch file? Try recreating it by manually
editing the appropriate files and running:

patch-package react-native-agora

If that doesn't work, then it's a bug in patch-package, so please submit a bug
report. Thanks!

https://github.com/ds300/patch-package/issues

patch-package finished with 1 error(s).

@ptim
Copy link

ptim commented Dec 18, 2023

FYI I'm hitting a similar issue attempting to apply a patch to react-dropzone after upgrading patch-package from 7.0.0 to 8.0.0.

This is the patch that has previously worked:
react-dropzone/react-dropzone#1259 (comment)

I note the mention:

I removed some really old legacy filename handling stuff so it's technically a breaking change.

https://github.com/ds300/patch-package/releases/tag/v8.0.0

I don't need multi-patches atm, so can stay on v7.

@JeanMeche
Copy link

I'm supecting the very same thing, v8 broke something.

angular/angular#56347 can attest, the patch doesn't apply anymore even if it is recreated from scratch.

@enzoferey
Copy link

enzoferey commented Oct 3, 2024

Downgrading to v7 also fixed the issue for me on another library failing to apply the patch. The odd thing is that on my local machine works but not on CD. Sharing the patch in case helpful (using [email protected]):

jsonschema+1.4.1.patch

diff --git a/node_modules/jsonschema/lib/index.d.ts b/node_modules/jsonschema/lib/index.d.ts
index ba47f9e..535d4e5 100644
--- a/node_modules/jsonschema/lib/index.d.ts
+++ b/node_modules/jsonschema/lib/index.d.ts
@@ -95,6 +95,10 @@ export interface Schema {
     if?: Schema
     then?: Schema
     else?: Schema
+    // https://github.com/tdegrunt/jsonschema/issues/394
+    default?: any
+    // https://github.com/tdegrunt/jsonschema/issues/323
+    contains?: Schema
 }
 
 export interface Options {

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

4 participants