java.lang.NoSuchMethodError: org.jetbrains.android.facet.AndroidFacetConfiguration.getModel()Lcom/android/tools/idea/model/AndroidModel

已回答

Hey there. I'm running into this error when running a plugin in Android Studio 4.0 Canary 9.

2020-02-27 11:43:44,009 [ 40310] ERROR - llij.ide.plugins.PluginManager - org.jetbrains.android.facet.AndroidFacetConfiguration.getModel()Lcom/android/tools/idea/model/AndroidModel;
java.lang.NoSuchMethodError: org.jetbrains.android.facet.AndroidFacetConfiguration.getModel()Lcom/android/tools/idea/model/AndroidModel;

Plugin works fine on AS 3.5 and 3.6. Am I missing anything? Thanks!

0

AndroidFacetConfiguration method is now part of AndroidModel. So these changes should fix it.

From this to this:

AndroidModel model = facet.getConfiguration().getModel();

to this:

AndroidModel model = AndroidModel.get(module);

0

请先登录再写评论。