Add linter checks to GHA & Fix code to pass lints

Add linter checks to GHA & Fix code to pass lints.
The linters added are:
- whitespace: Tool for detection of leading and trailing whitespace
- gosec: Inspects source code for security problems
- gci: Gci control golang package import order and make it always deterministic
- misspell: Finds commonly misspelled English words in comments
- gomnd: An analyzer to detect magic numbers

The file utils/utils.go is excluded from the checks of gomnd, as uses magic numbers through the code
This commit is contained in:
arnaucube
2020-08-27 18:10:05 +02:00
parent fe8431edfa
commit fd1e9c25ee
27 changed files with 95 additions and 75 deletions

View File

@@ -294,17 +294,14 @@ func (c *Coordinator) isForgeSequence() bool {
}
func (c *Coordinator) purgeRemoveByTimeout() error {
return nil
}
func (c *Coordinator) purgeInvalidDueToL2TxsSelection(l2Txs []*common.PoolL2Tx) error {
return nil
}
func (c *Coordinator) shouldL1L2Batch() bool {
return false
}