Gradle and Could not initialize class YYYYYY

In Gradle I got stumped by this even though class YYYYYY was on the classpath.
java.lang.NoClassDefFoundError: Could not initialize class YYYYYY

I put a try catch block around the code that was failing. This gave me a more direct error than before.
It turned out that I had XML reading error where a class was trying to read a file that was not present on the classpath

The class was present but the initialization failed, check your setup.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s