每当我尝试运行我的应用程序时,我都会收到此错误:
错误:任务执行失败
:app:transformClassesWithInstantRunSlicerForDebug'.
java.io.IOException: Failed to delete
C:\Users\ashis\AndroidStudioProjects\FirstApp\app\build\intermediates\instant-run-support\debug\restart-changes.txt**
Run Code Online (Sandbox Code Playgroud)
这是输出:
信息:Gradle任务
[:app:assembleDebug]:app:preBuild UP-TO-DATE:app:preDebugBuild UP-TO-DATE:app:checkDebugManifest:app:preReleaseBuild UP-TO-DATE:app:prepareComAndroidSupportAnimatedVectorDrawable2340Library UP-TO-DATE:app:prepareComAndroidSupportAppcompatV72340Library最新消息:app:prepareComAndroidSupportSupportV42340Library UP-TO-DATE:app:prepareComAndroidSupportSupportVectorDrawable2340Library UP-TO-DATE:app:prepareDebugDependencies:app:compileDebugAidl UP-TO-DATE:app:compileDebugRenderscript UP-TO-DATE:app:generateDebugBuildConfig UP -TO-DATE:app:mergeDebugShaders UP-TO-DATE:app:compileDebugShaders UP-TO-DATE:app:generateDebugAssets UP-TO-DATE:app:mergeDebugAssets UP-TO-DATE:app:generateDebugResValues UP-TO-DATE: app:generateDebugResources UP-TO-DATE:app:mergeDebugResources UP-TO-DATE:app:processDebugManifest UP-TO-DATE:app:processDebugResources UP-TO-DATE:app:generateDebugSources UP-TO-DATE:app:incrementalDebugJavaCompilationSafeguard UP-至今:app:compileDebugJavaWithJavac 最新版本:app:compileDebugNdk UP-TO-DATE:app:compileDebugSources UP-TO-DATE:app:buildInfoDebugLoader:app:transformClassesWithExtractJarsForDebug UP-TO-DATE:app:transformClassesWithInstantRunVerifierForDebug UP-TO-DATE:app:transformClassesWithJavaResourcesVerifierForDebug UP -TO-DATE:app:mergeDebugJniLibFolders UP-TO-DATE:app:transformNative_libsWithMergeJniLibsForDebug UP-TO-DATE:app:processDebugJavaRes UP-TO-DATE:app:transformResourcesWithMergeJavaResForDebug UP-TO-DATE:app:transformResourcesAndNative_libsWithJavaResourcesVerifierForDebug UP-TO-DATE: app:transformClassesWithInstantRunForDebug UP-TO-DATE:app:transformClasses_enhancedWithInstant + reloadDexForDebug UP-TO-DATE:app:incrementalDebugTasks:app:prePackageMarkerForDebug:app:fastDeployDebugExtractor UP-TO-DATE:app:generateDebugInstantRunAppInfo UP-TO-DATE:app:coldswapKickerDebug: app:transformClassesWithInstantRunSlicerForDebug FAILED错误:任务执行失败':app:transformClassesWithInstantRunSlicerForD ebug".java.io.IOException:无法删除C:\ Users\ashis\AndroidStudioProjects\FirstApp\app\build\intermediates\instant-run-support\debug\restart-changes.txt信息:BUILD FAILED信息:总时间:1分钟6.761秒信息:1错误信息:0警告信息:在控制台中查看完整输出
小智 78
:应用程序:transformClassesWithInstantRunSlicerForDebug".java.io.IOException:无法删除
- 尝试清理项目并重建项目.
来自@Kael:通过Build - > Clean Project或Build - > Rebuild Project执行清理.
Dex*_*ter 31
请按照以下步骤操作:转到
1>File
2>Settings
3>Build,Execution,Deployment
4>Instant Run
5>Uncheck (Enable Instant Run to hot swap code)
Run Code Online (Sandbox Code Playgroud)
因此,这对我有所帮助。
在我的情况下Build Menu > Clean Project and Build Menu > Rebuild没有工作.相反,我不得不build从文件系统中手动删除文件夹(在OSX上使用Finder,在Win上使用Explorer).
| 归档时间: |
|
| 查看次数: |
61946 次 |
| 最近记录: |