From a8ce9d3665036b01555e2d52012567cedf4cf351 Mon Sep 17 00:00:00 2001 From: Eng Zer Jun Date: Tue, 23 Jan 2024 09:07:52 +0800 Subject: [PATCH] Remove extra `github.com/pborman/uuid` dependency Currently we are using two UUID packages: 1. github.com/pborman/uuid 2. github.com/google/uuid `github.com/pborman/uuid` is no longer being actively maintained (last release was 2019). In addition, `github.com/pborman/uuid` uses `github.com/google/uuid` internally, so it is safe to replace. Signed-off-by: Eng Zer Jun --- go.mod | 1 - go.sum | 2 -- pkg/minikube/registry/drvs/hyperkit/hyperkit.go | 4 ++-- 3 files changed, 2 insertions(+), 5 deletions(-) diff --git a/go.mod b/go.mod index 295f78e405a9..a59362e013ba 100644 --- a/go.mod +++ b/go.mod @@ -48,7 +48,6 @@ require ( github.com/opencontainers/go-digest v1.0.0 github.com/opencontainers/runc v1.1.11 github.com/otiai10/copy v1.14.0 - github.com/pborman/uuid v1.2.1 github.com/phayes/freeport v0.0.0-20180830031419-95f893ade6f2 github.com/pkg/browser v0.0.0-20210911075715-681adbf594b8 github.com/pkg/errors v0.9.1 diff --git a/go.sum b/go.sum index dd938f4c8429..0a2c0d2b9ae1 100644 --- a/go.sum +++ b/go.sum @@ -1348,8 +1348,6 @@ github.com/otiai10/mint v1.5.1 h1:XaPLeE+9vGbuyEHem1JNk3bYc7KKqyI/na0/mLd/Kks= github.com/otiai10/mint v1.5.1/go.mod h1:MJm72SBthJjz8qhefc4z1PYEieWmy8Bku7CjcAqyUSM= github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= -github.com/pborman/uuid v1.2.1 h1:+ZZIw58t/ozdjRaXh/3awHfmWRbzYxJoAdNJxe/3pvw= -github.com/pborman/uuid v1.2.1/go.mod h1:X/NO0urCmaxf9VXbdlT7C2Yzkj2IKimNn4k+gtPdI/k= github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= github.com/pelletier/go-toml v1.7.0/go.mod h1:vwGMzjaWMwyfHwgIBhI2YUM4fB6nL6lVAvS1LBMMhTE= github.com/pelletier/go-toml v1.8.1/go.mod h1:T2/BmBdy8dvIRq1a/8aqjN41wvWlN4lrapLU/GW4pbc= diff --git a/pkg/minikube/registry/drvs/hyperkit/hyperkit.go b/pkg/minikube/registry/drvs/hyperkit/hyperkit.go index 1280fc1b348e..dfbc2a1e6e24 100644 --- a/pkg/minikube/registry/drvs/hyperkit/hyperkit.go +++ b/pkg/minikube/registry/drvs/hyperkit/hyperkit.go @@ -28,7 +28,7 @@ import ( "github.com/pkg/errors" "github.com/docker/machine/libmachine/drivers" - "github.com/pborman/uuid" + "github.com/google/uuid" "k8s.io/minikube/pkg/drivers/hyperkit" "k8s.io/minikube/pkg/minikube/config" @@ -62,7 +62,7 @@ func init() { func configure(cfg config.ClusterConfig, n config.Node) (interface{}, error) { u := cfg.UUID if u == "" { - u = uuid.NewUUID().String() + u = uuid.NewString() } return &hyperkit.Driver{