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

Incorrect repository layour for v2 Go Modules #208

Closed
jsafrane opened this issue Jan 23, 2020 · 2 comments · Fixed by #209
Closed

Incorrect repository layour for v2 Go Modules #208

jsafrane opened this issue Jan 23, 2020 · 2 comments · Fixed by #209

Comments

@jsafrane
Copy link
Contributor

From kubernetes-csi/external-snapshotter#239:

$ go get -v github.com/kubernetes-csi/[email protected]
go get github.com/kubernetes-csi/[email protected]: github.com/kubernetes-csi/[email protected]: invalid version: module contains a go.mod file, so major version must be compatible: should be v0 or v1, not v2

See kubernetes-csi/external-snapshotter#240 for a fix.

@alex1989hu
Copy link
Contributor

Do you need dep compatibility with all of its side effect (e.g. symlink creation in v2 directory)?

@alex1989hu
Copy link
Contributor

To verify: https://sum.golang.org/lookup/github.com/kubernetes-csi/external-attacher/[email protected]

Example go.mod

 module github.com/foo/bar

 go 1.13

 require (
     github.com/kubernetes-csi/external-attacher/v2 v2.1.1
 )

Import statements have to be updated to use it correctly:

package main

import (
	"github.com/kubernetes-csi/external-attacher/v2/pkg/controller"
)

// Your code here

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