[sdk50] Lint the go relayer like IBC-go #2
Annotations
10 errors and 10 warnings
lint:
internal/relaydebug/debugserver.go#L50
Error return value of `srv.Serve` is not checked (errcheck)
|
lint:
internal/relaydebug/debugserver.go#L42
G112: Potential Slowloris Attack because ReadHeaderTimeout is not configured in the http.Server (gosec)
|
lint:
relayer/codecs/ethermint/encoding.go#L347
redefines-builtin-id: redefinition of the built-in type any (revive)
|
lint:
relayer/provider/matcher.go#L38
singleCaseSwitch: should rewrite switch statement to if statement (gocritic)
|
lint:
relayer/provider/matcher.go#L67
singleCaseSwitch: should rewrite switch statement to if statement (gocritic)
|
lint:
relayer/provider/provider.go#L32
exported: type name will be used as provider.ProviderConfig by other packages, and that stutters; consider calling this Config (revive)
|
lint:
cmd/chains_test.go#L77
Error return value of `enc.Encode` is not checked (errcheck)
|
lint:
relayer/chains/cosmos/feegrant.go#L202
assignOp: replace `cc.PCfg.FeeGrants.GranteeLastSignerIndex = cc.PCfg.FeeGrants.GranteeLastSignerIndex + 1` with `cc.PCfg.FeeGrants.GranteeLastSignerIndex++` (gocritic)
|
lint:
relayer/chains/cosmos/log.go#L67
appendAssign: append result not assigned to the same slice (gocritic)
|
lint:
relayer/chains/penumbra/log.go#L59
appendAssign: append result not assigned to the same slice (gocritic)
|
lint:
relayer/processor/types.go#L239
receiver-naming: receiver name k should be consistent with previous receiver name connectionKey for ConnectionKey (revive)
|
lint:
relayer/chains/mock/mock_chain_processor.go#L22
exported: type name will be used as mock.MockChainProcessor by other packages, and that stutters; consider calling this ChainProcessor (revive)
|
lint:
relayer/chains/cosmos/query.go#L51
import-shadowing: The name 'query' shadows an import name (revive)
|
lint:
relayer/chains/cosmos/cosmos_chain_processor.go#L61
import-shadowing: The name 'provider' shadows an import name (revive)
|
lint:
relayer/chains/cosmos/tx.go#L1371
indent-error-flow: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (revive)
|
lint:
relayer/chains/cosmos/msg.go#L32
indent-error-flow: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (revive)
|
lint:
relayer/chains/cosmos/feegrant.go#L304
indent-error-flow: if block ends with a return statement, so drop this else and outdent its block (revive)
|
lint:
relayer/chains/cosmos/msg.go#L43
indent-error-flow: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (revive)
|
lint:
relayer/chains/cosmos/tx.go#L357
import-shadowing: The name 'tx' shadows an import name (revive)
|
lint:
relayer/chains/cosmos/tx.go#L633
import-shadowing: The name 'tx' shadows an import name (revive)
|