I have a react native version 0.61.4 project. I completed this project last year 2021 and everything was built and ran fine. Just yesterday, almost about a year now, I decided to build this project because I wanted to continue from where I left off last year.
I ran the command "npx react-native run android" command, and the build failed reason was: Execution failed for task ':@react-native-community_slider:compileDebugJavaWithJavac'
I did a series of google searches on this, and I discovered from within this thread: https://github.com/callstack/react-native-slider/issues/82, that I needed to do the following:
- npx install --save-dev jetifier
- npx jetify
I did this and I am still getting the same result.
Now I did this because I thought the issue may be a result of the package "@react-native-community/slider". So I replaced the package with "react-native-slider" and removed the previous package.
I ran "npx react-native run android" again. And this time I got the error:
Execution failed for task ':react-native-orientation:compileDebugJavaWithJavac', since react-native-orientation is one of the packages I have installed in my node modules.
Now all this I am just discovering after not touching this project for a year, and the project was building and running successfully since then.
In fact I did "cd android && ./gradlew --clean" and find ~/.gradle -type f -name "*.lock" -delete
My react-native version is 0.61.4 My android studio version is 2.3.1
Any help provided to help get me to get my android build successful will be greatly appreciated. PS iOS builds successfully.
npx install --save-dev jetifier npx jetify cd android && ./gradlew --clean find ~/.gradle -type f -name "*.lock" -delete
I was expecting the build to succeed, but instead, I kept getting, failed builds with 'compileDebugJavaWithJavac'