Cache.properties (the system cannot find the specified file)

I just started using Android Studio 1.3 sdk 24, and it has worked great until today. I get this cache.properties error message and I delete this cache file, but now I get this error message:

Error: C: \ Users \ user1.gradle \ caches \ 2.4 \ scripts \ asLocalRepo15_dhjxrnvsgiyg1ow3dfj4myl7 \ InitScript \ initscript \ cache.properties (the system cannot find the specified file)

I try to execute the / invalidate caches / restart .. file and rebuild the project, but I still get this error message. How to fix it?

+44
android android-studio
Aug 15 '15 at 12:59 on
source share
12 answers

You do not need to delete all .gradle folders and you do not need to reinstall Android Studio.

I have the latest version of Android Studio, and I ran into this problem, the only thing that worked for me:

  • Go to C:\Users\user\.gradle\caches\2.x\

  • Copy the scripts folder, scripts-remapped and paste it somewhere safe, if something went wrong, you put it back

  • Delete this folder scripts and scripts-remapped from the directory C:\Users\user\.gradle\caches\2.x\

  • Synchronize the project with Gradle Files, and you're done.

enter image description here

When synchronizing a project, Android Studio will generate new cache files.

It worked for me, I hope it works for you.

+106
Sep 05 '15 at 2:05
source share

Reinstalling Android Studio is again not an option!

To fix the problem:

cache.properties (the system cannot find the specified file)

go to:

  C:\Users\[User]\.gradle\caches\ 

Delete folders \2.4 and \2.8

introduction to the description of lifestyle

Reboot Android Studio !.

+10
Apr 03 '16 at 3:23
source share

You do not need to reinstall Android Studio or do not need to delete the entire .gradle folder.

I reinstalled the latest version of Android Studio and still ran into this problem. This made me rename the Android Projects folder on my desktop in my case.

The only thing you need to do:

1-Go to C: \ Users \ user_name.gradle \ caches \ 2.4 or (2.8 if the error otherwise)

2-Copy the folder “2.4” or “2.8” and paste it somewhere in a safe place, if something went wrong, you put it back

3-Delete this error folder from the C: \ Users \ user.gradle \ caches \ 2.4 \ (or \ 2.8) directory

4 - Close Android studio and restart it.

During the reboot, it syncs your project, and Android Studio will generate new cached files.

It worked for me, I hope it works for you ... :)

+8
Jan 12 '16 at 19:33
source share

I have the same problem, I just .gradle from C:\Users\user\.gradle\caches\2.4\ and from my application.

Of course, close Android Studio and run Android Studio again.

+5
Sep 28 '15 at 5:55
source share

No need to reinstall everything.

Just delete the folder 2.4 and 2.8 , located in the C:\Users\user\.gradle\caches , and reopen the Android studio. It will generate new money files, so now the assembly should be successful.

+4
Mar 11 '16 at 7:01
source share

As stated in the examples above, I tried to resolve the additional steps:

  • Go to the appropriate folder C: \ Users \ user.gradle \ caches \ 2.14.1 \
  • Copy the scripts and scripts-remapped folders to a safe place.
  • Now REMOVE AND HANDLE THE “Scripts” and “Reassigned Scripts” FOLDERS in the folder C: \ Users \ user.gradle \ caches \ 2.14.1 \
  • Finally, try synchronizing gradle.
  • Android Studio will offer to update the Gradle plugin. So click "Refresh" gradle.

(If you do not try to completely restart the IDE for Android Studio.)

Finally, it is done for me ... !!!

+3
Oct 31 '16 at 2:58
source share

I found a solution to my question, but I do not know if this is the optimal solution:

I deleted all the .gradle folders in the user library and reinstalled the android and then it worked.

+2
Aug 16 '15 at 13:16
source share

A simple solution. Go ahead and create an empty cache.properties file along the path specified in the error log. The error should disappear.

+1
Jan 27 '16 at 22:02
source share

Deleting the scripts folder and restoring the project will resolve this problem.

+1
Apr 27 '16 at 5:24
source share

I don’t know why a great developer, since Google cannot deal with this problem themselves, it’s very easy to delete the cached folder and regenerate it programmatically. In any case, just go to C: \ Users \ user.gradle \ caches \ and open the latest version folder and then delete the scripts folder. Go to android studio project and sync project.

+1
Nov 01 '16 at 6:33
source share

Go to the folder indicated in the error message. Delete the cache.properties.lock file.

0
Dec 05 '17 at 16:08
source share

As mentioned above, I ran into the same problem: try this

  • Delete scripts and scripts-converted folders in the folder C: \ Users \ user.gradle \ caches \ 2.14.1 \
  • restart android studio

THIS WORKS FOR ME.

-one
Nov 07 '16 at 21:09
source share



All Articles