Enable many golangci-linters that seem somewhat useful and don't show
ridiculous numbers of issues out of the gate.
update golangci-lint to latest 1.43.0
consistent import ordering enforced by gci
nilnil and nilerr linters actually found various bugs where a nil
error was returned after detecting an error.
fix issues in bwtester and ssh so that exclude-rules can be removed:
bwtester: requires removing the dot-import of the bwtestlib. For
this, renamed it to shorter bwtest and renamed various items in it
to remove the redundant Bwtest from the name.
ssh: minimally handle various errors, or explicitly ignore them
Reply the error state for WantReply requests.
enable lint for examples (and fix all issues)
It's clear that enabling more linters won't magically turn bad code good. But it probably doesn't hurt either, and it did find a few bugs.
Enable many golangci-linters that seem somewhat useful and don't show ridiculous numbers of issues out of the gate.
bwtest
and renamed various items in it to remove the redundant Bwtest from the name.WantReply
requests.It's clear that enabling more linters won't magically turn bad code good. But it probably doesn't hurt either, and it did find a few bugs.
This change is