Stackdriver / stackdriver-prometheus-sidecar

A sidecar for the Prometheus server that can send metrics to Stackdriver.
https://cloud.google.com/monitoring/kubernetes-engine/prometheus
Apache License 2.0
120 stars 43 forks source link

Test fails caused by github.com/apache/thrift and git.apache.org/thrift.git #176

Closed StevenYCChou closed 4 years ago

StevenYCChou commented 4 years ago

Seeing compilation error when running test locally with make test:

ycchou@ycchou44:~/src/stackdriver-prometheus-sidecar$ make test
>> running all tests
GO111MODULE=on go test  -mod=vendor ./...
?       github.com/Stackdriver/stackdriver-prometheus-sidecar/bench     [no test files]
compilation error :go: github.com/apache/thrift@v0.12.0 used for two different module paths (git.apache.org/thrift.git and github.com/apache/thrift)

FAIL    github.com/Stackdriver/stackdriver-prometheus-sidecar/cmd/stackdriver-prometheus-sidecar        0.252s
ok      github.com/Stackdriver/stackdriver-prometheus-sidecar/metadata  (cached)
ok      github.com/Stackdriver/stackdriver-prometheus-sidecar/retrieval (cached)
ok      github.com/Stackdriver/stackdriver-prometheus-sidecar/stackdriver       (cached)
ok      github.com/Stackdriver/stackdriver-prometheus-sidecar/tail      (cached)
ok      github.com/Stackdriver/stackdriver-prometheus-sidecar/targets   (cached)
FAIL
make: *** [Makefile:74: test] Error 1

Seems like there some other code will use git.apache.org/thrift.git even we merge the https://github.com/Stackdriver/stackdriver-prometheus-sidecar/pull/170 to replace git.apache.org with github.com/apache.

StevenYCChou commented 4 years ago

Somehow I run make test again it doesn't fail anymore.

 make test
>> running all tests
GO111MODULE=on go test  -mod=vendor ./...
?       github.com/Stackdriver/stackdriver-prometheus-sidecar/bench [no test files]
ok      github.com/Stackdriver/stackdriver-prometheus-sidecar/cmd/stackdriver-prometheus-sidecar    (cached)
ok      github.com/Stackdriver/stackdriver-prometheus-sidecar/metadata  (cached)
ok      github.com/Stackdriver/stackdriver-prometheus-sidecar/retrieval (cached)
ok      github.com/Stackdriver/stackdriver-prometheus-sidecar/stackdriver   (cached)
ok      github.com/Stackdriver/stackdriver-prometheus-sidecar/tail  (cached)
ok      github.com/Stackdriver/stackdriver-prometheus-sidecar/targets   (cached)

Couldn't reproduce the issue anymore. Will close this issue now.