Skip to content

Commit

Permalink
Merge branch 'main' into demote-relayer
Browse files Browse the repository at this point in the history
  • Loading branch information
iansuvak authored Aug 15, 2024
2 parents 5210e3b + 5e26b8d commit 776fe94
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 11 deletions.
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## Setup

To start developing on AWM Relayer, you'll need Golang v1.21.13.
To start developing on AWM Relayer, you'll need Golang v1.22.6.

## Issues

Expand Down
6 changes: 2 additions & 4 deletions database/json_file_storage_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,9 @@ func TestConcurrentWriteReadSingleChain(t *testing.T) {
wg := sync.WaitGroup{}
for i := 0; i < 10; i++ {
wg.Add(1)
idx := i
go func() {
defer wg.Done()
testWrite(jsonStorage, relayerIDs[0], uint64(idx))
testWrite(jsonStorage, relayerIDs[0], uint64(i))
}()
}
wg.Wait()
Expand Down Expand Up @@ -94,10 +93,9 @@ func TestConcurrentWriteReadMultipleChains(t *testing.T) {
wg := sync.WaitGroup{}
for i := 0; i < 3; i++ {
wg.Add(1)
index := i
go func() {
defer wg.Done()
testWrite(jsonStorage, relayerIDs[index], uint64(index))
testWrite(jsonStorage, relayerIDs[i], uint64(i))
}()
}
wg.Wait()
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/ava-labs/awm-relayer

go 1.21.13
go 1.22.6

require (
github.com/ava-labs/avalanchego v1.11.10
Expand Down
5 changes: 1 addition & 4 deletions relayer/application_relayer.go
Original file line number Diff line number Diff line change
Expand Up @@ -148,11 +148,8 @@ func (r *ApplicationRelayer) ProcessHeight(
) {
var eg errgroup.Group
for _, handler := range handlers {
// Copy the loop variable to a local variable to avoid the loop variable being captured by the
// goroutine. Once we upgrade to Go 1.22, we can use the loop variable directly in the goroutine.
h := handler
eg.Go(func() error {
_, err := r.ProcessMessage(h)
_, err := r.ProcessMessage(handler)
return err
})
}
Expand Down
2 changes: 1 addition & 1 deletion scripts/versions.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,4 @@ GINKGO_VERSION=${GINKGO_VERSION:-$(getDepVersion github.com/onsi/ginkgo/v2)}
SUBNET_EVM_VERSION=${SUBNET_EVM_VERSION:-update-avago-teleporter}

# Set golangci-lint version
GOLANGCI_LINT_VERSION=${GOLANGCI_LINT_VERSION:-'v1.55'}
GOLANGCI_LINT_VERSION=${GOLANGCI_LINT_VERSION:-'v1.60'}

0 comments on commit 776fe94

Please sign in to comment.