Skip to content

Move to golangci v2 - #704

Merged
chombium merged 1 commit into
cloudfoundry:mainfrom
jorbaum:golangciv2
Aug 19, 2025
Merged

Move to golangci v2#704
chombium merged 1 commit into
cloudfoundry:mainfrom
jorbaum:golangciv2

Conversation

@jorbaum

@jorbaum jorbaum commented Aug 11, 2025

Copy link
Copy Markdown
Contributor

Description

Move to golangci-lint v2.

Changes:

  • Accept QF1004: Change Replace to ReplaceAll where sensible
  • Accept QF1008: Omit an embedded field
  • Accept ST1019: code.cloudfoundry.org/loggregator-agent-release/src/pkg/ingress/v2 had been imported twice
  • Accept ST1005: to have nicer logs

Noteworthy changes in golangci-lint v2:

  • New config format (migrated with migrate command)
  • Default timeout is now 0 instead of 1 minute. See here for rationale. Kept ours unchanged for now.

Type of change

  • New feature (non-breaking change which adds functionality)

Testing performed?

  • Unit tests
  • Integration tests
  • Acceptance tests

Checklist:

  • This PR is being made against the main branch, or relevant version branch
  • I have made corresponding changes to the documentation
  • I have added testing for my changes

@linux-foundation-easycla

linux-foundation-easycla Bot commented Aug 11, 2025

Copy link
Copy Markdown

CLA Signed

The committers listed above are authorized under a signed CLA.

  • ✅ login: jorbaum / name: Joris Baum (7b08cbe)

Comment thread src/cmd/loggregator-agent/app/app_v1.go
@chombium

chombium commented Aug 18, 2025

Copy link
Copy Markdown
Contributor

@jorbaum Can you please rebase the master in your branch and re-run the linting tests?

@jorbaum

jorbaum commented Aug 18, 2025

Copy link
Copy Markdown
Contributor Author

@jorbaum Can you please rebase the master in your branch and re-run the linting tests?

Done. Linting tests look fine after rebase.

Also fixes issues reported by golangci-lint v2:

* Change `Replace` to `ReplaceAll` where sensible
* Omit an embedded field
* `ingress/v2` had been imported twice
* Nicer casing in logs

Noteworthy changes in golangci-lint v2:

* New config format (migrated with `migrate` command)
* Default timeout is now 0 instead of 1 minute.

@chombium chombium left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM! Thanks for this great update @jorbaum

@github-project-automation github-project-automation Bot moved this from Inbox to Pending Merge | Prioritized in Application Runtime Platform Working Group Aug 19, 2025
@chombium
chombium merged commit 2665bbf into cloudfoundry:main Aug 19, 2025
5 checks passed
@github-project-automation github-project-automation Bot moved this from Pending Merge | Prioritized to Done in Application Runtime Platform Working Group Aug 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Development

Successfully merging this pull request may close these issues.

2 participants