dep ensure "cannot Stat" no such file or directory on symlink

Created on 28 Sep 2018  Â·  5Comments  Â·  Source: golang/dep

What version of dep are you using (dep version)?

dep:
version : v0.5.0
build date : 2018-08-16
git hash : 224a564
go version : go1.10.3
go compiler : gc
platform : darwin/amd64
features : ImportDuringSolve=false

What dep command did you run?

dep ensure -v
...
(47)  ? attempt github.com/hashicorp/serf with 1 pkgs; 29 versions to try
(50)      try github.com/hashicorp/[email protected]
(50)  ✓ select github.com/hashicorp/[email protected] w/1 pkgs
  ✓ found solution with 82 packages from 47 projects

Solver wall times by segment:
     b-list-versions: 1m35.828292927s
         b-list-pkgs:   11.963157157s
              b-gmal:   10.117297237s
     b-source-exists:    7.900498959s
  b-deduce-proj-root:    1.483787317s
             satisfy:     15.204381ms
         select-atom:     11.762198ms
         select-root:      7.808046ms
            new-atom:      1.812363ms
               other:       313.755µs
            add-atom:        21.476µs

  TOTAL: 2m7.329955816s

cannot Stat: stat /Users/uudashr/go/src/bitbucket.org/me/myproject/vendor/github.com/hashicorp/go-rootcerts/test-fixtures/capath-with-symlinks/securetrust.pem: no such file or directory

What did you expect to see?

Should finish the dep ensure command

What did you see instead?

The command exited with status code 1

Most helpful comment

FWIW, I seemed to have run into a similar issue with a different package. I was able to fix it by deleting my vendor/ directory and then running dep ensure once again. I did not have to downgrade dep.

All 5 comments

I see this as will with k8s.io/kubernetes. Same version of dep on mojave.

Downgrading temporarily to 0.4.1 worked for me

FWIW, I seemed to have run into a similar issue with a different package. I was able to fix it by deleting my vendor/ directory and then running dep ensure once again. I did not have to downgrade dep.

What is dep's desired behavior if the symlinked file no longer exists? That's what seems to be the case with the k8s dependencies.

this appears to be caused by https://github.com/golang/dep/issues/1625 - in this case vendor/github.com/hashicorp/go-rootcerts/test-fixtures/capath-with-symlinks/securetrust.pem exists & is a symlink, but the file that it links to has been pruned.

Dep was officially deprecated earlier this year, and the proposal to archive this repository was accepted. As such, I'm closing outstanding issues before archiving the repository. For any further comments, please use the proposal thread on the Go issue tracker. Thanks!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

cemremengu picture cemremengu  Â·  3Comments

rustyx picture rustyx  Â·  3Comments

mohanraj-r picture mohanraj-r  Â·  3Comments

alecthomas picture alecthomas  Â·  3Comments

eleijonmarck picture eleijonmarck  Â·  3Comments