https://kotlinlang.org logo
#android
Title
# android
j

jurajsolarml

12/11/2018, 7:35 AM
Hello please help.How do I fix it ? Thanks ?/AS 3.4,Gradle 5,JAVA 11/
g

gildor

12/11/2018, 7:39 AM
Please show Gradle log (switch to text view in this panel to see it )
Cause: invalid type code: 8F
log_error.jpg
g

gildor

12/11/2018, 8:02 AM
There are no Gradle logs
Press this button
j

jurajsolarml

12/11/2018, 8:05 AM
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

jurajsolarml

12/11/2018, 8:11 AM
ok, thanks and how do I add a depency ?
g

gildor

12/11/2018, 8:14 AM
using gradle dependencies
j

jurajsolarml

12/11/2018, 8:15 AM
ok
but when I add it, I'm writing a mistake I do not know or do it right?
g

gildor

12/11/2018, 8:21 AM
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

jurajsolarml

12/11/2018, 8:27 AM
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

gildor

12/11/2018, 8:30 AM
Probably something related to build process, hard to tell, try to use
--stacktrace
option for Gradle
j

Juanvi Martínez

12/11/2018, 8:32 AM
btw, why using java 11 if it’s not officially supported on android?
j

jurajsolarml

12/11/2018, 8:37 AM
g

gildor

12/11/2018, 8:37 AM
ClassNotFoundException: javax.xml.bind.JAXBException
oh, I probably now
you add only API for jaxb
you need implementation
j

jurajsolarml

12/11/2018, 8:39 AM
ok,even more because I added here? implementation ("javax.xml.bind: JAXB api-2.3.1")
g

gildor

12/11/2018, 8:44 AM
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

jurajsolarml

12/11/2018, 9:53 AM
Ok, Apk works, Thanks :))
g

gildor

12/11/2018, 11:12 AM
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

Michael Bernier

12/11/2018, 1:30 PM
also last time I tried JAXB on Android, it didn’t work at all, some dependency can’t be used on Android
i

itnoles

12/11/2018, 3:44 PM
Please recheck implementation('com.mikepenzmaterialdrawer5.9.5@aar') {
😕 1
androidTestImplementation inside of implementation('com.mikepenzmaterialdrawer5.9.5@aar')
4 Views