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

Minification failure with R8: Compilation failed for ReactAppLifecycleFacade$1 in react-native-notifications #1031

Open
2 tasks done
Calderis opened this issue Feb 19, 2024 · 1 comment

Comments

@Calderis
Copy link

Calderis commented Feb 19, 2024

I encountered an issue while trying to minify my React Native application with R8. The build fails with the following error related to the ReactAppLifecycleFacade$1 class from the react-native-notifications module:

Execution failed for task ':app:minifyReleaseWithR8'.
> A failure occurred while executing com.android.build.gradle.internal.tasks.R8Task$R8Runnable
   > Compilation failed to complete, origin: /path/to/project/node_modules/react-native-notifications/lib/android/app/build/intermediates/runtime_library_classes_jar/reactNative60Release/classes.jar:com/wix/reactnativenotifications/core/ReactAppLifecycleFacade$1.class

Reproducing the Issue :

  1. Update react-native-notifications to the latest version.
  2. Enable minification in android/app/build.gradle.
  3. Attempt to build the release version using R8 with ./gradlew assembleRelease --info in android folder

Expected behavior :

The application should build successfully with R8 enabled for minification.

Actual behavior :

The build fails with the mentioned error related to the ReactAppLifecycleFacade$1 class.

Environment Information :

  • React Native version: 0.71.8
  • react-native-notifications version: 5.1.0
  • Node.js version: v16.14.0
  • yarn version: 1.22.19

I have tried the following solutions based on online recommendations:

  • Updating all project dependencies.
  • Checking community forums and discussions.

I appreciate your assistance in resolving this issue. Please let me know if any further information is needed.

Copy link

stale bot commented Jan 31, 2025

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@stale stale bot added the 🏚 stale label Jan 31, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant