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

chore: enable govet linter #1825

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

mmorel-35
Copy link
Contributor

@mmorel-35 mmorel-35 commented Mar 23, 2025

Description

  • Adding govet to the list of enabled linters in the Golang CI configuration

@ccoVeille
Copy link

I don't think there is a need for fieldalignment rule in govet linter.

I'm assuming it's the root cause of so many changes.

gopsutil is used on several OSes where alignment varies.

So if you think there is a need for it, you could take a look at https://pkg.go.dev/structs#HostLayout

(One of my recent discovery, thanks again @cristaloleg for this.)

I would like to recommend you to either:

  • disable this rule, and revert the changes
  • revert changes, use structs package, if needed disable the fieldalignment rule (I'm unsure govet detects the use of structs packages)

Signed-off-by: Matthieu MOREL <[email protected]>
@mmorel-35 mmorel-35 force-pushed the golangci-lint/govet branch from 57b4faf to d93dd8a Compare March 24, 2025 06:25
@mmorel-35 mmorel-35 changed the title chore(linters): add govet to the enabled linters in golangci configuration chore: enable govet linter Mar 24, 2025
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