-
Notifications
You must be signed in to change notification settings - Fork 95
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
Upgrade to Go 1.18 #342
Upgrade to Go 1.18 #342
Conversation
Signed-off-by: Aditya Sharma <git@adi.run>
Signed-off-by: Aditya Sharma <git@adi.run>
Signed-off-by: Aditya Sharma <git@adi.run>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @epk !
@@ -38,15 +38,15 @@ func (e errNotFound) IsNotFound() bool { | |||
// index was out of bounds in an array. | |||
func IsNotFound(err error) bool { | |||
cause := errors.Cause(err) | |||
_, ok := cause.(interface { | |||
_, ok := cause.(interface { //nolint: errorlint // Skip errorlint for interface type |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there no way to use any
here as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
any
is only explicitly interoperable with interface{}
, here it is an interface with function definitions
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you know if there is a plan to make it available for use in these cases as well, or are we stuck with interface{}
for the foreseeable future?
return pkg, err | ||
} | ||
if err == io.EOF { | ||
if errors.Is(err, io.EOF) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just checked that errors.Is
returns the same answer for == io.EOF
by running the tests with coverage and seeing it go into this statement.
go mod tidy -compat=1.18 -go=1.18 cd build/ git fetch git checkout origin/master sed -i s,ubuntu-18.04,ubuntu-20.04,g .github/workflows/* vim .github/workflows/ci.yml inspired by crossplane/crossplane-runtime#342 Signed-off-by: Carl Henrik Lunde <chlunde@ifi.uio.no>
go mod tidy -compat=1.18 -go=1.18 cd build/ git fetch git checkout origin/master sed -i s,ubuntu-18.04,ubuntu-20.04,g .github/workflows/* vim .github/workflows/ci.yml inspired by crossplane/crossplane-runtime#342 Signed-off-by: Carl Henrik Lunde <chlunde@ifi.uio.no>
go mod tidy -compat=1.18 -go=1.18 cd build/ git fetch git checkout origin/master sed -i s,ubuntu-18.04,ubuntu-20.04,g .github/workflows/* vim .github/workflows/ci.yml inspired by crossplane/crossplane-runtime#342 Signed-off-by: Carl Henrik Lunde <chlunde@ifi.uio.no>
go mod tidy -compat=1.18 -go=1.18 cd build/ git fetch git checkout origin/master sed -i s,ubuntu-18.04,ubuntu-20.04,g .github/workflows/* vim .github/workflows/ci.yml inspired by crossplane/crossplane-runtime#342 Signed-off-by: Carl Henrik Lunde <chlunde@ifi.uio.no>
go mod tidy -compat=1.18 -go=1.18 cd build/ git fetch git checkout origin/master sed -i s,ubuntu-18.04,ubuntu-20.04,g .github/workflows/* vim .github/workflows/ci.yml inspired by crossplane/crossplane-runtime#342 Signed-off-by: Carl Henrik Lunde <chlunde@ifi.uio.no>
* Upgrade to Go 1.18 go mod tidy -compat=1.18 -go=1.18 cd build/ git fetch git checkout origin/master sed -i s,ubuntu-18.04,ubuntu-20.04,g .github/workflows/* vim .github/workflows/ci.yml inspired by crossplane/crossplane-runtime#342 * gofmt -s -l -w ./*/ Signed-off-by: Carl Henrik Lunde <chlunde@ifi.uio.no>
Signed-off-by: Aditya Sharma git@adi.run
Description of your changes
I have:
make reviewable test
to ensure this PR is ready for review.How has this code been tested