jcabi-github icon indicating copy to clipboard operation
jcabi-github copied to clipboard

RtGithub producing Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/http/client/methods/HttpEntityEnclosingRequestBase

Open otuounitc opened this issue 5 years ago • 2 comments

I get this error when I'm trying to create an object of RtGithub class. Like this : val rep = RtGithub("...token...")

Here's the log: Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/http/client/methods/HttpEntityEnclosingRequestBase at com.jcabi.http.request.ApacheRequest.<clinit>(ApacheRequest.java:82) at com.jcabi.github.RtGithub.<clinit>(RtGithub.java:82) at com.example.unitconverter.constants.ScriptKt.main(script.kt:31) at com.example.unitconverter.constants.ScriptKt.main(script.kt) Caused by: java.lang.ClassNotFoundException: org.apache.http.client.methods.HttpEntityEnclosingRequestBase at java.net.URLClassLoader.findClass(URLClassLoader.java:382) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ... 4 more

otuounitc avatar Apr 23 '20 02:04 otuounitc

@otuounitc Seems like the class org.apache.http.client.methods.HttpEntityEnclosingRequestBase is missing. Are you sure you have the correct Apache HttpClient dependency?

amihaiemil avatar Apr 23 '20 10:04 amihaiemil

Did you get to resolve this?@otuounitc

GargAnan avatar May 31 '20 14:05 GargAnan