Skip to content
This repository was archived by the owner on Aug 23, 2023. It is now read-only.

bogus test flags in usage output of some of our executables #862

Closed
Dieterbe opened this issue Mar 6, 2018 · 2 comments
Closed

bogus test flags in usage output of some of our executables #862

Dieterbe opened this issue Mar 6, 2018 · 2 comments
Milestone

Comments

@Dieterbe
Copy link
Contributor

Dieterbe commented Mar 6, 2018

when #858 is merged, we have this problem:

github.com/grafana/metrictank/api imports github.com/prometheus/prometheus/promql, and see
prometheus/prometheus#3915

furthermore, metrictank, mt-store-cat, and mt-whisper-importer-reader import github.com/grafana/metrictank/api so those programs get all the irrelevant test flags.
which results in convoluted help/usage output.
not only that, but since some of the output is based on number of processors, we needed 950c786 to keep the CI scripts from failing.

@Dieterbe
Copy link
Contributor Author

Dieterbe commented Aug 6, 2018

we should now be able to clean this up.
prometheus/prometheus#4400

@Dieterbe Dieterbe added this to the 0.10.0 milestone Aug 17, 2018
@Dieterbe
Copy link
Contributor Author

updating the prometheus code is non-trivial:

make
make all
make[1]: Entering directory '/home/dieter/go/src/github.com/grafana/metrictank'
make bin
make[2]: Entering directory '/home/dieter/go/src/github.com/grafana/metrictank'
./scripts/build.sh
+ go build -ldflags '-X main.gitHash=0.9.0-267-g9c5f84c' -o /home/dieter/go/src/github.com/grafana/metrictank/build/metrictank
# github.com/grafana/metrictank/api
../../api/api.go:74:38: not enough arguments in call to promql.NewEngine
	have (*Server, nil)
	want ("github.com/grafana/metrictank/vendor/github.com/go-kit/kit/log".Logger, prometheus.Registerer, int, time.Duration)
../../api/prometheus.go:138:45: not enough arguments in call to s.PromQueryEngine.NewRangeQuery
	have (string, time.Time, time.Time, time.Duration)
	want (storage.Queryable, string, time.Time, time.Time, time.Duration)
../../api/prometheus.go:182:47: not enough arguments in call to s.PromQueryEngine.NewInstantQuery
	have (string, time.Time)
	want (storage.Queryable, string, time.Time)
../../api/prometheus.go:246:21: not enough arguments in call to q.Select
	have ([]*labels.Matcher...)
	want (*storage.SelectParams, ...*labels.Matcher)
../../api/prometheus_querier.go:44:3: cannot use querier literal (type *querier) as type storage.Querier in return argument:
	*querier does not implement storage.Querier (wrong type for Select method)
		have Select(...*labels.Matcher) (storage.SeriesSet, error)
		want Select(*storage.SelectParams, ...*labels.Matcher) (storage.SeriesSet, error)
+ fail
+ echo 'Aborting due to failure.'
Aborting due to failure.
+ exit 2
make[2]: *** [Makefile:9: bin] Error 2
make[2]: Leaving directory '/home/dieter/go/src/github.com/grafana/metrictank'
make[1]: *** [Makefile:15: all] Error 2
make[1]: Leaving directory '/home/dieter/go/src/github.com/grafana/metrictank'
make: *** [Makefile:3: default] Error 2

and all of our prometheus people have more important stuff going on than this.

@Dieterbe Dieterbe modified the milestones: 1.0, 0.10.0 Dec 12, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant