Android Studio Run Error

Stella981
• 阅读 713

运行项目时,报如下错误:

Android Studio Run Error

null

    java.lang.NullPointerException
    at com.intellij.openapi.vfs.impl.local.LocalFileSystemBase.findFileByIoFile(LocalFileSystemBase.java:79)
    at com.intellij.openapi.vfs.VfsUtil.findFileByIoFile(VfsUtil.java:232)
    at com.android.tools.idea.model.ManifestInfo$ManifestFile.getLibManifests(ManifestInfo.java:406)
    at com.android.tools.idea.model.ManifestInfo$ManifestFile.refresh(ManifestInfo.java:339)
    at com.android.tools.idea.model.MergedManifest.syncWithReadPermission(MergedManifest.java:377)
    at com.android.tools.idea.model.MergedManifest$2.run(MergedManifest.java:356)
    at com.intellij.openapi.application.impl.ApplicationImpl.runReadAction(ApplicationImpl.java:843)
    at com.android.tools.idea.model.MergedManifest.sync(MergedManifest.java:353)
    at com.android.tools.idea.model.MergedManifest.getDefaultTheme(MergedManifest.java:219)
    at com.android.tools.idea.configurations.ConfigurationManager.computePreferredTheme(ConfigurationManager.java:340)
    at com.android.tools.idea.configurations.Configuration.getTheme(Configuration.java:581)
    at com.android.tools.idea.uibuilder.model.NlModel.updateTrackingConfiguration(NlModel.java:1987)
    at com.android.tools.idea.uibuilder.model.NlModel.<init>(NlModel.java:179)
    at com.android.tools.idea.uibuilder.model.NlModel.create(NlModel.java:161)
    at com.android.tools.idea.uibuilder.editor.NlEditorPanel.<init>(NlEditorPanel.java:58)
    at com.android.tools.idea.uibuilder.editor.NlEditor.getComponent(NlEditor.java:53)
    at com.android.tools.idea.uibuilder.editor.NlEditor.getComponent(NlEditor.java:35)
    at com.intellij.openapi.fileEditor.impl.EditorComposite.createEditorComponent(EditorComposite.java:187)
    at com.intellij.openapi.fileEditor.impl.EditorComposite.createTabbedPaneWrapper(EditorComposite.java:176)
    at com.intellij.openapi.fileEditor.impl.EditorComposite.<init>(EditorComposite.java:119)
    at com.intellij.openapi.fileEditor.impl.EditorWithProviderComposite.<init>(EditorWithProviderComposite.java:40)
    at com.intellij.openapi.fileEditor.impl.FileEditorManagerImpl.createComposite(FileEditorManagerImpl.java:1020)
    at com.intellij.openapi.fileEditor.impl.FileEditorManagerImpl.lambda$openFileImpl4$6(FileEditorManagerImpl.java:890)
    at com.intellij.util.ui.UIUtil.invokeAndWaitIfNeeded(UIUtil.java:2453)
    at com.intellij.openapi.fileEditor.impl.FileEditorManagerImpl.openFileImpl4(FileEditorManagerImpl.java:971)
    at com.intellij.openapi.fileEditor.impl.FileEditorManagerImpl.openFileImpl3(FileEditorManagerImpl.java:788)
    at com.intellij.openapi.fileEditor.impl.FileEditorManagerImpl.lambda$openFileImpl2$4(FileEditorManagerImpl.java:770)
    at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:122)
    at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:100)
    at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:86)
    at com.intellij.openapi.fileEditor.impl.FileEditorManagerImpl.openFileImpl2(FileEditorManagerImpl.java:770)
    at com.intellij.openapi.fileEditor.impl.FileEditorManagerImpl.openFileWithProviders(FileEditorManagerImpl.java:711)
    at com.intellij.openapi.fileEditor.ex.FileEditorManagerEx.openFile(FileEditorManagerEx.java:151)
    at com.intellij.openapi.fileEditor.impl.FileEditorManagerImpl.lambda$openEditor$9(FileEditorManagerImpl.java:1151)
    at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:129)
    at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:100)
    at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:86)
    at com.intellij.openapi.fileEditor.impl.FileEditorManagerImpl.openEditor(FileEditorManagerImpl.java:1149)
    at com.intellij.openapi.fileEditor.OpenFileDescriptor.navigateInAnyFileEditor(OpenFileDescriptor.java:146)
    at com.intellij.openapi.fileEditor.OpenFileDescriptor.navigateInEditor(OpenFileDescriptor.java:132)
    at com.intellij.openapi.fileEditor.OpenFileDescriptor.navigateInEditorOrNativeApp(OpenFileDescriptor.java:128)
    at com.intellij.openapi.fileEditor.OpenFileDescriptor.navigate(OpenFileDescriptor.java:115)
    at com.intellij.psi.impl.source.PsiFileImpl.navigate(PsiFileImpl.java:1007)
    at com.intellij.codeInsight.navigation.NavigationUtil.openFileWithPsiElement(NavigationUtil.java:176)
    at com.intellij.ide.projectView.impl.nodes.AbstractPsiBasedNode.navigate(AbstractPsiBasedNode.java:235)
    at com.intellij.ide.projectView.impl.nodes.AbstractPsiBasedNode.navigate(AbstractPsiBasedNode.java:245)
    at com.intellij.ide.projectView.impl.nodes.PsiFileNode.navigate(PsiFileNode.java:133)
    at com.intellij.util.OpenSourceUtil.navigate(OpenSourceUtil.java:53)
    at com.intellij.util.OpenSourceUtil.openSourcesFrom(OpenSourceUtil.java:31)
    at com.intellij.util.EditSourceOnDoubleClickHandler$TreeMouseListener.processDoubleClick(EditSourceOnDoubleClickHandler.java:130)
    at com.intellij.util.EditSourceOnDoubleClickHandler$TreeMouseListener.onDoubleClick(EditSourceOnDoubleClickHandler.java:122)
    at com.intellij.ui.DoubleClickListener.onClick(DoubleClickListener.java:30)
    at com.intellij.ui.ClickListener$1.mouseReleased(ClickListener.java:73)
    at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:290)
    at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:289)
    at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:289)
    at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:289)
    at java.awt.Component.processMouseEvent(Component.java:6533)
    at javax.swing.JComponent.processMouseEvent(JComponent.java:3324)
    at com.intellij.ui.treeStructure.Tree.processMouseEvent(Tree.java:443)
    at com.intellij.ide.dnd.aware.DnDAwareTree.processMouseEvent(DnDAwareTree.java:59)
    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:80)
    at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:90)
    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:80)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:728)
    at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:795)
    at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:627)
    at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:387)
    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)

解决方法 Solution

Try 【Sync Project with Gradle Files】

Android Studio Run Error

点赞
收藏
评论区
推荐文章
blmius blmius
3年前
MySQL:[Err] 1292 - Incorrect datetime value: ‘0000-00-00 00:00:00‘ for column ‘CREATE_TIME‘ at row 1
文章目录问题用navicat导入数据时,报错:原因这是因为当前的MySQL不支持datetime为0的情况。解决修改sql\mode:sql\mode:SQLMode定义了MySQL应支持的SQL语法、数据校验等,这样可以更容易地在不同的环境中使用MySQL。全局s
待兔 待兔
4个月前
手写Java HashMap源码
HashMap的使用教程HashMap的使用教程HashMap的使用教程HashMap的使用教程HashMap的使用教程22
Stella981 Stella981
3年前
Microsoft.NETCore.App 版本不一致导致的运行失败
场景重现今天新建了一个ASP.NETCore的项目,通过WebDeploy顺利发布到IIS上后,但访问时出现如下异常:!HTTPError502.5ProcessFailure(https://static.oschina.net/uploads/img/201705/25131143_Q15g.png"
Wesley13 Wesley13
3年前
thinkphp3.2.3模板渲染支持三元表达式
thinkphp3.2.3模板渲染支持三元表达式{$status?'正常':'错误'}{$info'status'?$info'msg':$info'error'}注意:三元运算符中暂时不支持点语法。如下:           <divclass"modalhidefade"id'myModa
Stella981 Stella981
3年前
Linux下java报错Too many open files的解决方法
最近发现运行在Linux下的javaapplication报如下错误:java.io.IOException:Cannotrunprogram"/bin/sh":java.io.IOException:error24,ToomanyopenfilesCausedby:java.io.IOException:
Stella981 Stella981
3年前
Golang 返回&errorString,而不是errorString的原因
Errors包查看golang的errors包你会发现其源码是:funcNew(textstring)error{return&errorString{text}}//errorStringisatrivialimplementationofer
Stella981 Stella981
3年前
CAS 实现站内单点登录及实现第三方 OAuth、OpenId 登录(二)
一、登录表单<form:form id"loginForm" method"post" commandName"${commandName}" htmlEscape"true"    <form:errors path"" element"em" cssClass"" /    <c:if t
Easter79 Easter79
3年前
Swift项目兼容Objective
!456.jpg(http://static.oschina.net/uploads/img/201509/13172704_1KcG.jpg"1433497731426906.jpg")本文是投稿文章,作者:一叶(博客(https://www.oschina.net/action/GoToLink?urlhttp%3A%2F%2F00red
Stella981 Stella981
3年前
How Linux Works
!(https://static.oschina.net/uploads/img/201705/30192005_FetF.jpg"在这里输入图片标题")(一)HowtheLinuxKernelBoots1.Themachine’sBIOSorbootfirmwa
Stella981 Stella981
3年前
GTID做mysql主从时报错
今天在做主从同步时,显示slave\_IO线程为NO,并且报如下错误Slave_IO_Running:No...Last_IO_Error:Fatalerror:TheslaveI/OthreadstopsbecausemasterandslavehaveequalMySQLserverUU