Skip to content

Commit

Permalink
Merge pull request #6226 from Algo-devops-service/relstable4.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
algojohnlee authored Jan 10, 2025
2 parents f54f099 + a92bb19 commit 63d271c
Show file tree
Hide file tree
Showing 1,238 changed files with 15,829 additions and 3,053 deletions.
22 changes: 12 additions & 10 deletions .github/workflows/reviewdog.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
name: "ReviewDog workflow"
env:
GOLANGCI_LINT_VERSION: "v1.62.0"
on:
push:
branches:
Expand All @@ -17,15 +19,15 @@ jobs:
- name: Make libsodium.a
run: sudo mv /usr/bin/go /usr/bin/go.bak && make crypto/libs/linux/amd64/lib/libsodium.a && sudo mv /usr/bin/go.bak /usr/bin/go
- name: reviewdog-golangci-lint
uses: reviewdog/action-golangci-lint@v2.6.2
uses: reviewdog/action-golangci-lint@v2.7.0
with:
go_version_file: go.mod
golangci_lint_version: "v1.62.0"
golangci_lint_version: ${{ env.GOLANGCI_LINT_VERSION }}
golangci_lint_flags: "-c .golangci.yml --allow-parallel-runners"
reporter: "github-pr-check"
tool_name: "Lint Errors"
level: "error"
fail_on_error: true
fail_level: any
filter_mode: "nofilter"
# Non-Blocking Warnings Section
reviewdog-warnings:
Expand Down Expand Up @@ -56,20 +58,20 @@ jobs:
uses: actions/cache@v3.3.1
with:
path: cicdtmp/golangci-lint/golangci-lint-cgo
key: cicd-golangci-lint-cgo-v0.0.2-${{ env.GO_VERSION }}
key: cicd-golangci-lint-cgo-v0.0.3-${{ env.GO_VERSION }}-${{ env.GOLANGCI_LINT_VERSION }}

- name: Build custom golangci-lint with CGO_ENABLED
if: steps.cache-golangci-lint.outputs.cache-hit != 'true'
run: |
cd cicdtmp/golangci-lint
git clone https://github.com/golangci/golangci-lint.git .
git checkout tags/v1.62.0
git checkout tags/${GOLANGCI_LINT_VERSION}
CGO_ENABLED=true go build -trimpath -o golangci-lint-cgo ./cmd/golangci-lint
./golangci-lint-cgo --version
cd ../../
- name: Install reviewdog
run: |
curl -sfL https://raw.githubusercontent.com/reviewdog/reviewdog/v0.20.2/install.sh | sh -s -- v0.20.2
curl -sfL https://raw.githubusercontent.com/reviewdog/reviewdog/v0.20.3/install.sh | sh -s -- v0.20.3
reviewdog --version
- name: Build custom linters
run: |
Expand All @@ -92,9 +94,9 @@ jobs:
cat temp_golangci-lint-cgo.txt | reviewdog \
-f=golangci-lint \
-name="Lint Warnings" \
-reporter=github-check \
-reporter=github-pr-check \
-filter-mode=added \
-fail-on-error=true \
-fail-level=any \
-level=warning
- name: Slack Notification
env:
Expand All @@ -107,11 +109,11 @@ jobs:
steps:
- uses: actions/checkout@v4
- name: shellcheck
uses: reviewdog/action-shellcheck@v1
uses: reviewdog/action-shellcheck@v1.28.0
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
reporter: "github-pr-check"
shellcheck_flags: "-e SC2034,SC2046,SC2053,SC2207,SC2145 -S warning"
fail_on_error: true
fail_level: any
path: |
test/scripts/e2e_subs
4 changes: 2 additions & 2 deletions .golangci-warnings.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ linters:
- partitiontest

linters-settings:
gosec: # we are mostly only interested in G601
excludes: [G101, G103, G104, G107, G202, G301, G302, G303, G304, G306, G307, G404]
gosec: # Go 1.22 makes G601 irrelevant
excludes: [G101, G103, G104, G107, G115, G202, G301, G302, G303, G304, G306, G307, G404, G601]
custom:
partitiontest:
path: cmd/partitiontest_linter/plugin.so
Expand Down
3 changes: 3 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -293,6 +293,9 @@ $(GOPATH1)/bin/%:
test: build
$(GOTESTCOMMAND) $(GOTAGS) -race $(UNIT_TEST_SOURCES) -timeout 1h -coverprofile=coverage.txt -covermode=atomic

testc:
echo $(UNIT_TEST_SOURCES) | xargs -P8 -n1 go test -c

benchcheck: build
$(GOTESTCOMMAND) $(GOTAGS) -race $(UNIT_TEST_SOURCES) -run ^NOTHING -bench Benchmark -benchtime 1x -timeout 1h

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -169,5 +169,5 @@ Provides utilities for the various components:

Please see the [COPYING_FAQ](COPYING_FAQ) for details on how to apply our license.

Copyright (C) 2019-2024, Algorand Inc.
Copyright (C) 2019-2025, Algorand Inc.

2 changes: 1 addition & 1 deletion agreement/abstractions.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/actions.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/actor.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/agreeInstall.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/agreementtest/keyManager.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/agreementtest/simulate.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
4 changes: 2 additions & 2 deletions agreement/agreementtest/simulate_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand All @@ -19,6 +19,7 @@ package agreementtest
import (
"context"
"fmt"
"maps"
"math/rand"
"os"
"strconv"
Expand All @@ -27,7 +28,6 @@ import (

"github.com/algorand/go-deadlock"
"github.com/stretchr/testify/require"
"golang.org/x/exp/maps"

"github.com/algorand/go-algorand/agreement"
"github.com/algorand/go-algorand/config"
Expand Down
2 changes: 1 addition & 1 deletion agreement/asyncVoteVerifier.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/asyncVoteVerifier_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
4 changes: 2 additions & 2 deletions agreement/autopsy.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand All @@ -20,11 +20,11 @@ import (
"fmt"
"io"
"os"
"slices"

"github.com/algorand/go-algorand/data/basics"
"github.com/algorand/go-algorand/logging"
"github.com/algorand/go-algorand/protocol"
"golang.org/x/exp/slices"
)

// An Autopsy is a trace of the ordered input events and output
Expand Down
2 changes: 1 addition & 1 deletion agreement/bundle.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/bundle_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/cadaver.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/certificate.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/certificate_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
4 changes: 2 additions & 2 deletions agreement/common_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand All @@ -19,12 +19,12 @@ package agreement
import (
"context"
"fmt"
"maps"
"math/rand"
"testing"

"github.com/algorand/go-deadlock"
"github.com/stretchr/testify/require"
"golang.org/x/exp/maps"

"github.com/algorand/go-algorand/config"
"github.com/algorand/go-algorand/crypto"
Expand Down
2 changes: 1 addition & 1 deletion agreement/coservice.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/credentialArrivalHistory.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/credentialArrivalHistory_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/cryptoRequestContext.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/cryptoRequestContext_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/cryptoVerifier.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/cryptoVerifier_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/demux.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/demux_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/doc.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/dynamicFilterTimeoutParams.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/dynamicFilterTimeoutParams_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/encoding_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/errors.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/events.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/events_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/fuzzer/bandwidthFilter_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/fuzzer/catchupFilter_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/fuzzer/clockedFilter_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/fuzzer/dropMessageFilter_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/fuzzer/duplicateMessageFilter_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/fuzzer/filter_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/fuzzer/fuzzer.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/fuzzer/fuzzer_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/fuzzer/ledger_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
2 changes: 1 addition & 1 deletion agreement/fuzzer/messageDecoderFilter_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2019-2024 Algorand, Inc.
// Copyright (C) 2019-2025 Algorand, Inc.
// This file is part of go-algorand
//
// go-algorand is free software: you can redistribute it and/or modify
Expand Down
Loading

0 comments on commit 63d271c

Please sign in to comment.