glide icon indicating copy to clipboard operation
glide copied to clipboard

Error 128 on glide install

Open brasilikum opened this issue 9 years ago • 3 comments

I did the following on machine a

glide init
glide install
git add .
git commit
git push

when I cloned the repo on machine b and tried glide install, i got error 128

glide install
[INFO] Downloading dependencies. Please wait...
[INFO] Fetching updates for github.com/onsi/ginkgo.
[INFO] Fetching updates for github.com/onsi/gomega.
[INFO] Fetching updates for github.com/Sirupsen/logrus.
[WARN] Download failed.
[ERROR] Update failed for github.com/onsi/ginkgo: exit status 1
[WARN] Download failed.
[ERROR] Update failed for github.com/Sirupsen/logrus: exit status 1
[INFO] Downloading dependencies. Please wait...
[INFO] Setting references.
[INFO] Setting version for github.com/onsi/ginkgo to ac3d45ddd7ef5c4d7fc4d037b615a81f4d67981e.
[INFO] Setting version for github.com/onsi/gomega to a1094b2db2d4845621602c667bd4ccf09834544e.
[INFO] Setting version for github.com/Sirupsen/logrus to 57cce1ed6103dce7791881d3e69e55f90d986aa5.
[ERROR] Failed to set version to ac3d45ddd7ef5c4d7fc4d037b615a81f4d67981e: exit status 128
[ERROR] Failed to set version on github.com/onsi/ginkgo to ac3d45ddd7ef5c4d7fc4d037b615a81f4d67981e: exit status 128
[ERROR] Failed to set version to a1094b2db2d4845621602c667bd4ccf09834544e: exit status 128
[ERROR] Failed to set version on github.com/onsi/gomega to a1094b2db2d4845621602c667bd4ccf09834544e: exit status 128
[ERROR] Failed to set version to 57cce1ed6103dce7791881d3e69e55f90d986aa5: exit status 128
[ERROR] Failed to set version on github.com/Sirupsen/logrus to 57cce1ed6103dce7791881d3e69e55f90d986aa5: exit status 128

I searched through some issues and got the hint about the empty project directories.

.
(...)
└── vendor
    └── github.com
        ├── Sirupsen
        │   └── logrus
        └── onsi
            ├── ginkgo
            └── gomega

when I removed everything in vendor/, glide install worked as expected.

What do you recommend for handling this? Should git ignore /* vendor? Should I add the vendor packages as submodules?

brasilikum avatar Feb 23 '16 11:02 brasilikum

What version of Glide are you using (glide --version)? What version of Go and what operating system are you on?

Is the project you're working on public?i If so, I'm happy to take a look at it.

There should be two state. If you see another one, please let me know.

  1. You ignore the vendor/ folder. In that case Glide will create and populate it.
  2. Your packages being vendored (stored in your projects VCS) in the vendor/ folder. If that happens you'll see messages such as gopkg.in/yaml.v2 appears to be a vendored package. Unable to update. Consider the '--update-vendored' flag. Glide detects packages without a VCS directory and you can opt-in to updating those by using a flag.

It looks like there was some problem along the way or the vendor/ directory is in some state. If I had enough information to reproduce I might be able to help more.

mattfarina avatar Feb 23 '16 20:02 mattfarina

Unfortunately, the project is not public. It is worth noting that the vendored projectfolders appear to be git submodules. If I run git submodule status i get No submodule mapping found in .gitmodules for path 'vendor/github.com/Sirupsen/logrus' and there is no .gitmodules file.

I use glide 0.9.0 on OSX El Capitan.

I prefer solution 2 as I like the idea of reproducible builds.

brasilikum avatar Feb 24 '16 10:02 brasilikum

Same Error happens on Glide v.0.13.1 and Golang 1.9.4

D:\go_workspace\src\hero0926-api-test>glide install
[INFO]  Lock file (glide.lock) does not exist. Performing update.
[INFO]  Downloading dependencies. Please wait...
[INFO]  --> Fetching updates for github.com/gorilla/mux
[WARN]  Download failed.
[ERROR] Update failed for github.com/gorilla/mux: Unable to update repository: exit status 128
[ERROR] Failed to do initial checkout of config: Unable to update repository: exit status 128

sinramyeon avatar Feb 23 '18 14:02 sinramyeon