soundcloud / roshi

Roshi is a large-scale CRDT set implementation for timestamped events.
BSD 2-Clause "Simplified" License
3.15k stars 154 forks source link

Vendor missing transitive dependencies #27

Closed nickstenning closed 10 years ago

nickstenning commented 10 years ago

Checking out roshi into a clean $GOPATH and running (from the repo root)

make -C roshi-server

currently fails because the following dependencies of github.com/prometheus/client_golang are missing:

github.com/matttproud/golang_protobuf_extensions
github.com/prometheus/client_model

This PR fixes that by including both libraries as git subtrees in the _vendor/ directory.

I don't presume to know what your policy is for vendoring transitive deps, but I had a quick chat with @peterbourgon on Twitter who suggested I submit this PR.

I've vendored both at master from their respective repositories. This is presumably safe for prometheus/client_model, which hasn't changed since last November. I considered vendoring matttproud/golang_protobuf_extensions at the commit it would have been at when you last updated your copy of prometheus/client_golang, but a glance at the commit log suggests that some rather important bugs have been fixed in the intervening period.

After this PR, the following command sequence works on a clean installation with an empty $GOPATH, where it didn't before:

git clone https://github.com/.../roshi
make -C roshi/roshi-server
make -C roshi/roshi-walker
GOPATH="$PWD/roshi/_vendor/:$GOPATH" go test ./roshi/...
peterbourgon commented 10 years ago

Yep! Those extra deps came in with the new version of the prometheus client lib, and neither I nor the committer caught them at the time. Thanks!