Throw exception in GitRepository::checkError