Wednesday, January 16, 2019

How To Deal With Dep Ensure Issue

Symptom:

When we create a new project in golang, we run "dep ensure" and get below error:
dep ensure
Solving failure: No versions of k8s.io/gengo met constraints:
        master: unable to update checked out version: fatal: reference is not a tree: f8a0810f38afb8478882b3835a615aebfda39afa
: command failed: [git checkout f8a0810f38afb8478882b3835a615aebfda39afa]: exit status 128

Solution:

Use "dep ensure -v"  to get debug information and find out which packages have check out issues
In this example, k8s.io/gengo  has issues.

It is very likely  dep cache corrupted on this package when new version of our apps or tools being added 

We need to delete dep cache of k8s.io/gengo

rm -rf  $GOPATH/go/dep/source/https---github.com-kubernetes-gengo

rerun dep ensure


5 comments:

  1. A cool and adorable collection of happy birthday images and wishes for free download. Feel free to share the images under the category 'BetterHalf' through any .Happy Birthday Gorgeous Lady

    ReplyDelete
  2. This comment has been removed by the author.

    ReplyDelete
  3. SWhat is the REAL Secret to Making the Law of Attraction Work for You Right NOW? At last! Bestselling author and Secret movie star Dr. Joe Vitale reveals for .Instant-Manifestation
    .

    ReplyDelete
  4. Are you love action game ? PUBG Lite is latest version has features various game modes, including classic, arcade, and training mode.

    ReplyDelete