Make linter stricker #148
Labels
No labels
P0
P1
P2
P3
badger
frostfs-adm
frostfs-cli
frostfs-ir
frostfs-lens
frostfs-node
good first issue
triage
Infrastructure
blocked
bug
config
discussion
documentation
duplicate
enhancement
go
help wanted
internal
invalid
kludge
observability
perfomance
question
refactoring
wontfix
No milestone
No project
No assignees
3 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: TrueCloudLab/frostfs-node#148
Loading…
Reference in a new issue
No description provided.
Delete branch "dstepanov-yadro/frostfs-node:feat/linters"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
19ca57e0e4
to8a21c93e69
WIP: Make linter strickerto Make linter stricker@ -55,1 +60,4 @@
- whitespace
- containedctx
- funlen
- gocyclo
Do we need both gocyclo and gocognit?
They estimate the same complexity but with different metrics.
What about using
gocognit
only?These linters are slightly different: https://github.com/uudashr/gocognit#comparison-with-cyclometic-complexity
i`m ok with using gocognit only
done
@ -27,2 +27,4 @@
staticcheck:
checks: ["all", "-SA1019"] # TODO Enable SA1019 after deprecated warning are fixed.
funlen:
lines: 80 # default 60
Function body should fit on one screen. My 24 inch screen holds 40 lines.
I have seen a research, where it was stated that function's that don't fit on ones screen rapidly decrease developer productivity, so I think 40 lines is a nice goal to have in mind. Let's be honest, not everyone has 4k monitors.
8a21c93e69
to58a95620a1
58a95620a1
to662ac260fa
d4f7585cf5
to60261b0d0a
60261b0d0a
to50b92e2019
50b92e2019
to44b86bac5a