-
Notifications
You must be signed in to change notification settings - Fork 2
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
/android/app/build/generated/autolinking/src/main/java/com/facebook/react/PackageList.java:70: error: duplicate class: com.facebook.react.PackageList public class PackageList { #285
Comments
I think you forgot to remove this code at the bottom of andoird/app/build.gradle
|
@iwangsyah I had the same problem, and this answer helped me! |
It seems I'm facing a similar issue. I'm unsure why this file is being generated after deletion and why it's necessary to run the app. Additionally, I've noticed that in some React Native projects, this file isn't even present. |
I faced the same issue when I migrated my project from React Native version 0.74.x to 0.75.x. I finally resolved it. |
android/app/build/generated/autolinking/src/main/java/com/facebook/react/PackageList.java:56: error: duplicate class: com.facebook.react.PackageList FAILURE: Build failed with an exception.
I am still getting this error and above solution didn't worked for me react-native version 0.74.2 anyone can suggest me for the solution Thanks |
@manishmobmaxime Did you find any solution? |
@shahid3130khan @manishmobmaxime did you fix this? |
I was having the same issue migrating from 0.74.5 to 0.76.5. The solution suggested here fixed the problem, however, the line to be deleted was not at the end of the file, but at line 122 (a few lines before the end). |
/android/app/build/generated/autolinking/src/main/java/com/facebook/react/PackageList.java:70: error: duplicate class: com.facebook.react.PackageList
public class PackageList { ^
1 error FAILURE: Build failed with an exception. * What went wrong:
Execution failed for task ':app:compileDebugJavaWithJavac'.
The text was updated successfully, but these errors were encountered: