Skip to content

Commit

Permalink
golangci: fix lint and updater linter (#1691)
Browse files Browse the repository at this point in the history
Fixes failing lint in main and updates linter to latest version.

category: fixbuild
ticket: none
  • Loading branch information
corverroos authored Jan 26, 2023
1 parent 3b79fbc commit 02c7290
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 9 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/golangci-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
- name: golangci-lint
uses: golangci/golangci-lint-action@v3
with:
version: v1.48.0
version: v1.50.1
only-new-issues: true

- name: notify failure
Expand Down
8 changes: 5 additions & 3 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -88,9 +88,6 @@ issues:
- "nested-structs" # Relax revive
- "0xhex" # Relax revive and staticcheck about our custom struct tag
- "shadow: declaration of \"err\" shadows declaration" # Relax govet
- "bls_sig contains underscore" # Relax nosnakecase
- "v\\d_\\d contains underscore" # Relax nosnakecase
- "P_\\w+ contains underscore" # Relax nosnakecase

linters:
enable-all: true
Expand Down Expand Up @@ -122,3 +119,8 @@ linters:
- tagliatelle
- varnamelen
- wsl
# Deprecated
- nosnakecase
- structcheck
- varcheck
- deadcode
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ repos:
# Then run code validators (on the formatted code)

- repo: https://github.com/golangci/golangci-lint
rev: v1.48.0
rev: v1.50.1
hooks:
- id: golangci-lint
args: [ -n ] # See .golangci.yml for config
Expand Down
4 changes: 0 additions & 4 deletions cmd/enr_internal_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,6 @@ import (
"github.com/obolnetwork/charon/p2p"
)

const (
compressedK1PubkeyLen = 33
)

func TestRunNewEnr(t *testing.T) {
temp, err := os.MkdirTemp("", "")
require.NoError(t, err)
Expand Down

0 comments on commit 02c7290

Please sign in to comment.