Android Studio 2.2 不显示视图属性

Android Studio 2.2 not displaying view properties

将我的 android studio 升级到 2.2 版后,当我在布局设计器中单击视图以查看其属性时出现以下错误:

Exception in plugin Android Support Moments Ago.

Missing attribute definition for focusable java.lang.IllegalArgumentException:

Missing attribute definition for focusable at com.android.tools.idea.uibuilder.property.NlPropertyItem.(NlPropertyItem.java:88) at com.android.tools.idea.uibuilder.property.NlPropertyItem.create(NlPropertyItem.java:72) at com.android.tools.idea.uibuilder.property.NlProperties.getPropertiesWithReadLock(NlProperties.java:111) at com.android.tools.idea.uibuilder.property.NlProperties.lambda$getProperties7(NlProperties.java:64) at com.intellij.openapi.application.impl.ApplicationImpl.runReadAction(ApplicationImpl.java:966) at com.android.tools.idea.uibuilder.property.NlProperties.getProperties(NlProperties.java:63) at com.android.tools.idea.uibuilder.property.NlPropertiesManager.lambda$setSelectedComponents8(NlPropertiesManager.java:174) at com.intellij.openapi.application.impl.ApplicationImpl.run(ApplicationImpl.java:369) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745)

属性面板卡在加载中,

我的 OS 是 ubuntu 16.04,几乎我已经将 Android SDK 中的所有内容升级到最新版本。

打开可能有问题JDK。请删除它并安装 Oracle JDK 而不是使用此 post: http://www.webupd8.org/2012/09/install-oracle-java-8-in-ubuntu-via-ppa.html

然后转到 File -> Project Structure 并更改 Java sdk 路径。

希望对您有所帮助

最后我通过将compileSdkVersion和targetSdkVersion从24更改为23解决了这个问题。实际上这不是解决异常的正确方法,但我暂时找不到任何解决方案。