It usually happens after some kind of refactor in the solution under different conditions. I think it's easier to just stop server, delete the contents of the repository database and start fresh. (or course all the old content (solutions, styles, db info, ...) on that app. server will be deleted in the process)