Skip to content

Commit

Permalink
Require a valid version of github.com/openshift/api (#5132)
Browse files Browse the repository at this point in the history
* Require a valid version of github.com/openshift/api

If you run go mod tidy it fails with:

	go: downloading github.com/openshift/api v3.9.0+incompatible
	unknown revision v3.9.0

The go.sum points to github.com/openshift/api@v3.9.0 but this version does
not exist, it was retracted in openshift/api#1515

Added a replace directive to pin the library to a known commit that points
to the now retracted v3.9.0 release.

* add comment to replace directive

* make notice
  • Loading branch information
mauri870 authored Jul 24, 2024
1 parent 3f363ff commit 907cfa7
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
1 change: 1 addition & 0 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ linters-settings:
- github.com/dop251/goja
- github.com/dop251/goja_nodejs
- github.com/fsnotify/fsnotify
- github.com/openshift/api
- github.com/tonistiigi/fifo

gosimple:
Expand Down
4 changes: 2 additions & 2 deletions NOTICE.txt
Original file line number Diff line number Diff line change
Expand Up @@ -38403,11 +38403,11 @@ Contents of probable licence file $GOMODCACHE/github.com/opencontainers/image-sp

--------------------------------------------------------------------------------
Dependency : github.com/openshift/api
Version: v3.9.0+incompatible
Version: v0.0.0-20180801171038-322a19404e37
Licence type (autodetected): Apache-2.0
--------------------------------------------------------------------------------

Contents of probable licence file $GOMODCACHE/github.com/openshift/api@v3.9.0+incompatible/LICENSE:
Contents of probable licence file $GOMODCACHE/github.com/openshift/api@v0.0.0-20180801171038-322a19404e37/LICENSE:

Apache License
Version 2.0, January 2004
Expand Down
3 changes: 3 additions & 0 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -340,6 +340,9 @@ replace (
github.com/Shopify/sarama => github.com/elastic/sarama v1.19.1-0.20220310193331-ebc2b0d8eef3
github.com/dop251/goja => github.com/andrewkroh/goja v0.0.0-20190128172624-dd2ac4456e20
github.com/dop251/goja_nodejs => github.com/dop251/goja_nodejs v0.0.0-20171011081505-adff31b136e6
// openshift removed all tags from their repo, use the pseudoversion from the release-3.9 branch HEAD
// See https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/12d41f40b0d408b0167633d8095160d3343d46ac/go.mod#L38
github.com/openshift/api v3.9.0+incompatible => github.com/openshift/api v0.0.0-20180801171038-322a19404e37
github.com/tonistiigi/fifo => github.com/containerd/fifo v0.0.0-20190816180239-bda0ff6ed73c
)

Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -1345,9 +1345,9 @@ github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8
github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM=
github.com/opencontainers/image-spec v1.1.0 h1:8SG7/vwALn54lVB/0yZ/MMwhFrPYtpEHQb2IpWsCzug=
github.com/opencontainers/image-spec v1.1.0/go.mod h1:W4s4sFTMaBeK1BQLXbG4AdM2szdn85PY75RI83NrTrM=
github.com/openshift/api v0.0.0-20180801171038-322a19404e37 h1:05irGU4HK4IauGGDbsk+ZHrm1wOzMLYjMlfaiqMrBYc=
github.com/openshift/api v0.0.0-20180801171038-322a19404e37/go.mod h1:dh9o4Fs58gpFXGSYfnVxGR9PnV53I8TW84pQaJDdGiY=
github.com/openshift/api v0.0.0-20210521075222-e273a339932a/go.mod h1:izBmoXbUu3z5kUa4FjZhvekTsyzIWiOoaIgJiZBBMQs=
github.com/openshift/api v3.9.0+incompatible h1:fJ/KsefYuZAjmrr3+5U9yZIZbTOpVkDDLDLFresAeYs=
github.com/openshift/api v3.9.0+incompatible/go.mod h1:dh9o4Fs58gpFXGSYfnVxGR9PnV53I8TW84pQaJDdGiY=
github.com/openshift/build-machinery-go v0.0.0-20210423112049-9415d7ebd33e/go.mod h1:b1BuldmJlbA/xYtdZvKi+7j5YGB44qJUJDZ9zwiNCfE=
github.com/openshift/client-go v0.0.0-20210521082421-73d9475a9142 h1:ZHRIMCFIJN1p9LsJt4HQ+akDrys4PrYnXzOWI5LK03I=
github.com/openshift/client-go v0.0.0-20210521082421-73d9475a9142/go.mod h1:fjS8r9mqDVsPb5td3NehsNOAWa4uiFkYEfVZioQ2gH0=
Expand Down

0 comments on commit 907cfa7

Please sign in to comment.