Change:
Please see We have a lot of references to which we need to migrate to newer package(s) mentioned in the url above: * We also need some verify scripts to ensure we don't add back this package /area code-organization
There are no sig labels on this issue. Please add an appropriate label by using one of the following commands: - Please see the for a listing of the SIGs, working groups, and committees available. <detailsInstructions for interacting with me using PR comments are available . If you have questions or suggestions related to my behavior, please file an issue against the repository. </details
This issue is currently awaiting triage. If a SIG or subproject determines this is a relevant issue, they will accept it by applying the label and provide further guidance. The label can be by org members by writing in a comment. <detailsInstructions for interacting with me using PR comments are available . If you have questions or suggestions related to my behavior, please file an issue against the repository. </details
/sig architecture (seems like this cuts across everything!)
The package is deprecated but is not planned for removal. Switching is fine, but this is not urgent
mind if I take a look at this ? /assign
Ack !
For the script to verify the and ensure we don't add this back again, can I modify the existing toolchain to add a new field with similar behavior support as that of ?
ioutil is extremely widely used, and is not actually a problem to continue using... make sure the importverifier doesn't complain if we depend on it transitively via a vendored dependency
Sure. I will keep that in mind. I will enable this as a soft warning behavior if that is all right with everyone so that we can warn them but not fail the check right-away. Once we decide to enforce it, we can switch the config to fail the checks.
I'm skeptical that this is worth the effort to warn/sweep existing code
ack on the warn/verify we can deal with that later (i'll check on possibilities). let's focus this issue to just the bulk replace
Ack. Thanks
Most of the methods in ioutil have relatively simple implementations that seem stable, doubly so if it's deprecated If go isn't planning to remove this package any time soon I'm also not sure it's worth the cost of forcing library consumers to use go1.16+?
Issues go stale after 90d of inactivity. Mark the issue as fresh with . Stale issues rot after an additional 30d of inactivity and eventually close. If this issue is safe to close now please do so with . Send feedback to sig-contributor-experience at . /lifecycle stale
/remove-lifecycle stale /priority important-longterm (based on Please feel to correct, if otherwise)
The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs. This bot triages issues and PRs according to the following rules: After 90d of inactivity, is applied After 30d of inactivity since was applied, is applied After 30d of inactivity since was applied, the issue is closed You can: Mark this issue or PR as fresh with Mark this issue or PR as rotten with Close this issue or PR with Offer to help out with [Issue Triage][1] Please send feedback to sig-contributor-experience at . /lifecycle stale [1]:
/remove-lifecycle stale /lifecycle frozen
looks like people are still submitting PRs on this topic and they are not getting reviewed. From Go perspective there's no update since the 1.16 announcement (AFAIK). Should we revisit this goal?
This issue is currently awaiting triage. If a SIG or subproject determines this is a relevant issue, they will accept it by applying the label and provide further guidance. The label can be by org members by writing in a comment. <detailsInstructions for interacting with me using PR comments are available . If you have questions or suggestions related to my behavior, please file an issue against the repository. </details
Go compatibility means the deprecated functions will not be removed. I'm not in favor of this goal... I think it's churn with little purpose.
/close
Closing this issue. <detailsIn response to : /close Instructions for interacting with me using PR comments are available . If you have questions or suggestions related to my behavior, please file an issue against the repository. </details

Discussion:
package testing import ( <del> "io/ioutil" </del> "math/rand" <ins> "os" </ins> "testing" "github.com/google/go-cmp/cmp"

} func BenchmarkNodeConversion(b *testing.B) { <del> data, err := ioutil.ReadFile("node_example.json") </del> <ins> data, err := os.ReadFile("node_example.json") </ins> if err != nil { b.Fatalf("Unexpected error while reading file: %v", err) }

} func BenchmarkReplicationControllerConversion(b *testing.B) { <del> data, err := ioutil.ReadFile("replication_controller_example.json") </del> <ins> data, err := os.ReadFile("replication_controller_example.json") </ins> if err != nil { b.Fatalf("Unexpected error while reading file: %v", err) }

package testing import ( <del> "io/ioutil" </del> <ins> "os" </ins> "testing" "time"

} func BenchmarkNodeCopy(b *testing.B) { <del> data, err := ioutil.ReadFile("node_example.json") </del> <ins> data, err := os.ReadFile("node_example.json") </ins> if err != nil { b.Fatalf("Unexpected error while reading file: %v", err) }

} func BenchmarkReplicationControllerCopy(b *testing.B) { <del> data, err := ioutil.ReadFile("replication_controller_example.json") </del> <ins> data, err := os.ReadFile("replication_controller_example.json") </ins> if err != nil { b.Fatalf("Unexpected error while reading file: %v", err) }

"bytes" "encoding/hex" gojson "encoding/json" <del> "io/ioutil" </del> <ins> "io" </ins> "math/rand" "reflect" "testing"

if n, err := w.Write(obj.Bytes()); err != nil || n != len(obj.Bytes()) { t.Fatal(err) } <del> sr := streaming.NewDecoder(framer.NewFrameReader(ioutil.NopCloser(out)), s) </del> <ins> sr := streaming.NewDecoder(framer.NewFrameReader(io.NopCloser(out)), s) </ins> resultSecret := &v1.Secret{} res, _, err := sr.Decode(nil, resultSecret) if err != nil {

if n, err := w.Write(obj.Bytes()); err != nil || n != len(obj.Bytes()) { t.Fatal(err) } <del> sr = streaming.NewDecoder(framer.NewFrameReader(ioutil.NopCloser(out)), s) </del> <ins> sr = streaming.NewDecoder(framer.NewFrameReader(io.NopCloser(out)), s) </ins> outEvent := &metav1.WatchEvent{} _, _, err = sr.Decode(nil, outEvent) if err != nil || outEvent.Type != string(watch.Added) {