-
Notifications
You must be signed in to change notification settings - Fork 24.3k
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
React Native 0.57.7 - Android build failed at task :app:mergeReleaseResources #23482
Comments
We are automatically closing this issue because it does not appear to follow any of the provided issue templates. 👉 Click here if you want to report a reproducible bug or regression in React Native. |
Deprecated Gradle features were used in this build, making it incompatible with Gradle 5.0. |
What is the solution for this? |
experiencing same problem it says incompatible with gradle 6.0 i'm thinking updating gradle manually |
Don't import package.json inside your app. This will cause production build to include package.json into your bundle resources and it will cause Java error. Strange, I haven't seen that point in official React Native docs. |
Am having the same error |
me too :( |
another one here ! |
Even more strange is we were successfully doing this in 57.8 but after upgrading to 60.0 got this error. |
Hmm, "package" is a reserved word in Java. Seems, RN Android build was including the package.json differently before the 60.0 version. |
Thanks this indeed fixed stuff for me. However I still need
Then inside my JS I do this: |
For those of you that need to import
Then, inside your inside your
The script applies the changes from the PR which fixes the underlying issue (which hasn't been merged in yet). |
Another solution is to use the So, I put a new key there and import this json instead:
|
I'm getting an error when running the
./gradlew assembleRelease --stacktrace
command in my React Native (v0.57.7) project'sandroid
folder:When checking the folder
android/build/generated/res/react/release/raw
folder, thepackage.json
file is being copied there along with all my other resources (mainly.json
files).What could I possibly do to prevent this weird thing from happening? Just to have said it, I've tried googling for hours now but can't find a solution.
The text was updated successfully, but these errors were encountered: