Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Add linter to the building pipeline #30896
Add linter to the building pipeline #30896
Changes from all commits
5289350
2e6c821
fedbde5
ecdf9bc
bf5f3ac
cbf3f28
28de4ff
116d4d0
b917f1a
ef89729
85f928b
e0b4c1c
51cc67d
40c60f5
36a59f1
b53e701
90ae9fa
b7c357a
c4bb929
6e31095
78f1613
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For stylecheck (or some other linter) could we check that godoc follows the https://staticcheck.io/docs/checks/#ST1020. Like if you are going to put effort into writing docs for your exported function then follow the Go conventions 😄. FWIW we have that check in go-libaudit (had to disable one of the default excludes).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I actually thought it was the default behaviour, I used to see this errors before in one of my previous projects. I tested locally and even with
checks: ["all"]
forstaticcheck
andstylecheck
it didn't return any errors for missing or malformed go doc strings. I'll investigate further.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's probably one of the default rules for excluding issues listed in https://golangci-lint.run/usage/configuration#command-line-options. Like maybe
EXC0014
.Adding something like this can workaround it:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll add it later as a separate PR, since this is already stable and approved.