Skip to content

chore(lint): fix golangci-lint 2.13.1 findings - #18209

Merged
bartsmykla merged 1 commit into
kumahq:masterfrom
lukidzi:chore/golangci-lint-2131-findings
Aug 25, 2026
Merged

chore(lint): fix golangci-lint 2.13.1 findings#18209
bartsmykla merged 1 commit into
kumahq:masterfrom
lukidzi:chore/golangci-lint-2131-findings

Conversation

@lukidzi

@lukidzi lukidzi commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

Motivation

The golangci-lint bump to 2.13.1 (#18189) enabled modernize's embedlit check, which flags the redundant embedded ObjectMeta type in struct literals. Seven of those live in http_route_controller_test.go, so the check job is red on master and every open PR inherits the failure.

Implementation information

Dropped the redundant ObjectMeta: kube_meta.ObjectMeta{...} wrapper in the seven flagged literals; ObjectMeta is embedded in both MeshService and the core Kubernetes types, so the fields are set directly. Mechanical change, no behavior difference. The kube_meta import stays, it is still used elsewhere in the file.

Verified with golangci-lint run --fix=false (the flag CI passes) on the package: 0 issues. Build, vet, and the package tests pass.

Supporting documentation

Follows the same pattern as #18194 for the previous lint bump.

Changelog: skip

The 2.13.1 bump enabled modernize's embedlit check, which flags the
redundant embedded ObjectMeta type in struct literals. Master's check
job is red and every open PR inherits the failure.

Signed-off-by: Lukasz Dziedziak <lukidzi@gmail.com>
@lukidzi
lukidzi requested a review from a team as a code owner August 25, 2026 15:30
@lukidzi
lukidzi requested review from Automaat and slonka August 25, 2026 15:30
@bartsmykla
bartsmykla merged commit 135f19b into kumahq:master Aug 25, 2026
28 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants