Skip to content
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

Update deps #4181

Merged
merged 7 commits into from
Feb 12, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/checkLicenses.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
- run: |
./scripts/create-licenses.sh
# Upload the licenses list so it's available if needed
- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
with:
name: Licenses
path: LICENSES.txt
Expand Down
8 changes: 2 additions & 6 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,13 @@

run:
deadline: 5m
skip-dirs:
thirdparty/

linters:
# please, do not use `enable-all`: it's deprecated and will be removed soon.
# inverted configuration with `enable-all` and `disable` is not scalable during updates of golangci-lint
disable-all: true
enable:
- bodyclose
- deadcode
- depguard
- dogsled
- dupl
- errcheck
Expand All @@ -33,19 +29,19 @@ linters:
- misspell
- nakedret
- staticcheck
- structcheck
- stylecheck
- revive
- typecheck
- unconvert
- unparam
- unused
- varcheck
- whitespace

issues:
exclude:
- Using the variable on range scope `tc` in function literal
exclude-dirs:
- thirdparty/

linters-settings:
dupl:
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ install-kind:

.PHONY: install-golangci-lint
install-golangci-lint:
go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.52.2
go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.60.1

.PHONY: install-go-licenses
install-go-licenses:
Expand Down
2 changes: 1 addition & 1 deletion commands/alpha/alphacmd.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ func GetCommand(ctx context.Context, _, version string) *cobra.Command {
Use: "alpha",
Short: alphadocs.AlphaShort,
Long: alphadocs.AlphaLong,
RunE: func(cmd *cobra.Command, args []string) error {
RunE: func(cmd *cobra.Command, _ []string) error {
h, err := cmd.Flags().GetBool("help")
if err != nil {
return err
Expand Down
2 changes: 1 addition & 1 deletion commands/alpha/license/command.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ func NewCommand(ctx context.Context, _ string) *cobra.Command {
Use: "license",
Short: "[Alpha] " + licensedocs.LicenseShort,
Long: "[Alpha] " + licensedocs.LicenseShort + "\n" + licensedocs.LicenseLong,
RunE: func(cmd *cobra.Command, args []string) error {
RunE: func(cmd *cobra.Command, _ []string) error {
h, err := cmd.Flags().GetBool("help")
if err != nil {
return err
Expand Down
2 changes: 1 addition & 1 deletion commands/alpha/rollouts/rolloutscmd.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ func NewCommand(ctx context.Context, version string) *cobra.Command {
Use: "rollouts",
Short: "rollouts",
Long: "rollouts",
RunE: func(cmd *cobra.Command, args []string) error {
RunE: func(cmd *cobra.Command, _ []string) error {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We probably should just turn off this linter, it isn't useful / correct

h, err := cmd.Flags().GetBool("help")
if err != nil {
return err
Expand Down
2 changes: 1 addition & 1 deletion commands/fn/doc/cmdfndoc.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ func NewRunner(ctx context.Context, parent string) *Runner {
}
r.Command = c
c.Flags().StringVarP(&r.Image, "image", "i", "", "kpt function image name")
_ = r.Command.RegisterFlagCompletionFunc("image", func(cmd *cobra.Command, args []string, toComplete string) ([]string, cobra.ShellCompDirective) {
_ = r.Command.RegisterFlagCompletionFunc("image", func(cmd *cobra.Command, _ []string, _ string) ([]string, cobra.ShellCompDirective) {
return cmdutil.SuggestFunctions(cmd), cobra.ShellCompDirectiveDefault
})
cmdutil.FixDocs("kpt", parent, c)
Expand Down
2 changes: 1 addition & 1 deletion commands/fn/fncmd.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ func GetCommand(ctx context.Context, name string) *cobra.Command {
Short: fndocs.FnShort,
Long: fndocs.FnLong,
Aliases: []string{"functions"},
RunE: func(cmd *cobra.Command, args []string) error {
RunE: func(cmd *cobra.Command, _ []string) error {
h, err := cmd.Flags().GetBool("help")
if err != nil {
return err
Expand Down
2 changes: 1 addition & 1 deletion commands/fn/render/cmdrender.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ func NewRunner(ctx context.Context, parent string) *Runner {

c.Flags().Var(&r.RunnerOptions.ImagePullPolicy, "image-pull-policy",
"pull image before running the container "+r.RunnerOptions.ImagePullPolicy.HelpAllowedValues())
_ = c.RegisterFlagCompletionFunc("image-pull-policy", func(cmd *cobra.Command, args []string, toComplete string) ([]string, cobra.ShellCompDirective) {
_ = c.RegisterFlagCompletionFunc("image-pull-policy", func(_ *cobra.Command, _ []string, _ string) ([]string, cobra.ShellCompDirective) {
return r.RunnerOptions.ImagePullPolicy.AllStrings(), cobra.ShellCompDirectiveDefault
})

Expand Down
2 changes: 1 addition & 1 deletion commands/fn/render/cmdrender_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,4 +44,4 @@ func TestCmd_flagAndArgParsing_Symlink(t *testing.T) {
}

// NoOpRunE is a noop function to replace the run function of a command. Useful for testing argument parsing.
var NoOpRunE = func(cmd *cobra.Command, args []string) error { return nil }
var NoOpRunE = func(_ *cobra.Command, _ []string) error { return nil }
2 changes: 1 addition & 1 deletion commands/live/migrate/migratecmd.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ func NewRunner(
Short: livedocs.MigrateShort,
Long: livedocs.MigrateShort + "\n" + livedocs.MigrateLong,
Example: livedocs.MigrateExamples,
RunE: func(cmd *cobra.Command, args []string) error {
RunE: func(_ *cobra.Command, args []string) error {
if len(args) == 0 {
// default to current working directory
args = append(args, ".")
Expand Down
4 changes: 2 additions & 2 deletions commands/live/migrate/migratecmd_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ func TestKptMigrate_migrateKptfileToRG(t *testing.T) {
migrateRunner := NewRunner(ctx, tf, cmLoader, ioStreams)
migrateRunner.dryRun = tc.dryRun
migrateRunner.rgFile = tc.rgFilename
migrateRunner.cmInvClientFunc = func(factory util.Factory) (inventory.Client, error) {
migrateRunner.cmInvClientFunc = func(_ util.Factory) (inventory.Client, error) {
return inventory.NewFakeClient([]object.ObjMetadata{}), nil
}
err = migrateRunner.migrateKptfileToRG([]string{dir})
Expand Down Expand Up @@ -242,7 +242,7 @@ func TestKptMigrate_retrieveConfigMapInv(t *testing.T) {
// Create MigrateRunner and call "retrieveConfigMapInv"
cmLoader := manifestreader.NewManifestLoader(tf)
migrateRunner := NewRunner(ctx, tf, cmLoader, ioStreams)
migrateRunner.cmInvClientFunc = func(factory util.Factory) (inventory.Client, error) {
migrateRunner.cmInvClientFunc = func(_ util.Factory) (inventory.Client, error) {
return inventory.NewFakeClient([]object.ObjMetadata{}), nil
}
actual, err := migrateRunner.retrieveConfigMapInv(strings.NewReader(tc.configMap), []string{"-"})
Expand Down
2 changes: 1 addition & 1 deletion commands/live/status/cmdstatus_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@ foo/deployment.apps/default/foo is InProgress: inProgress
invFactory := inventory.FakeClientFactory(tc.inventory)
loader := NewFakeLoader(ctx, tf, tc.inventory)
runner := NewRunner(ctx, tf, invFactory, loader)
runner.PollerFactoryFunc = func(c cmdutil.Factory) (poller.Poller, error) {
runner.PollerFactoryFunc = func(_ cmdutil.Factory) (poller.Poller, error) {
return &fakePoller{tc.events}, nil
}

Expand Down
2 changes: 1 addition & 1 deletion commands/pkg/diff/cmddiff_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -91,4 +91,4 @@ func TestCmd_flagAndArgParsing_Symlink(t *testing.T) {
assert.Equal(t, filepath.Join(cwd, "path", "to", "pkg", "dir"), r.Path)
}

var NoOpRunE = func(cmd *cobra.Command, args []string) error { return nil }
var NoOpRunE = func(_ *cobra.Command, _ []string) error { return nil }
2 changes: 1 addition & 1 deletion commands/pkg/get/cmdget.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ func NewRunner(ctx context.Context, parent string) *Runner {
strings.Join(kptfilev1.UpdateStrategiesAsStrings(), ","))
c.Flags().BoolVar(&r.isDeploymentInstance, "for-deployment", false,
"(Experimental) indicates if this package will be deployed to a cluster.")
_ = c.RegisterFlagCompletionFunc("strategy", func(cmd *cobra.Command, args []string, toComplete string) ([]string, cobra.ShellCompDirective) {
_ = c.RegisterFlagCompletionFunc("strategy", func(_ *cobra.Command, _ []string, _ string) ([]string, cobra.ShellCompDirective) {
return kptfilev1.UpdateStrategiesAsStrings(), cobra.ShellCompDirectiveDefault
})
return r
Expand Down
14 changes: 8 additions & 6 deletions commands/pkg/get/cmdget_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

// revive:disable:unused-parameter

package get_test

import (
Expand Down Expand Up @@ -169,7 +171,7 @@ func TestCmd_fail(t *testing.T) {
}

// NoOpRunE is a noop function to replace the run function of a command. Useful for testing argument parsing.
var NoOpRunE = func(cmd *cobra.Command, args []string) error { return nil }
var NoOpRunE = func(_ *cobra.Command, _ []string) error { return nil }

// NoOpFailRunE causes the test to fail if run is called. Useful for validating run isn't called for
// errors.
Expand Down Expand Up @@ -205,26 +207,26 @@ func TestCmd_Execute_flagAndArgParsing(t *testing.T) {
validations func(repo, dir string, r *get.Runner, err error)
}{
"must have at least 1 arg": {
argsFunc: func(repo, _ string) []string {
argsFunc: func(_, _ string) []string {
return []string{}
},
runE: failRun,
validations: func(_, _ string, r *get.Runner, err error) {
validations: func(_, _ string, _ *get.Runner, err error) {
assert.EqualError(t, err, "requires at least 1 arg(s), only received 0")
},
},
"must provide unambiguous repo, dir and version": {
argsFunc: func(repo, _ string) []string {
argsFunc: func(_, _ string) []string {
return []string{"foo", "bar", "baz"}
},
runE: failRun,
validations: func(_, _ string, r *get.Runner, err error) {
validations: func(_, _ string, _ *get.Runner, err error) {
assert.Error(t, err)
assert.Contains(t, err.Error(), "ambiguous repo/dir@version specify '.git' in argument")
},
},
"repo arg is split up correctly into ref and repo": {
argsFunc: func(repo, _ string) []string {
argsFunc: func(_, _ string) []string {
return []string{"something://foo.git/@master", "./"}
},
runE: NoOpRunE,
Expand Down
2 changes: 1 addition & 1 deletion commands/pkg/pkgcmd.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ func GetCommand(ctx context.Context, name string) *cobra.Command {
Short: pkgdocs.PkgShort,
Long: pkgdocs.PkgLong,
Aliases: []string{"package"},
RunE: func(cmd *cobra.Command, args []string) error {
RunE: func(cmd *cobra.Command, _ []string) error {
h, err := cmd.Flags().GetBool("help")
if err != nil {
return err
Expand Down
2 changes: 1 addition & 1 deletion commands/pkg/update/cmdupdate.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ func NewRunner(ctx context.Context, parent string) *Runner {
"the update strategy that will be used when updating the package. This will change "+
"the default strategy for the package -- must be one of: "+
strings.Join(kptfilev1.UpdateStrategiesAsStrings(), ","))
_ = c.RegisterFlagCompletionFunc("strategy", func(cmd *cobra.Command, args []string, toComplete string) ([]string, cobra.ShellCompDirective) {
_ = c.RegisterFlagCompletionFunc("strategy", func(_ *cobra.Command, _ []string, _ string) ([]string, cobra.ShellCompDirective) {
return kptfilev1.UpdateStrategiesAsStrings(), cobra.ShellCompDirectiveDefault
})
cmdutil.FixDocs("kpt", parent, c)
Expand Down
4 changes: 2 additions & 2 deletions commands/pkg/update/cmdupdate_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -278,7 +278,7 @@ func TestCmd_onlyVersionAsInput(t *testing.T) {
}

// NoOpRunE is a noop function to replace the run function of a command. Useful for testing argument parsing.
var NoOpRunE = func(cmd *cobra.Command, args []string) error { return nil }
var NoOpRunE = func(_ *cobra.Command, _ []string) error { return nil }

// NoOpFailRunE causes the test to fail if run is called. Useful for validating run isn't called for
// errors.
Expand Down Expand Up @@ -429,7 +429,7 @@ func TestCmd_path(t *testing.T) {
defer testutil.Chdir(t, test.currentWD)()

r := update.NewRunner(fake.CtxWithDefaultPrinter(), "kpt")
r.Command.RunE = func(cmd *cobra.Command, args []string) error {
r.Command.RunE = func(_ *cobra.Command, _ []string) error {
if !assert.Equal(t, test.expectedFullPackagePath, r.Update.Pkg.UniquePath.String()) {
t.FailNow()
}
Expand Down
12 changes: 6 additions & 6 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ require (
github.com/spf13/pflag v1.0.5
github.com/stretchr/testify v1.8.4
github.com/xlab/treeprint v1.2.0
golang.org/x/mod v0.10.0
golang.org/x/text v0.14.0
golang.org/x/mod v0.17.0
golang.org/x/text v0.21.0
gopkg.in/yaml.v3 v3.0.1
gotest.tools v2.2.0+incompatible
k8s.io/api v0.28.4
Expand Down Expand Up @@ -107,11 +107,11 @@ require (
github.com/spyzhov/ajson v0.9.0 // indirect
github.com/vbatts/tar-split v0.11.2 // indirect
go.starlark.net v0.0.0-20230525235612-a134d8f9ddca // indirect
golang.org/x/net v0.17.0 // indirect
golang.org/x/net v0.33.0 // indirect
golang.org/x/oauth2 v0.8.0 // indirect
golang.org/x/sync v0.2.0 // indirect
golang.org/x/sys v0.13.0 // indirect
golang.org/x/term v0.13.0 // indirect
golang.org/x/sync v0.10.0 // indirect
golang.org/x/sys v0.28.0 // indirect
golang.org/x/term v0.27.0 // indirect
golang.org/x/time v0.3.0 // indirect
google.golang.org/appengine v1.6.7 // indirect
google.golang.org/protobuf v1.33.0 // indirect
Expand Down
28 changes: 14 additions & 14 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -270,8 +270,8 @@ golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvx
golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.10.0 h1:lFO9qtOdlre5W1jxS3r/4szv2/6iXxScdzjoBMXNhYk=
golang.org/x/mod v0.10.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs=
golang.org/x/mod v0.17.0 h1:zY54UmvipHiNd+pm+m0x9KhZ9hl1/7QNMyxXbc6ICqA=
golang.org/x/mod v0.17.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c=
golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
Expand All @@ -281,8 +281,8 @@ golang.org/x/net v0.0.0-20190603091049-60506f45cf65/go.mod h1:HSz+uSET+XFnRR8LxR
golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU=
golang.org/x/net v0.17.0 h1:pVaXccu2ozPjCXewfr1S7xza/zcXTity9cCdXQYSjIM=
golang.org/x/net v0.17.0/go.mod h1:NxSsAGuq816PNPmqtQdLE42eU2Fs7NoRIZrHJAlaCOE=
golang.org/x/net v0.33.0 h1:74SYHlV8BIgHIFC/LrYkOGIwL19eTYXQ5wc6TBuO36I=
golang.org/x/net v0.33.0/go.mod h1:HXLR5J+9DxmrqMwG9qjGCxZ+zKXxBru04zlTvWlWuN4=
golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
golang.org/x/oauth2 v0.8.0 h1:6dkIjl3j3LtZ/O3sTgZTMsLKSftL/B8Zgq4huOIIUu8=
golang.org/x/oauth2 v0.8.0/go.mod h1:yr7u4HXZRm1R1kBWqr/xKNqewf0plRYoB7sla+BCIXE=
Expand All @@ -292,8 +292,8 @@ golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJ
golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.2.0 h1:PUR+T4wwASmuSTYdKjYHI5TD22Wy5ogLU5qZCOLxBrI=
golang.org/x/sync v0.2.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.10.0 h1:3NQrjDixjgGwUOCaF8w2+VYHv0Ve/vGYSbdkTa98gmQ=
golang.org/x/sync v0.10.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk=
golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
Expand All @@ -302,16 +302,16 @@ golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7w
golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE=
golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.28.0 h1:Fksou7UEQUWlKvIdsqzJmUmCX3cZuD2+P3XyyzwMhlA=
golang.org/x/sys v0.28.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
golang.org/x/term v0.0.0-20220526004731-065cf7ba2467/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
golang.org/x/term v0.13.0 h1:bb+I9cTfFazGW51MZqBVmZy7+JEJMouUHTUSKVQLBek=
golang.org/x/term v0.13.0/go.mod h1:LTmsnFJwVN6bCy1rVCoS+qHT1HhALEFxKncY3WNNh4U=
golang.org/x/term v0.27.0 h1:WP60Sv1nlK1T6SupCHbXzSaN0b9wUmsPoRS9b61A23Q=
golang.org/x/term v0.27.0/go.mod h1:iMsnZpn0cago0GOrHO2+Y7u7JPn5AylBrcoWkElMTSM=
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk=
golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ=
golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU=
golang.org/x/text v0.21.0 h1:zyQAAkrwaneQ066sspRyJaG9VNi/YJ1NfzcGB3hZ/qo=
golang.org/x/text v0.21.0/go.mod h1:4IBbMaMmOPCJ8SecivzSH54+73PCFmPWxNTLm+vZkEQ=
golang.org/x/time v0.3.0 h1:rg5rLMjNzMS1RkNLzCG38eapWhnYLFYXDXj2gOlr8j4=
golang.org/x/time v0.3.0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
Expand All @@ -322,8 +322,8 @@ golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBn
golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
golang.org/x/tools v0.9.3 h1:Gn1I8+64MsuTb/HpH+LmQtNas23LhUVr3rYZ0eKuaMM=
golang.org/x/tools v0.9.3/go.mod h1:owI94Op576fPu3cIGQeHs3joujW/2Oc6MtlxbF5dfNc=
golang.org/x/tools v0.21.1-0.20240508182429-e35e4ccd0d2d h1:vU5i/LfpvrRCpgM/VPfJLg5KjxD3E+hfT1SH+d9zLwg=
golang.org/x/tools v0.21.1-0.20240508182429-e35e4ccd0d2d/go.mod h1:aiJjzUbINMkxbQROHiO6hDPo2LHcIPhhQsa9DLh0yGk=
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
Expand Down
4 changes: 2 additions & 2 deletions internal/alpha/printers/table/printer.go
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ func getProgress(resInfo *resourceInfo) (string, string, error) {

color, setColor := printcommon.ColorForStatus(rs.Status)
if setColor {
s = printcommon.SprintfWithColor(color, s)
s = printcommon.SprintfWithColor(color, "%s", s)
}

text = s
Expand Down Expand Up @@ -295,7 +295,7 @@ func getConditions(rs *pollingevent.ResourceStatus) []string {
}
}

s := printcommon.SprintfWithColor(color, text)
s := printcommon.SprintfWithColor(color, "%s", text)
conditionStrings = append(conditionStrings, s)
}
return conditionStrings
Expand Down
2 changes: 1 addition & 1 deletion internal/errors/errors.go
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ func E(args ...interface{}) error {
case error:
e.Err = a
case string:
e.Err = fmt.Errorf(a)
e.Err = fmt.Errorf("%s", a)
default:
panic(fmt.Errorf("unknown type %T for value %v in call to error.E", a, a))
}
Expand Down
2 changes: 1 addition & 1 deletion internal/fnruntime/imagepullpolicy.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ func (e *ImagePullPolicy) Set(v string) error {
return nil
}
}
return fmt.Errorf("must must be one of " + strings.Join(e.AllStrings(), ", "))
return fmt.Errorf("must be one of: %s", strings.Join(e.AllStrings(), ", "))
}

func (e *ImagePullPolicy) AllStrings() []string {
Expand Down
Loading