我对Android Studio(以及StackOverflow = D)相对较新,最近开始遇到启动问题。
每当我第一次启动Android Studio时(即在PC启动/重启后),我在Android Studio项目窗口中的所有内容都是一个对话框,说明&#34; 无法加载项目 - java.lang.NullPointerException < /强>&#34;
当我单击“确定”(没有其他选项)时,项目窗口中没有显示任何内容。我在右上方有一个红色弹出窗口 - 发生IDE内部错误,点击查看详细信息。这是我从中得到的错误消息:
null
java.lang.NullPointerException
at com.intellij.openapi.updateSettings.impl.UpdateChecker.updateAndShowResult(UpdateChecker.kt:126)
at com.intellij.openapi.updateSettings.impl.CheckForUpdateAction.actionPerformed(CheckForUpdateAction.java:40)
at com.intellij.openapi.actionSystem.ex.ActionUtil.performActionDumbAware(ActionUtil.java:191)
at com.intellij.openapi.actionSystem.impl.ActionMenuItem$ActionTransmitter$1.run(ActionMenuItem.java:312)
at com.intellij.openapi.wm.impl.FocusManagerImpl.runOnOwnContext(FocusManagerImpl.java:958)
at com.intellij.openapi.actionSystem.impl.ActionMenuItem$ActionTransmitter.actionPerformed(ActionMenuItem.java:282)
at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2022)
at com.intellij.openapi.actionSystem.impl.ActionMenuItem.fireActionPerformed(ActionMenuItem.java:110)
at com.intellij.ui.plaf.beg.BegMenuItemUI.doClick(BegMenuItemUI.java:513)
at com.intellij.ui.plaf.beg.BegMenuItemUI.access$300(BegMenuItemUI.java:45)
at com.intellij.ui.plaf.beg.BegMenuItemUI$MyMouseInputHandler.mouseReleased(BegMenuItemUI.java:533)
at java.awt.Component.processMouseEvent(Component.java:6533)
at javax.swing.JComponent.processMouseEvent(JComponent.java:3324)
at java.awt.Component.processEvent(Component.java:6298)
at java.awt.Container.processEvent(Container.java:2236)
at java.awt.Component.dispatchEventImpl(Component.java:4889)
at java.awt.Container.dispatchEventImpl(Container.java:2294)
at java.awt.Component.dispatchEvent(Component.java:4711)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4888)
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4525)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4466)
at java.awt.Container.dispatchEventImpl(Container.java:2280)
at java.awt.Window.dispatchEventImpl(Window.java:2746)
at java.awt.Component.dispatchEvent(Component.java:4711)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:758)
at java.awt.EventQueue.access$500(EventQueue.java:97)
at java.awt.EventQueue$3.run(EventQueue.java:709)
at java.awt.EventQueue$3.run(EventQueue.java:703)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:76)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:86)
at java.awt.EventQueue$4.run(EventQueue.java:731)
at java.awt.EventQueue$4.run(EventQueue.java:729)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:76)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:728)
at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:857)
at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:654)
at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:386)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:201)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)
不知道这意味着什么...我在Windows 10 x64上使用最新版本的软件:
Android Studio 2.2.3
Build #AI-145.3537739, built on December 2, 2016
JRE: 1.8.0_76-release-b03 amd64
JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
想知道为什么会发生这种情况以及如何解决这个问题?顺便说一句, 这只是第一次发生 ,但我无法关闭它(无响应),所以我必须通过任务管理器结束任务。当我再次启动它确实可以正常工作,但在下一步 PC启动时会出现同样的错误......
(我在互联网上做了很多关于此事的搜索,但除了人们有较旧的过时软件版本外,无法找到任何对此类问题的引用 - 但我正在运行所有软件的最新稳定版本 - 其中这就是为什么我找不到任何东西)
任何帮助将不胜感激=)
答案 0 :(得分:0)
更新和Windows重启后我也面临同样的问题。 不确定,但可能是由于最近版本的Android Studio中存在错误。
对我有用的临时解决方案是从任务管理器中杀死(&#34;结束进程&#34;)Android Studio可执行文件(studio64.exe),然后再次运行它。
一旦开始运作良好,请更新到最新版本。