-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Execution failed for task ':react-native-svg:compileDebugJavaWithJavac'. #1037
Comments
Did you get any where with this? isue #779 suggests it is fixed in v7.0.2 but I am experiencing with v9.7.1 |
That's really strange, those should come from react-native. Can you make a git repo with a reproduction? |
Thanks for coming back. Unfortunately this is in a massive repo I'm trying to upgrade (from react native 0.54.4 to 0.59.10) and my react native knowledge isn't very strong to do a reproduction. Here is the dependencies section of package.json:
|
A reproduction project would most likely contain only react-native and react-native-svg, and absolutely nothing else, with the smallest possible amount of code/changes to show the issue. |
Essentially https://github.com/react-native-community/react-native-svg#troubleshooting react-native init CleanProject
cd CleanProject/
yarn add react-native-svg
cd ios && pod install && cd .. And everything should work correctly. |
I have the same problem. I run this Sorry for my bad English |
Again, can you make a git repo with a minimal reproduction? |
I've done a minimal reproduction and it doesn't occur. I'll try and compare the two and see if I can find where it is failing. I guess it must be something in the gradle build process so I'll start there. Thanks for your help though and your patience with a react-native n00b 😄 |
Interestingly, I have noticed the clean project does seem to run the task react-native-svg:compileDebugJavaWithJavac but it leaves it on the console wherease the others vanish. My other project has a much more verbose run output so I'm going to investigate if it's got some sort of switch to make it break on warnings. The output I get on the clean project is:
|
Interesting, at least it seems to build correctly. So the issue could be related to caching, have you tried cleaning the project? Or some gradle configs. |
Ok, I found it. It was a problem with my build.gradle. Obviously this is because I'm a) doing a big upgrade and b) don't know what I'm doing! diff --git a/android/build.gradle b/android/build.gradle
index 79f7a803..05d74d0a 100644
--- a/android/build.gradle
+++ b/android/build.gradle
@@ -34,9 +34,9 @@ wrapper {
ext {
minSdkVersion = 16
- compileSdkVersion = 26
- targetSdkVersion = 26
- supportLibVersion = "26.1.0"
+ compileSdkVersion = 28
+ targetSdkVersion = 28
+ supportLibVersion = "28.0.0"
}
subprojects {
@@ -45,7 +45,7 @@ subprojects {
resolutionStrategy.eachDependency { details ->
if (details.requested.group == 'com.android.support'
&& !details.requested.name.contains('multidex') ) {
- details.useVersion "26.1.0"
+ details.useVersion "28.0.0"
}
}
} |
this was my error |
I'm facing with 2 problem: |
Please install version 4.2.4 |
Please run this and then test again:
or
|
Execution failed for task ':react-native-svg:compileDebugJavaWithJavac'.
|
Still getting this error. even with a new clean project. On removing package error foes and App compiles |
Same |
anyone found any solution for this? |
Bug
I ran following comments for setup,
npm i react-native-copilot
npm i react-native-svg
react-native link react-native-svg
everything fine, but I'm getting build time error.
FAILURE: Build failed with an exception.
Execution failed for task ':react-native-svg:compileDebugJavaWithJavac'.
Environment info
info
React Native Environment Info:
System:
OS: macOS 10.14.5
CPU: (8) x64 Intel(R) Core(TM) i7-4770HQ CPU @ 2.20GHz
Memory: 25.87 MB / 16.00 GB
Shell: 3.2.57 - /bin/bash
Binaries:
Node: 8.9.4 - ~/.nvm/versions/node/v8.9.4/bin/node
Yarn: 1.12.3 - /usr/local/bin/yarn
npm: 5.6.0 - ~/.nvm/versions/node/v8.9.4/bin/npm
Watchman: 4.9.0 - /usr/local/bin/watchman
SDKs:
Android SDK:
API Levels: 23, 24, 25, 26, 27, 28
Build Tools: 23.0.1, 23.0.2, 25.0.0, 25.0.1, 25.0.2, 26.0.1, 26.0.2, 26.0.3, 27.0.3, 28.0.1, 28.0.3
System Images: android-23 | Intel x86 Atom_64, android-23 | Google APIs Intel x86 Atom_64, android-24 | Google APIs ARM 64 v8a, android-28 | Google APIs Intel x86 Atom, android-29 | Google Play Intel x86 Atom
IDEs:
Android Studio: 3.3 AI-182.5107.16.33.5314842
Xcode: /undefined - /usr/bin/xcodebuild
npmPackages:
react: ^16.8.6 => 16.8.6
react-native: 0.59.9 => 0.59.9
npmGlobalPackages:
react-native-cli: 2.0.1
Library version: ^9.5.1
Steps To Reproduce
npm i react-native-copilot
npm i react-native-svg
react-native link react-native-svg
react-native run-android
Describe what you expected to happen:
The text was updated successfully, but these errors were encountered: