FairwindsOps/pluto

Go 1.16 Deprecates IOUtil; lint fails build

freeone3000 opened this issue · 0 comments

What happened?

Building from master using go 1.19.5 (released October 2022) fails lint with the error in the "reproduction" section.

What did you expect to happen?

Build from master should succeed.

How can we reproduce this?

~/IdeaProjects/pluto/ git:(master) $ make
golangci-lint run
cmd/root.go:34:2: SA1019: "io/ioutil" has been deprecated since Go 1.16: As of Go 1.16, the same functionality is now provided by package io or package os, and those implementations should be preferred in new code. See the specific function documentation for details. (staticcheck)
	"io/ioutil"
	^
pkg/finder/finder.go:33:2: SA1019: "io/ioutil" has been deprecated since Go 1.16: As of Go 1.16, the same functionality is now provided by package io or package os, and those implementations should be preferred in new code. See the specific function documentation for details. (staticcheck)
	"io/ioutil"
	^
make: *** [lint] Error 1
~/IdeaProjects/pluto/ git:(master) $ go version  
go version go1.19.5 darwin/arm64

Version

1.19.5

Search

  • I did search for other open and closed issues before opening this.

Code of Conduct

  • I agree to follow this project's Code of Conduct

Additional context

will be submitting a potential fix for this shortly; it seems an easy fix