1
votes

I'm integrating stripe payment on my new Android app.

I downloaded the stripe library project from git hub(https://github.com/stripe/stripe-android/archive/master.zip) and imported it into Eclipse.

After that I have included this library project in my project.

When I start running the app on my device, I'm getting following error.

[2014-10-04 00:08:03 - stripe] Could not find stripe.apk!

After running, I get Exception in Stripe call.

10-04 00:16:29.106: E/AndroidRuntime(26379): java.lang.NoClassDefFoundError: com.stripe.android.model.Card

Thank you.

1
why is this even a thing? i thought google dropped android support for eclipse. - EvOlaNdLuPiZ

1 Answers

1
votes

The NoClassDefFoundError means that the definition of the class was found at compile time but not found at run time. The most likely cause is that (and reiterated by the log message you have shown) is that the Stripe class definition is not available at runtime (ie within your device). But you didn't get any compile time errors because the class was available while building it in your system.

I checked the Stripe github page and the readme information did not say anything about generating a Stripe.apk (or the need for it). Most likely your eclipse is causing problems with this. I've seen this kind of error in the past.

After switching to Android Studio, I haven't experienced any of these problems as gradle automatically gets the dependencies and links them.