Skip to content

Commit

Permalink
Enable extra default linters for our code
Browse files Browse the repository at this point in the history
- enable errcheck
- enable staticcheck
- only scans plugin directory and _ext.go files
- fix lint errors
  • Loading branch information
qdm12 committed Jan 30, 2025
1 parent ecb4cce commit 3eddab0
Show file tree
Hide file tree
Showing 16 changed files with 167 additions and 111 deletions.
11 changes: 7 additions & 4 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,16 @@ run:
timeout: 10m

linters:
disable-all: true
enable:
- goimports
- gosimple
- govet
- ineffassign
- misspell
- unconvert
- unused
- whitespace

issues:
exclude-rules:
- path-except: "(plugin\\/.+\\.go|.+_ext\\.go)"
linters:
- errcheck
- staticcheck
16 changes: 8 additions & 8 deletions plugin/evm/atomic/export_tx.go
Original file line number Diff line number Diff line change
Expand Up @@ -133,16 +133,16 @@ func (utx *UnsignedExportTx) Verify(
func (utx *UnsignedExportTx) GasUsed(fixedFee bool) (uint64, error) {
byteCost := calcBytesCost(len(utx.Bytes()))
numSigs := uint64(len(utx.Ins))
sigCost, err := math.Mul64(numSigs, secp256k1fx.CostPerSignature)
sigCost, err := math.Mul(numSigs, secp256k1fx.CostPerSignature)
if err != nil {
return 0, err
}
cost, err := math.Add64(byteCost, sigCost)
cost, err := math.Add(byteCost, sigCost)
if err != nil {
return 0, err
}
if fixedFee {
cost, err = math.Add64(cost, params.AtomicTxBaseCost)
cost, err = math.Add(cost, params.AtomicTxBaseCost)
if err != nil {
return 0, err
}
Expand All @@ -160,15 +160,15 @@ func (utx *UnsignedExportTx) Burned(assetID ids.ID) (uint64, error) {
)
for _, out := range utx.ExportedOutputs {
if out.AssetID() == assetID {
spent, err = math.Add64(spent, out.Output().Amount())
spent, err = math.Add(spent, out.Output().Amount())
if err != nil {
return 0, err
}
}
}
for _, in := range utx.Ins {
if in.AssetID == assetID {
input, err = math.Add64(input, in.Amount)
input, err = math.Add(input, in.Amount)
if err != nil {
return 0, err
}
Expand Down Expand Up @@ -346,7 +346,7 @@ func NewExportTx(
avaxIns, avaxSigners, err = GetSpendableAVAXWithFee(ctx, state, keys, avaxNeeded, cost, baseFee)
default:
var newAvaxNeeded uint64
newAvaxNeeded, err = math.Add64(avaxNeeded, params.AvalancheAtomicTxFee)
newAvaxNeeded, err = math.Add(avaxNeeded, params.AvalancheAtomicTxFee)
if err != nil {
return nil, errOverflowExport
}
Expand Down Expand Up @@ -486,7 +486,7 @@ func GetSpendableAVAXWithFee(
return nil, nil, err
}

newAmount, err := math.Add64(amount, initialFee)
newAmount, err := math.Add(amount, initialFee)
if err != nil {
return nil, nil, err
}
Expand Down Expand Up @@ -527,7 +527,7 @@ func GetSpendableAVAXWithFee(
// Update the cost for the next iteration
cost = newCost

newAmount, err := math.Add64(amount, additionalFee)
newAmount, err := math.Add(amount, additionalFee)
if err != nil {
return nil, nil, err
}
Expand Down
10 changes: 5 additions & 5 deletions plugin/evm/atomic/import_tx.go
Original file line number Diff line number Diff line change
Expand Up @@ -144,13 +144,13 @@ func (utx *UnsignedImportTx) GasUsed(fixedFee bool) (uint64, error) {
if err != nil {
return 0, err
}
cost, err = math.Add64(cost, inCost)
cost, err = math.Add(cost, inCost)
if err != nil {
return 0, err
}
}
if fixedFee {
cost, err = math.Add64(cost, params.AtomicTxBaseCost)
cost, err = math.Add(cost, params.AtomicTxBaseCost)
if err != nil {
return 0, err
}
Expand All @@ -167,15 +167,15 @@ func (utx *UnsignedImportTx) Burned(assetID ids.ID) (uint64, error) {
)
for _, out := range utx.Outs {
if out.AssetID == assetID {
spent, err = math.Add64(spent, out.Amount)
spent, err = math.Add(spent, out.Amount)
if err != nil {
return 0, err
}
}
}
for _, in := range utx.ImportedInputs {
if in.AssetID() == assetID {
input, err = math.Add64(input, in.Input().Amount())
input, err = math.Add(input, in.Input().Amount())
if err != nil {
return 0, err
}
Expand Down Expand Up @@ -311,7 +311,7 @@ func NewImportTx(
continue
}
aid := utxo.AssetID()
importedAmount[aid], err = math.Add64(importedAmount[aid], input.Amount())
importedAmount[aid], err = math.Add(importedAmount[aid], input.Amount())
if err != nil {
return nil, err
}
Expand Down
13 changes: 7 additions & 6 deletions plugin/evm/atomic_syncer_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ import (
"bytes"
"context"
"fmt"
"math/rand"
"testing"

"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"

"github.com/ava-labs/avalanchego/database"
"github.com/ava-labs/avalanchego/database/memdb"
Expand Down Expand Up @@ -80,7 +80,9 @@ func testAtomicSyncer(t *testing.T, serverTrieDB *triedb.Database, targetHeight
return leafsResponse, nil
}

syncer.Start(ctx)
err = syncer.Start(ctx)
require.NoError(t, err)

if err := <-syncer.Done(); err == nil {
t.Fatalf("Expected syncer to fail at checkpoint with numLeaves %d", numLeaves)
}
Expand All @@ -104,7 +106,9 @@ func testAtomicSyncer(t *testing.T, serverTrieDB *triedb.Database, targetHeight
return leafsResponse, nil
}

syncer.Start(ctx)
err = syncer.Start(ctx)
require.NoError(t, err)

if err := <-syncer.Done(); err != nil {
t.Fatalf("Expected syncer to finish successfully but failed due to %s", err)
}
Expand Down Expand Up @@ -153,7 +157,6 @@ func testAtomicSyncer(t *testing.T, serverTrieDB *triedb.Database, targetHeight
}

func TestAtomicSyncer(t *testing.T) {
rand.Seed(1)
targetHeight := 10 * uint64(commitInterval)
serverTrieDB := triedb.NewDatabase(rawdb.NewMemoryDatabase(), nil)
root, _, _ := syncutils.GenerateTrie(t, serverTrieDB, int(targetHeight), atomicKeyLength)
Expand All @@ -162,7 +165,6 @@ func TestAtomicSyncer(t *testing.T) {
}

func TestAtomicSyncerResume(t *testing.T) {
rand.Seed(1)
targetHeight := 10 * uint64(commitInterval)
serverTrieDB := triedb.NewDatabase(rawdb.NewMemoryDatabase(), nil)
numTrieKeys := int(targetHeight) - 1 // no atomic ops for genesis
Expand All @@ -179,7 +181,6 @@ func TestAtomicSyncerResume(t *testing.T) {
}

func TestAtomicSyncerResumeNewRootCheckpoint(t *testing.T) {
rand.Seed(1)
targetHeight1 := 10 * uint64(commitInterval)
serverTrieDB := triedb.NewDatabase(rawdb.NewMemoryDatabase(), nil)
numTrieKeys1 := int(targetHeight1) - 1 // no atomic ops for genesis
Expand Down
16 changes: 13 additions & 3 deletions plugin/evm/atomic_trie.go
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,11 @@ func (a *atomicTrie) InsertTrie(nodes *trienode.NodeSet, root common.Hash) error
return err
}
}
a.trieDB.Reference(root, common.Hash{})

err := a.trieDB.Reference(root, common.Hash{})
if err != nil {
return fmt.Errorf("referencing root: %w", err)
}

// The use of [Cap] in [insertTrie] prevents exceeding the configured memory
// limit (and OOM) in case there is a large backlog of processing (unaccepted) blocks.
Expand Down Expand Up @@ -358,7 +362,10 @@ func (a *atomicTrie) AcceptTrie(height uint64, root common.Hash) (bool, error) {
//
// Note: It is safe to dereference roots that have been committed to disk
// (they are no-ops).
a.tipBuffer.Insert(root)
err := a.tipBuffer.Insert(root)
if err != nil {
return hasCommitted, fmt.Errorf("inserting root in tip buffer: %w", err)
}

// Commit this root if we have reached the [commitInterval].
if height%a.commitInterval == 0 {
Expand All @@ -373,6 +380,9 @@ func (a *atomicTrie) AcceptTrie(height uint64, root common.Hash) (bool, error) {
}

func (a *atomicTrie) RejectTrie(root common.Hash) error {
a.trieDB.Dereference(root)
err := a.trieDB.Dereference(root)
if err != nil {
return fmt.Errorf("dereferencing root from trie database: %w", err)
}
return nil
}
4 changes: 1 addition & 3 deletions plugin/evm/atomic_trie_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -381,8 +381,6 @@ func TestIndexingNilShouldNotImpactTrie(t *testing.T) {
if err := indexAtomicTxs(a1, i, ops[i]); err != nil {
t.Fatal(err)
}
} else {
// do nothing
}
}

Expand Down Expand Up @@ -569,7 +567,7 @@ func TestApplyToSharedMemory(t *testing.T) {
assert.NoError(t, err)
assert.False(t, hasMarker)
// reinitialize the atomic trie
backend, err = NewAtomicBackend(
_, err = NewAtomicBackend(
db, sharedMemories.thisChain, nil, repo, test.lastAcceptedHeight, common.Hash{}, test.commitInterval,
)
assert.NoError(t, err)
Expand Down
2 changes: 1 addition & 1 deletion plugin/evm/block_verification.go
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ func (v blockValidator) SyntacticVerify(b *Block, rules params.Rules) error {
if err != nil {
return err
}
totalGasUsed, err = safemath.Add64(totalGasUsed, gasUsed)
totalGasUsed, err = safemath.Add(totalGasUsed, gasUsed)
if err != nil {
return err
}
Expand Down
6 changes: 2 additions & 4 deletions plugin/evm/export_tx_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1704,7 +1704,6 @@ func TestNewExportTx(t *testing.T) {
}
}()

parent := vm.LastAcceptedBlockInternal().(*Block)
importAmount := uint64(50000000)
utxoID := avax.UTXOID{TxID: ids.GenerateTestID()}

Expand Down Expand Up @@ -1764,7 +1763,7 @@ func TestNewExportTx(t *testing.T) {
t.Fatal(err)
}

parent = vm.LastAcceptedBlockInternal().(*Block)
parent := vm.LastAcceptedBlockInternal().(*Block)
exportAmount := uint64(5000000)

state, err := vm.blockChain.State()
Expand Down Expand Up @@ -1877,7 +1876,6 @@ func TestNewExportTxMulticoin(t *testing.T) {
}
}()

parent := vm.LastAcceptedBlockInternal().(*Block)
importAmount := uint64(50000000)
utxoID := avax.UTXOID{TxID: ids.GenerateTestID()}

Expand Down Expand Up @@ -1967,7 +1965,7 @@ func TestNewExportTxMulticoin(t *testing.T) {
t.Fatal(err)
}

parent = vm.LastAcceptedBlockInternal().(*Block)
parent := vm.LastAcceptedBlockInternal().(*Block)
exportAmount := uint64(5000000)

testKeys0Addr := testKeys[0].EthAddress()
Expand Down
9 changes: 7 additions & 2 deletions plugin/evm/gossiper_atomic_gossiping_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import (
"github.com/ava-labs/avalanchego/proto/pb/sdk"
"github.com/ava-labs/avalanchego/utils/set"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
"google.golang.org/protobuf/proto"

commonEng "github.com/ava-labs/avalanchego/snow/engine/common"
Expand Down Expand Up @@ -147,7 +148,9 @@ func TestMempoolAtmTxsAppGossipHandlingDiscardedTx(t *testing.T) {
tx, conflictingTx := importTxs[0], importTxs[1]
txID := tx.ID()

mempool.AddRemoteTx(tx)
err := mempool.AddRemoteTx(tx)
require.NoError(t, err)

mempool.NextTx()
mempool.DiscardCurrentTx(txID)

Expand Down Expand Up @@ -184,7 +187,9 @@ func TestMempoolAtmTxsAppGossipHandlingDiscardedTx(t *testing.T) {
// Conflicting tx must be submitted over the API to be included in push gossip.
// (i.e., txs received via p2p are not included in push gossip)
// This test adds it directly to the mempool + gossiper to simulate that.
vm.mempool.AddRemoteTx(conflictingTx)
err = vm.mempool.AddRemoteTx(conflictingTx)
require.NoError(t, err)

vm.atomicTxPushGossiper.Add(&atomic.GossipAtomicTx{Tx: conflictingTx})
time.Sleep(500 * time.Millisecond)

Expand Down
43 changes: 33 additions & 10 deletions plugin/evm/message/block_request_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ package message

import (
"encoding/base64"
"math/rand"
"testing"

"github.com/ethereum/go-ethereum/common"
Expand Down Expand Up @@ -38,15 +37,39 @@ func TestMarshalBlockRequest(t *testing.T) {
// TestMarshalBlockResponse asserts that the structure or serialization logic hasn't changed, primarily to
// ensure compatibility with the network.
func TestMarshalBlockResponse(t *testing.T) {
// create some random bytes
// set seed to ensure deterministic random behaviour
rand.Seed(1)
blocksBytes := make([][]byte, 32)
for i := range blocksBytes {
blocksBytes[i] = make([]byte, rand.Intn(32)+32) // min 32 length, max 64
_, err := rand.Read(blocksBytes[i])
assert.NoError(t, err)
}
blocksBytes := [][]byte{
[]byte{0x4f, 0x16, 0x3f, 0x5f, 0xf, 0x9a, 0x62, 0x1d, 0x72, 0x95, 0x66, 0xc7, 0x4d, 0x10, 0x3, 0x7c, 0x4d, 0x7b, 0xbb, 0x4, 0x7, 0xd1, 0xe2, 0xc6, 0x49, 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 0xc1, 0xaf, 0x42, 0xea, 0xb8, 0xe2, 0x92, 0x5c, 0x6d, 0xae, 0xe4, 0xde, 0x5e, 0xf9, 0xf9, 0xdc, 0xf0, 0x8d, 0xfc, 0xbd, 0x2, 0xb8, 0x8, 0x9, 0x39, 0x85, 0x85, 0x92, 0x8a, 0xf, 0x7d, 0xe5, 0xb, 0xe1, 0xa6, 0xdc, 0x1d, 0x57, 0x68, 0xe8, 0x53, 0x79, 0x88, 0xfd, 0xdc, 0xe5, 0x62, 0xe9, 0xb9, 0x48, 0xc9, 0x18, 0xbb, 0xa3, 0xe9, 0x33, 0xe5, 0xc4, 0x0},
[]byte{0xcd, 0xae, 0x77, 0xba, 0x1d, 0x25, 0x9b, 0x18, 0x8a, 0x4b, 0x21, 0xc8, 0x6f, 0xbc, 0x23, 0xd7, 0x28, 0xb4, 0x53, 0x47, 0xea, 0xda, 0x65, 0xa, 0xf2, 0x4c, 0x56, 0xd0, 0x80, 0xa, 0x86, 0x91, 0x33, 0x20, 0x88, 0xa8, 0x5, 0xbd, 0x55, 0xc4, 0x46, 0xe2, 0x5e, 0xb0, 0x75}}

blockResponse := BlockResponse{
Blocks: blocksBytes,
Expand Down
Loading

0 comments on commit 3eddab0

Please sign in to comment.