Hello please help.How do I fix it ? Thanks ?/AS 3....
# android
j
Hello please help.How do I fix it ? Thanks ?/AS 3.4,Gradle 5,JAVA 11/
g
Please show Gradle log (switch to text view in this panel to see it )
Cause: invalid type code: 8F
log_error.jpg
g
There are no Gradle logs
Press this button
j
also you cannot have javax.xml on Android out of the box, you need this dependency https://mvnrepository.com/artifact/javax.xml.bind/jaxb-api
j
ok, thanks and how do I add a depency ?
g
using gradle dependencies
j
ok
but when I add it, I'm writing a mistake I do not know or do it right?
g
Did you add maven xml snippet to Gradle file? 😁
🤣 4
You need something like
Copy code
implementation("javax.xml.bind:jaxb-api:2.3.1")
j
Yes, but he's still writing the mistake FAILURE: Build failed with an exception. * What went wrong: Execution failed for task 'appcompileDebugJavaWithJavac'.
javax/xml/bind/JAXBException
g
Probably something related to build process, hard to tell, try to use
--stacktrace
option for Gradle
j
btw, why using java 11 if it’s not officially supported on android?
j
g
ClassNotFoundException: javax.xml.bind.JAXBException
oh, I probably now
you add only API for jaxb
you need implementation
j
ok,even more because I added here? implementation ("javax.xml.bind: JAXB api-2.3.1")
g
No-no, this dependency is just API, no real implementation of xml binder
anyway, it’s really strange why do you have this error
I mean looks like some dependency requires it
First of all I would try to use Java 8. Java 11 for any Android development can be really tricky, some tools just may not work with it
j
Ok, Apk works, Thanks :))
g
some tools just may not work with it
I checked your build.gradle and I found this tool. This is Kotlin Kapt. Kapt doesn’t work with Java 9+
m
also last time I tried JAXB on Android, it didn’t work at all, some dependency can’t be used on Android
i
Please recheck implementation('com.mikepenzmaterialdrawer5.9.5@aar') {
😕 1
androidTestImplementation inside of implementation('com.mikepenzmaterialdrawer5.9.5@aar')