Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't use go install due to replace directives in go.mod #160

Closed
dmorneau opened this issue Feb 22, 2022 · 2 comments · Fixed by #163
Closed

Can't use go install due to replace directives in go.mod #160

dmorneau opened this issue Feb 22, 2022 · 2 comments · Fixed by #163

Comments

@dmorneau
Copy link

Describe the bug
go install does not work with custom-pod-autoscaler because its go.mod includes replace directives

To Reproduce

go install github.com/jthomperoo/custom-pod-autoscaler/v2@v2.4.0

Expected behavior
It would be useful if the package was compatible with go install (for context, I'm trying to install it in an existing container).

Additional context

go: downloading github.com/jthomperoo/custom-pod-autoscaler/v2 v2.4.0
go install: github.com/jthomperoo/custom-pod-autoscaler/v2@v2.4.0 (in github.com/jthomperoo/custom-pod-autoscaler/v2@v2.4.0):
	The go.mod file for the module providing named packages contains one or
	more replace directives. It must not contain directives that would cause
	it to be interpreted differently than if it were the main module.

replace (

@jthomperoo
Copy link
Owner

jthomperoo commented Feb 22, 2022

Thanks for raising this!

Unfortunately this project has a dependency on Argo Rollouts which includes a direct dependency on k8s.io/kubernetes which requires these replace directives: argoproj/argo-rollouts/issues/473

I'm looking at removing this direct dependency from this codebase, but in order to support go install I'll need to think of a way around this until Argo Rollouts removes this dependency. I don't think that will be any time soon, so the options I can think of are these:

I'll keep this issue updated with any progress.

@jthomperoo
Copy link
Owner

This is now available in version v2.5.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants