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

Usage of go mod is not compatible with go1.18 #6586

Closed
zhsj opened this issue Feb 24, 2022 · 3 comments
Closed

Usage of go mod is not compatible with go1.18 #6586

zhsj opened this issue Feb 24, 2022 · 3 comments
Assignees
Labels

Comments

@zhsj
Copy link
Contributor

zhsj commented Feb 24, 2022

Description

With go1.18, I get

go: inconsistent vendoring in /home/zhsj/go/src/github.com/containerd/containerd:
        github.com/containerd/containerd: is marked as replaced in vendor/modules.txt, but not replaced in go.mod

        To ignore the vendor directory, use -mod=readonly or -mod=mod.
        To sync the vendor directory, run:
                go mod vendor

Go upstream thinks it should be fixed in containerd instead. Ref golang/go#51285

Steps to reproduce the issue

Describe the results you received and expected

No error

What version of containerd are you using?

main

Any other relevant information

No response

Show configuration if it is related to CRI plugin.

No response

@zhsj zhsj added the kind/bug label Feb 24, 2022
@kzys kzys self-assigned this Mar 7, 2022
@williamh
Copy link

We are now hitting this in Gentoo Linux also. https://bugs.gentoo.org/835367

kzys added a commit to kzys/containerd that referenced this issue Mar 16, 2022
The empty-mod hack no longer works with Go 1.18.

This commit fixes containerd#6586.

Signed-off-by: Kazuyoshi Kato <katokazu@amazon.com>
kzys added a commit to kzys/containerd that referenced this issue Mar 16, 2022
The empty-mod hack no longer works with Go 1.18.

This commit fixes containerd#6586.

Signed-off-by: Kazuyoshi Kato <katokazu@amazon.com>
kzys added a commit to kzys/containerd that referenced this issue Mar 18, 2022
The empty-mod hack no longer works with Go 1.18.

This commit fixes containerd#6586.

Signed-off-by: Kazuyoshi Kato <katokazu@amazon.com>
@AkihiroSuda
Copy link
Member

Reopening until we fix 1.6/1.5
#6605 (comment)

@AkihiroSuda AkihiroSuda reopened this Mar 22, 2022
@kzys
Copy link
Member

kzys commented May 4, 2022

#6717 was 1.6 backport. #6716 was 1.5 backport.

@kzys kzys closed this as completed May 4, 2022
copybara-service bot pushed a commit to google/gvisor that referenced this issue Oct 13, 2022
These versions are compatible with Go 1.18. There are a lot of OSS bugs
about this issue. Notable discussions:
- golang/go#51285
- containerd/containerd#6586

This was fixed upstream in the main branch in containerd/containerd#6605.
The fix was back-ported to v1.5 and v1.6 in containerd/containerd#6716
and containerd/containerd#6717 respectively.

These backports are available in the following versions:
```shell
/tmp/gopathJJGZf/containerd$ git tag --contains 765df66099eec88d0365eaa1e9a933877a058f0b
v1.6.2
v1.6.3
v1.6.4
v1.6.5
v1.6.6
v1.6.7
v1.6.8
/tmp/gopathJJGZf/containerd$ git tag --contains 86bec213720b54bf9ea2813e2c2a577271af58d3
v1.5.11
v1.5.12
v1.5.13
```

So use the smallest versions out of them.

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

No branches or pull requests

4 participants