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

Retract the v1.0.0 version #916

Merged
merged 1 commit into from
Feb 3, 2022

Conversation

mtrmac
Copy link
Collaborator

@mtrmac mtrmac commented Feb 2, 2022

The v1.0.0 tag no longer exists, but the Go proxy still remembers it.

So, we see things like

skopeo % go get -u ./...
go: downloading github.com/containers/image/v5 v5.19.1
github.com/containers/skopeo/cmd/skopeo imports
	github.com/containers/common/pkg/auth: cannot find module providing package github.com/containers/common/pkg/auth
github.com/containers/skopeo/cmd/skopeo imports
	github.com/containers/common/pkg/flag: cannot find module providing package github.com/containers/common/pkg/flag
github.com/containers/skopeo/cmd/skopeo imports
	github.com/containers/common/pkg/report: cannot find module providing package github.com/containers/common/pkg/report
github.com/containers/skopeo/cmd/skopeo imports
	github.com/containers/common/pkg/retry: cannot find module providing package github.com/containers/common/pkg/retry

Try to fix that, per https://go.dev/ref/mod#go-mod-file-retract and https://play-with-go.dev/retract-module-versions_go116_en/ .

The intent is to tag this commit with v1.0.1 (and then, later,
maybe delete it).

The v1.0.0 tag no longer exists, but the Go proxy
still remembers it.

So, we see things like
> skopeo % go get -u ./...
> go: downloading github.com/containers/image/v5 v5.19.1
> github.com/containers/skopeo/cmd/skopeo imports
> 	github.com/containers/common/pkg/auth: cannot find module providing package github.com/containers/common/pkg/auth
> github.com/containers/skopeo/cmd/skopeo imports
> 	github.com/containers/common/pkg/flag: cannot find module providing package github.com/containers/common/pkg/flag
> github.com/containers/skopeo/cmd/skopeo imports
> 	github.com/containers/common/pkg/report: cannot find module providing package github.com/containers/common/pkg/report
> github.com/containers/skopeo/cmd/skopeo imports
> 	github.com/containers/common/pkg/retry: cannot find module providing package github.com/containers/common/pkg/retry

Try to fix that, per https://go.dev/ref/mod#go-mod-file-retract
and https://play-with-go.dev/retract-module-versions_go116_en/ .

The intent is to tag this commit with v1.0.1 (and then, later,
maybe delete it).

Signed-off-by: Miloslav Trmač <[email protected]>
@mtrmac
Copy link
Collaborator Author

mtrmac commented Feb 2, 2022

Hopefully fixes #914 . If this fails, we can never the go.mod update, and delete the v1.0.1 tag — that should, I think, get us basically exactly in the situation where we are now.

@rhatdan
Copy link
Member

rhatdan commented Feb 2, 2022

LGTM
@vrothberg PTAL

Copy link
Member

@vrothberg vrothberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

Note that

The retract directive was added in Go 1.16. Go 1.15 and lower will report an error if a retract directive is written in the main module’s go.mod file and will ignore retract directives in go.mod files of dependencies.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Feb 3, 2022

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: mtrmac, vrothberg

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci bot added the approved label Feb 3, 2022
@openshift-merge-robot openshift-merge-robot merged commit 2f92acf into containers:main Feb 3, 2022
@mtrmac
Copy link
Collaborator Author

mtrmac commented Feb 3, 2022

Go 1.15 and lower will report an error

Oh, that’s unfortunate. I guess we are doing that now…

@mtrmac
Copy link
Collaborator Author

mtrmac commented Feb 3, 2022

… actually, after we tag the v1.0.1, and assuming that works for recent versions, we could just revert the retraction on the v0.… branch, and if I understand the lookup correctly, that’s going to work fine.

But let’s keep things simple and only do that if someone asks for it.

@mtrmac mtrmac deleted the retract-1.0.0 branch February 3, 2022 17:49
@mtrmac
Copy link
Collaborator Author

mtrmac commented Feb 3, 2022

@rhatdan / @vrothberg Could you tag a v1.0.1 tag at commit a970d99 , please?

@rhatdan
Copy link
Member

rhatdan commented Feb 3, 2022

You want me to push this to containers/common?

@mtrmac
Copy link
Collaborator Author

mtrmac commented Feb 3, 2022

Yes, this is a c/common PR and commit, so tag it in this repo.

(And then don’t merge updates to a v1.0.1 version of c/common in Podman/Buildah/Skopeo, if this retraction didn’t work and the tools thought that v1.0.1 is a legitimate update.)

@rhatdan
Copy link
Member

rhatdan commented Feb 3, 2022

The Tag now should exists in containers/common.

@mtrmac
Copy link
Collaborator Author

mtrmac commented Feb 3, 2022

Thanks, it seems to work as expected — and containers/podman#13131 was filed by Dependabot.

@vrothberg
Copy link
Member

Great work, @mtrmac !

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

Successfully merging this pull request may close these issues.

None yet

4 participants