Skip to content

Merge branch 'main' into renovate/github.com-docker-docker-25.x #4166

Merge branch 'main' into renovate/github.com-docker-docker-25.x

Merge branch 'main' into renovate/github.com-docker-docker-25.x #4166

GitHub Actions / golangci failed Feb 2, 2024 in 1s

reviewdog [golangci] report

reported by reviewdog 🐶

Findings (14)

runtime/kubernetes/mock.go|143 col 53| Error return value of (k8s.io/client-go/tools/cache.SharedInformer).AddEventHandler is not checked (errcheck)
runtime/kubernetes/pod_tracker.go|227 col 40| Error return value of (k8s.io/client-go/tools/cache.SharedInformer).AddEventHandler is not checked (errcheck)
mock/docker/service.go|23 col 40| unused-parameter: parameter 'ctx' seems to be unused, consider removing or renaming it as _ (revive)
mock/docker/node.go|22 col 42| unused-parameter: parameter 'ctx' seems to be unused, consider removing or renaming it as _ (revive)
mock/docker/system.go|24 col 35| unused-parameter: parameter 'ctx' seems to be unused, consider removing or renaming it as _ (revive)
executor/linux/secret.go|202 col 37| non-wrapping format verb for fmt.Errorf. Use %w to format errors (errorlint)
executor/linux/secret.go|219 col 37| non-wrapping format verb for fmt.Errorf. Use %w to format errors (errorlint)
executor/linux/secret.go|236 col 37| non-wrapping format verb for fmt.Errorf. Use %w to format errors (errorlint)
mock/docker/image.go|121 col 13| SA1019: types.ImageMetadata is deprecated: use [image.Metadata]. (staticcheck)
mock/docker/service.go|24 col 9| SA1019: types.ServiceCreateResponse is deprecated: use [swarm.ServiceCreateResponse]. (staticcheck)
mock/docker/service.go|69 col 9| SA1019: types.ServiceUpdateResponse is deprecated: use [swarm.ServiceUpdateResponse]. (staticcheck)
runtime/docker/container.go|72 col 10| SA1019: types.ContainerRemoveOptions is deprecated: use [container.RemoveOptions]. (staticcheck)
runtime/docker/container.go|170 col 10| SA1019: types.ContainerStartOptions is deprecated: use [container.StartOptions]. (staticcheck)
runtime/docker/container.go|240 col 10| SA1019: types.ContainerLogsOptions is deprecated: use [container.LogsOptions]. (staticcheck)

Filtered Findings (0)

Annotations

Check failure on line 143 in runtime/kubernetes/mock.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] runtime/kubernetes/mock.go#L143

Error return value of `(k8s.io/client-go/tools/cache.SharedInformer).AddEventHandler` is not checked (errcheck)
Raw output
runtime/kubernetes/mock.go:143:53: Error return value of `(k8s.io/client-go/tools/cache.SharedInformer).AddEventHandler` is not checked (errcheck)
	c.PodTracker.podInformer.Informer().AddEventHandler(cache.ResourceEventHandlerFuncs{
	                                                   ^

Check failure on line 227 in runtime/kubernetes/pod_tracker.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] runtime/kubernetes/pod_tracker.go#L227

Error return value of `(k8s.io/client-go/tools/cache.SharedInformer).AddEventHandler` is not checked (errcheck)
Raw output
runtime/kubernetes/pod_tracker.go:227:40: Error return value of `(k8s.io/client-go/tools/cache.SharedInformer).AddEventHandler` is not checked (errcheck)
	podInformer.Informer().AddEventHandler(cache.ResourceEventHandlerFuncs{
	                                      ^

Check failure on line 23 in mock/docker/service.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] mock/docker/service.go#L23

unused-parameter: parameter 'ctx' seems to be unused, consider removing or renaming it as _ (revive)
Raw output
mock/docker/service.go:23:40: unused-parameter: parameter 'ctx' seems to be unused, consider removing or renaming it as _ (revive)
func (s *ServiceService) ServiceCreate(ctx context.Context, service swarm.ServiceSpec, options types.ServiceCreateOptions) (types.ServiceCreateResponse, error) {
                                       ^

Check failure on line 22 in mock/docker/node.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] mock/docker/node.go#L22

unused-parameter: parameter 'ctx' seems to be unused, consider removing or renaming it as _ (revive)
Raw output
mock/docker/node.go:22:42: unused-parameter: parameter 'ctx' seems to be unused, consider removing or renaming it as _ (revive)
func (n *NodeService) NodeInspectWithRaw(ctx context.Context, nodeID string) (swarm.Node, []byte, error) {
                                         ^

Check failure on line 24 in mock/docker/system.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] mock/docker/system.go#L24

unused-parameter: parameter 'ctx' seems to be unused, consider removing or renaming it as _ (revive)
Raw output
mock/docker/system.go:24:35: unused-parameter: parameter 'ctx' seems to be unused, consider removing or renaming it as _ (revive)
func (s *SystemService) DiskUsage(ctx context.Context, opts types.DiskUsageOptions) (types.DiskUsage, error) {
                                  ^

Check failure on line 202 in executor/linux/secret.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] executor/linux/secret.go#L202

non-wrapping format verb for fmt.Errorf. Use `%w` to format errors (errorlint)
Raw output
executor/linux/secret.go:202:37: non-wrapping format verb for fmt.Errorf. Use `%w` to format errors (errorlint)
			return nil, fmt.Errorf("%s: %w", ErrUnableToRetrieve, err)
			                                 ^

Check failure on line 219 in executor/linux/secret.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] executor/linux/secret.go#L219

non-wrapping format verb for fmt.Errorf. Use `%w` to format errors (errorlint)
Raw output
executor/linux/secret.go:219:37: non-wrapping format verb for fmt.Errorf. Use `%w` to format errors (errorlint)
			return nil, fmt.Errorf("%s: %w", ErrUnableToRetrieve, err)
			                                 ^

Check failure on line 236 in executor/linux/secret.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] executor/linux/secret.go#L236

non-wrapping format verb for fmt.Errorf. Use `%w` to format errors (errorlint)
Raw output
executor/linux/secret.go:236:37: non-wrapping format verb for fmt.Errorf. Use `%w` to format errors (errorlint)
			return nil, fmt.Errorf("%s: %w", ErrUnableToRetrieve, err)
			                                 ^

Check failure on line 121 in mock/docker/image.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] mock/docker/image.go#L121

SA1019: types.ImageMetadata is deprecated: use [image.Metadata]. (staticcheck)
Raw output
mock/docker/image.go:121:13: SA1019: types.ImageMetadata is deprecated: use [image.Metadata]. (staticcheck)
		Metadata: types.ImageMetadata{LastTagTime: time.Now()},
		          ^

Check failure on line 24 in mock/docker/service.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] mock/docker/service.go#L24

SA1019: types.ServiceCreateResponse is deprecated: use [swarm.ServiceCreateResponse]. (staticcheck)
Raw output
mock/docker/service.go:24:9: SA1019: types.ServiceCreateResponse is deprecated: use [swarm.ServiceCreateResponse]. (staticcheck)
	return types.ServiceCreateResponse{}, nil
	       ^

Check failure on line 69 in mock/docker/service.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] mock/docker/service.go#L69

SA1019: types.ServiceUpdateResponse is deprecated: use [swarm.ServiceUpdateResponse]. (staticcheck)
Raw output
mock/docker/service.go:69:9: SA1019: types.ServiceUpdateResponse is deprecated: use [swarm.ServiceUpdateResponse]. (staticcheck)
	return types.ServiceUpdateResponse{}, nil
	       ^

Check failure on line 72 in runtime/docker/container.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] runtime/docker/container.go#L72

SA1019: types.ContainerRemoveOptions is deprecated: use [container.RemoveOptions]. (staticcheck)
Raw output
runtime/docker/container.go:72:10: SA1019: types.ContainerRemoveOptions is deprecated: use [container.RemoveOptions]. (staticcheck)
	opts := types.ContainerRemoveOptions{
	        ^

Check failure on line 170 in runtime/docker/container.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] runtime/docker/container.go#L170

SA1019: types.ContainerStartOptions is deprecated: use [container.StartOptions]. (staticcheck)
Raw output
runtime/docker/container.go:170:10: SA1019: types.ContainerStartOptions is deprecated: use [container.StartOptions]. (staticcheck)
	opts := types.ContainerStartOptions{}
	        ^

Check failure on line 240 in runtime/docker/container.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] runtime/docker/container.go#L240

SA1019: types.ContainerLogsOptions is deprecated: use [container.LogsOptions]. (staticcheck)
Raw output
runtime/docker/container.go:240:10: SA1019: types.ContainerLogsOptions is deprecated: use [container.LogsOptions]. (staticcheck)
	opts := types.ContainerLogsOptions{
	        ^