Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@ jobs:
- name: Build
run: go build ./...
- name: Install Linters
run: "curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.64.5"
run: "curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v2.0.2"
- name: Test and Lint
run: ./run_tests.sh
22 changes: 13 additions & 9 deletions .golangci.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
version: "2"
run:
deadline: 10m

timeout: 10m
linters:
disable-all: true
default: none
enable:
- asciicheck
- bidichk
Expand All @@ -17,9 +17,6 @@ linters:
- fatcontext
- goconst
- godot
- gofmt
- goimports
- gosimple
- govet
- ineffassign
- makezero
Expand All @@ -34,9 +31,16 @@ linters:
- revive
- staticcheck
- tparallel
- typecheck
- unconvert
- usestdlibvars
- usetesting
- unparam
- unused
- usestdlibvars
- usetesting
exclusions:
presets:
- comments
- std-error-handling
formatters:
enable:
- gofmt
- goimports
4 changes: 2 additions & 2 deletions cmd/vote-validator/results.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ func (r *results) writeFile(path string) (bool, error) {
return false, fmt.Errorf("opening log file failed: %w", err)
}

write := func(f *os.File, str string, a ...any) {
_, err := f.WriteString(fmt.Sprintf(str+"\n", a...))
write := func(f *os.File, format string, a ...any) {
_, err := fmt.Fprintf(f, format+"\n", a...)
if err != nil {
f.Close()
panic(fmt.Sprintf("writing to log file failed: %v", err))
Expand Down
Loading