Android, NoClassDefFoundError

I have an Android project in IntelliJ. It builds fine, but when I run it, I see a whole series of NoClassDefFoundError exceptions across the app when it executes. So the compiler is finding the source when it builds the app, but when the app executes, the compiled source is clearly not available. The source in question is just sitting in the src folder in the project, so I'm pretty confused why this is happening. The class DEFINITELY exists, and is referenced in the code which compiles, so this does look like a linking issue.

Can anyone shed any light? I suspect I need to tweak the project settings.

2 comments
Comment actions Permalink
@Override
public ModuleConfigurationEditor[] createEditors(ModuleConfigurationState state) {

ModifiableRootModel rootModel = state.getRootModel();
Module module = rootModel.getModule();

String moduleName = module.getName();
List<ModuleConfigurationEditor> editors = new ArrayList<>();
editors.add(new CommonContentEntriesEditor(moduleName, state));
//editors.add(new ClasspathEditor(state));
return editors.toArray(ModuleConfigurationEditor.EMPTY);
}

Implentation with CommonContentEntriesEditor class works, as it is part of intellij.platform.lang.impl.
0
Comment actions Permalink

Does it run normally when using Android Studio?

 

You can make a minimum demo of this problem and push it to github, So we can investigate it in detail.

0

Please sign in to leave a comment.