Error updating Android Studio

When I try to update my Android Sudio, I get this message:

Temp. directory: C:\Users\Rick\AppData\Local\Temp\ +---------------- | A file operation failed. | This might be due to a file being locked by another | application. Please try closing any application | that uses the files being updated then press 'Retry'. +---------------- com.intellij.updater.RetryException: Cannot delete file C:\Users\Rick\AppData\Local\Android\android-studio\plugins\gradle\lib\gradle-tooling-extension-impl.jar at com.intellij.updater.BaseUpdateAction.replaceUpdated(BaseUpdateAction.java:40) at com.intellij.updater.UpdateZipAction.doApply(UpdateZipAction.java:199) at com.intellij.updater.PatchAction.apply(PatchAction.java:140) at com.intellij.updater.Patch$3.forEach(Patch.java:198) at com.intellij.updater.Patch.forEach(Patch.java:248) at com.intellij.updater.Patch.apply(Patch.java:194) at com.intellij.updater.PatchFileCreator.apply(PatchFileCreator.java:86) at com.intellij.updater.PatchFileCreator.apply(PatchFileCreator.java:77) at com.intellij.updater.Runner.doInstallImpl(Runner.java:307) at com.intellij.updater.Runner.doInstall(Runner.java:268) at com.intellij.updater.Runner.access$000(Runner.java:18) at com.intellij.updater.Runner$2.execute(Runner.java:258) at com.intellij.updater.SwingUpdaterUI$7.run(SwingUpdaterUI.java:230) at java.lang.Thread.run(Thread.java:745) 
+6
source share
3 answers

The Android\android-studio\plugins\gradle\lib\gradle-tooling-extension-impl.jar is probably used by some JVM process (displayed as java.exe in the task manager).

The solution that worked for me was to close the updater and close all java.exe processes in the task manager, and then open Android Studio and try updating again. This time the update should go all the way.

+9
source

Workaround:

 1-Close Android Studio. 2-Right-click "Android Studio" icon and select "Run as administrator". 3-Go to "Help->Check for Update..." 
0
source

I get the exact error you get. I left my computer for the night and clicked retry, and it worked. Very strange. I also tried using:

handle - http://technet.microsoft.com/en-us/sysinternals/bb896655.aspx as well as Process explorer - http://technet.microsoft.com/en-us/sysinternals/bb896653

to check what the lock on this file is, and both of them showed nothing. That is, when I pressed the snooze button and it worked

-1
source

Source: https://habr.com/ru/post/975806/


All Articles