archive for required library could not be read or is not a valid ZIP file

Aniket Thakur picture Aniket Thakur · Oct 22, 2013 · Viewed 70k times · Source

Before coming to the problem let me explain what I did that has landed me in the problem.

  1. I created an account on github and made a repository named Android.
  2. Then I installed github client in my windows 7.
  3. Then I opened this client, provided my authentication and cloned the repository to a local directory C:\Users\Aniket\Documents\GitHub\Android(This folder has the .git folder in it).
  4. Then I went to my Eclipse ADT and installed EGit plugin as described here. Also I
  5. Then in Eclipse I right click on my project TicTacToe go to Team->Share Project and provide my repository path i.e C:\Users\Aniket\Documents\GitHub\Android.
  6. My Project was added to the local repository and in my github client it shows me all option to commit file in the actual repository on the github site.
  7. But my project is suddenly showing error with a red '!' sign on it.

    Description --> Archive for required library: 'C:/Users/Aniket/AndroidWorkspace/TicTacToe /libs/android-support-v4.jar' in project 'TicTacToe' cannot be read or is not a valid ZIP file

    Resource --> TicTacToe

    Path Location --> Build path

    Type --> Build Path Problem

Note : the Error was a single line displayed in error console on Eclipse. I just split it up for readability.

Even after detaching repository it shows that error.

Has anyone encountered this scenario before. What is the solution or workaround? I googled and first few links suggest it is an Eclipse bug. Please suggest what can be done to bring my project back to executable state?

Answer

rachit picture rachit · Oct 22, 2013

It is an Eclipse bug. I have faced the similar problem several times. closing and reopening the project works sometime. if it doesn't work try restarting Eclipse.